| Alternative 1 | |
|---|---|
| Error | 45.2 |
| Cost | 33028 |
(FPCore (a b angle x-scale y-scale)
:precision binary64
(/
(-
(sqrt
(*
(*
(* 2.0 (/ (* 4.0 (* (* b a) (* b (- a)))) (pow (* x-scale y-scale) 2.0)))
(* (* b a) (* b (- a))))
(+
(+
(/
(/
(+
(pow (* a (sin (* (/ angle 180.0) PI))) 2.0)
(pow (* b (cos (* (/ angle 180.0) PI))) 2.0))
x-scale)
x-scale)
(/
(/
(+
(pow (* a (cos (* (/ angle 180.0) PI))) 2.0)
(pow (* b (sin (* (/ angle 180.0) PI))) 2.0))
y-scale)
y-scale))
(sqrt
(+
(pow
(-
(/
(/
(+
(pow (* a (sin (* (/ angle 180.0) PI))) 2.0)
(pow (* b (cos (* (/ angle 180.0) PI))) 2.0))
x-scale)
x-scale)
(/
(/
(+
(pow (* a (cos (* (/ angle 180.0) PI))) 2.0)
(pow (* b (sin (* (/ angle 180.0) PI))) 2.0))
y-scale)
y-scale))
2.0)
(pow
(/
(/
(*
(*
(* 2.0 (- (pow b 2.0) (pow a 2.0)))
(sin (* (/ angle 180.0) PI)))
(cos (* (/ angle 180.0) PI)))
x-scale)
y-scale)
2.0)))))))
(/ (* 4.0 (* (* b a) (* b (- a)))) (pow (* x-scale y-scale) 2.0))))(FPCore (a b angle x-scale y-scale)
:precision binary64
(let* ((t_0 (* 0.005555555555555556 (* angle PI)))
(t_1 (* a (cos t_0)))
(t_2 (* b (sqrt 8.0))))
(if (<= y-scale -3e-106)
(*
0.25
(fabs
(*
(sqrt 2.0)
(* y-scale (* (cos (* angle (* PI 0.005555555555555556))) t_2)))))
(if (<= y-scale 9.5e-195)
(* 0.25 (* x-scale (* (sqrt 8.0) (* (sqrt 2.0) t_1))))
(if (<= y-scale 1.4e-37)
(*
0.25
(*
x-scale
(* (sqrt 8.0) (* (sqrt 2.0) (hypot (* b (sin t_0)) t_1)))))
(* (* y-scale 0.25) (* (sqrt 2.0) (fabs t_2))))))))double code(double a, double b, double angle, double x_45_scale, double y_45_scale) {
return -sqrt((((2.0 * ((4.0 * ((b * a) * (b * -a))) / pow((x_45_scale * y_45_scale), 2.0))) * ((b * a) * (b * -a))) * (((((pow((a * sin(((angle / 180.0) * ((double) M_PI)))), 2.0) + pow((b * cos(((angle / 180.0) * ((double) M_PI)))), 2.0)) / x_45_scale) / x_45_scale) + (((pow((a * cos(((angle / 180.0) * ((double) M_PI)))), 2.0) + pow((b * sin(((angle / 180.0) * ((double) M_PI)))), 2.0)) / y_45_scale) / y_45_scale)) + sqrt((pow(((((pow((a * sin(((angle / 180.0) * ((double) M_PI)))), 2.0) + pow((b * cos(((angle / 180.0) * ((double) M_PI)))), 2.0)) / x_45_scale) / x_45_scale) - (((pow((a * cos(((angle / 180.0) * ((double) M_PI)))), 2.0) + pow((b * sin(((angle / 180.0) * ((double) M_PI)))), 2.0)) / y_45_scale) / y_45_scale)), 2.0) + pow((((((2.0 * (pow(b, 2.0) - pow(a, 2.0))) * sin(((angle / 180.0) * ((double) M_PI)))) * cos(((angle / 180.0) * ((double) M_PI)))) / x_45_scale) / y_45_scale), 2.0)))))) / ((4.0 * ((b * a) * (b * -a))) / pow((x_45_scale * y_45_scale), 2.0));
}
double code(double a, double b, double angle, double x_45_scale, double y_45_scale) {
double t_0 = 0.005555555555555556 * (angle * ((double) M_PI));
double t_1 = a * cos(t_0);
double t_2 = b * sqrt(8.0);
double tmp;
if (y_45_scale <= -3e-106) {
tmp = 0.25 * fabs((sqrt(2.0) * (y_45_scale * (cos((angle * (((double) M_PI) * 0.005555555555555556))) * t_2))));
} else if (y_45_scale <= 9.5e-195) {
tmp = 0.25 * (x_45_scale * (sqrt(8.0) * (sqrt(2.0) * t_1)));
} else if (y_45_scale <= 1.4e-37) {
tmp = 0.25 * (x_45_scale * (sqrt(8.0) * (sqrt(2.0) * hypot((b * sin(t_0)), t_1))));
} else {
tmp = (y_45_scale * 0.25) * (sqrt(2.0) * fabs(t_2));
}
return tmp;
}
public static double code(double a, double b, double angle, double x_45_scale, double y_45_scale) {
return -Math.sqrt((((2.0 * ((4.0 * ((b * a) * (b * -a))) / Math.pow((x_45_scale * y_45_scale), 2.0))) * ((b * a) * (b * -a))) * (((((Math.pow((a * Math.sin(((angle / 180.0) * Math.PI))), 2.0) + Math.pow((b * Math.cos(((angle / 180.0) * Math.PI))), 2.0)) / x_45_scale) / x_45_scale) + (((Math.pow((a * Math.cos(((angle / 180.0) * Math.PI))), 2.0) + Math.pow((b * Math.sin(((angle / 180.0) * Math.PI))), 2.0)) / y_45_scale) / y_45_scale)) + Math.sqrt((Math.pow(((((Math.pow((a * Math.sin(((angle / 180.0) * Math.PI))), 2.0) + Math.pow((b * Math.cos(((angle / 180.0) * Math.PI))), 2.0)) / x_45_scale) / x_45_scale) - (((Math.pow((a * Math.cos(((angle / 180.0) * Math.PI))), 2.0) + Math.pow((b * Math.sin(((angle / 180.0) * Math.PI))), 2.0)) / y_45_scale) / y_45_scale)), 2.0) + Math.pow((((((2.0 * (Math.pow(b, 2.0) - Math.pow(a, 2.0))) * Math.sin(((angle / 180.0) * Math.PI))) * Math.cos(((angle / 180.0) * Math.PI))) / x_45_scale) / y_45_scale), 2.0)))))) / ((4.0 * ((b * a) * (b * -a))) / Math.pow((x_45_scale * y_45_scale), 2.0));
}
public static double code(double a, double b, double angle, double x_45_scale, double y_45_scale) {
double t_0 = 0.005555555555555556 * (angle * Math.PI);
double t_1 = a * Math.cos(t_0);
double t_2 = b * Math.sqrt(8.0);
double tmp;
if (y_45_scale <= -3e-106) {
tmp = 0.25 * Math.abs((Math.sqrt(2.0) * (y_45_scale * (Math.cos((angle * (Math.PI * 0.005555555555555556))) * t_2))));
} else if (y_45_scale <= 9.5e-195) {
tmp = 0.25 * (x_45_scale * (Math.sqrt(8.0) * (Math.sqrt(2.0) * t_1)));
} else if (y_45_scale <= 1.4e-37) {
tmp = 0.25 * (x_45_scale * (Math.sqrt(8.0) * (Math.sqrt(2.0) * Math.hypot((b * Math.sin(t_0)), t_1))));
} else {
tmp = (y_45_scale * 0.25) * (Math.sqrt(2.0) * Math.abs(t_2));
}
return tmp;
}
def code(a, b, angle, x_45_scale, y_45_scale): return -math.sqrt((((2.0 * ((4.0 * ((b * a) * (b * -a))) / math.pow((x_45_scale * y_45_scale), 2.0))) * ((b * a) * (b * -a))) * (((((math.pow((a * math.sin(((angle / 180.0) * math.pi))), 2.0) + math.pow((b * math.cos(((angle / 180.0) * math.pi))), 2.0)) / x_45_scale) / x_45_scale) + (((math.pow((a * math.cos(((angle / 180.0) * math.pi))), 2.0) + math.pow((b * math.sin(((angle / 180.0) * math.pi))), 2.0)) / y_45_scale) / y_45_scale)) + math.sqrt((math.pow(((((math.pow((a * math.sin(((angle / 180.0) * math.pi))), 2.0) + math.pow((b * math.cos(((angle / 180.0) * math.pi))), 2.0)) / x_45_scale) / x_45_scale) - (((math.pow((a * math.cos(((angle / 180.0) * math.pi))), 2.0) + math.pow((b * math.sin(((angle / 180.0) * math.pi))), 2.0)) / y_45_scale) / y_45_scale)), 2.0) + math.pow((((((2.0 * (math.pow(b, 2.0) - math.pow(a, 2.0))) * math.sin(((angle / 180.0) * math.pi))) * math.cos(((angle / 180.0) * math.pi))) / x_45_scale) / y_45_scale), 2.0)))))) / ((4.0 * ((b * a) * (b * -a))) / math.pow((x_45_scale * y_45_scale), 2.0))
def code(a, b, angle, x_45_scale, y_45_scale): t_0 = 0.005555555555555556 * (angle * math.pi) t_1 = a * math.cos(t_0) t_2 = b * math.sqrt(8.0) tmp = 0 if y_45_scale <= -3e-106: tmp = 0.25 * math.fabs((math.sqrt(2.0) * (y_45_scale * (math.cos((angle * (math.pi * 0.005555555555555556))) * t_2)))) elif y_45_scale <= 9.5e-195: tmp = 0.25 * (x_45_scale * (math.sqrt(8.0) * (math.sqrt(2.0) * t_1))) elif y_45_scale <= 1.4e-37: tmp = 0.25 * (x_45_scale * (math.sqrt(8.0) * (math.sqrt(2.0) * math.hypot((b * math.sin(t_0)), t_1)))) else: tmp = (y_45_scale * 0.25) * (math.sqrt(2.0) * math.fabs(t_2)) return tmp
function code(a, b, angle, x_45_scale, y_45_scale) return Float64(Float64(-sqrt(Float64(Float64(Float64(2.0 * Float64(Float64(4.0 * Float64(Float64(b * a) * Float64(b * Float64(-a)))) / (Float64(x_45_scale * y_45_scale) ^ 2.0))) * Float64(Float64(b * a) * Float64(b * Float64(-a)))) * Float64(Float64(Float64(Float64(Float64((Float64(a * sin(Float64(Float64(angle / 180.0) * pi))) ^ 2.0) + (Float64(b * cos(Float64(Float64(angle / 180.0) * pi))) ^ 2.0)) / x_45_scale) / x_45_scale) + Float64(Float64(Float64((Float64(a * cos(Float64(Float64(angle / 180.0) * pi))) ^ 2.0) + (Float64(b * sin(Float64(Float64(angle / 180.0) * pi))) ^ 2.0)) / y_45_scale) / y_45_scale)) + sqrt(Float64((Float64(Float64(Float64(Float64((Float64(a * sin(Float64(Float64(angle / 180.0) * pi))) ^ 2.0) + (Float64(b * cos(Float64(Float64(angle / 180.0) * pi))) ^ 2.0)) / x_45_scale) / x_45_scale) - Float64(Float64(Float64((Float64(a * cos(Float64(Float64(angle / 180.0) * pi))) ^ 2.0) + (Float64(b * sin(Float64(Float64(angle / 180.0) * pi))) ^ 2.0)) / y_45_scale) / y_45_scale)) ^ 2.0) + (Float64(Float64(Float64(Float64(Float64(2.0 * Float64((b ^ 2.0) - (a ^ 2.0))) * sin(Float64(Float64(angle / 180.0) * pi))) * cos(Float64(Float64(angle / 180.0) * pi))) / x_45_scale) / y_45_scale) ^ 2.0))))))) / Float64(Float64(4.0 * Float64(Float64(b * a) * Float64(b * Float64(-a)))) / (Float64(x_45_scale * y_45_scale) ^ 2.0))) end
function code(a, b, angle, x_45_scale, y_45_scale) t_0 = Float64(0.005555555555555556 * Float64(angle * pi)) t_1 = Float64(a * cos(t_0)) t_2 = Float64(b * sqrt(8.0)) tmp = 0.0 if (y_45_scale <= -3e-106) tmp = Float64(0.25 * abs(Float64(sqrt(2.0) * Float64(y_45_scale * Float64(cos(Float64(angle * Float64(pi * 0.005555555555555556))) * t_2))))); elseif (y_45_scale <= 9.5e-195) tmp = Float64(0.25 * Float64(x_45_scale * Float64(sqrt(8.0) * Float64(sqrt(2.0) * t_1)))); elseif (y_45_scale <= 1.4e-37) tmp = Float64(0.25 * Float64(x_45_scale * Float64(sqrt(8.0) * Float64(sqrt(2.0) * hypot(Float64(b * sin(t_0)), t_1))))); else tmp = Float64(Float64(y_45_scale * 0.25) * Float64(sqrt(2.0) * abs(t_2))); end return tmp end
function tmp = code(a, b, angle, x_45_scale, y_45_scale) tmp = -sqrt((((2.0 * ((4.0 * ((b * a) * (b * -a))) / ((x_45_scale * y_45_scale) ^ 2.0))) * ((b * a) * (b * -a))) * (((((((a * sin(((angle / 180.0) * pi))) ^ 2.0) + ((b * cos(((angle / 180.0) * pi))) ^ 2.0)) / x_45_scale) / x_45_scale) + (((((a * cos(((angle / 180.0) * pi))) ^ 2.0) + ((b * sin(((angle / 180.0) * pi))) ^ 2.0)) / y_45_scale) / y_45_scale)) + sqrt(((((((((a * sin(((angle / 180.0) * pi))) ^ 2.0) + ((b * cos(((angle / 180.0) * pi))) ^ 2.0)) / x_45_scale) / x_45_scale) - (((((a * cos(((angle / 180.0) * pi))) ^ 2.0) + ((b * sin(((angle / 180.0) * pi))) ^ 2.0)) / y_45_scale) / y_45_scale)) ^ 2.0) + ((((((2.0 * ((b ^ 2.0) - (a ^ 2.0))) * sin(((angle / 180.0) * pi))) * cos(((angle / 180.0) * pi))) / x_45_scale) / y_45_scale) ^ 2.0)))))) / ((4.0 * ((b * a) * (b * -a))) / ((x_45_scale * y_45_scale) ^ 2.0)); end
function tmp_2 = code(a, b, angle, x_45_scale, y_45_scale) t_0 = 0.005555555555555556 * (angle * pi); t_1 = a * cos(t_0); t_2 = b * sqrt(8.0); tmp = 0.0; if (y_45_scale <= -3e-106) tmp = 0.25 * abs((sqrt(2.0) * (y_45_scale * (cos((angle * (pi * 0.005555555555555556))) * t_2)))); elseif (y_45_scale <= 9.5e-195) tmp = 0.25 * (x_45_scale * (sqrt(8.0) * (sqrt(2.0) * t_1))); elseif (y_45_scale <= 1.4e-37) tmp = 0.25 * (x_45_scale * (sqrt(8.0) * (sqrt(2.0) * hypot((b * sin(t_0)), t_1)))); else tmp = (y_45_scale * 0.25) * (sqrt(2.0) * abs(t_2)); end tmp_2 = tmp; end
code[a_, b_, angle_, x$45$scale_, y$45$scale_] := N[((-N[Sqrt[N[(N[(N[(2.0 * N[(N[(4.0 * N[(N[(b * a), $MachinePrecision] * N[(b * (-a)), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[Power[N[(x$45$scale * y$45$scale), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(b * a), $MachinePrecision] * N[(b * (-a)), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(N[(N[(N[(N[Power[N[(a * N[Sin[N[(N[(angle / 180.0), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[N[(b * N[Cos[N[(N[(angle / 180.0), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] / x$45$scale), $MachinePrecision] / x$45$scale), $MachinePrecision] + N[(N[(N[(N[Power[N[(a * N[Cos[N[(N[(angle / 180.0), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[N[(b * N[Sin[N[(N[(angle / 180.0), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] / y$45$scale), $MachinePrecision] / y$45$scale), $MachinePrecision]), $MachinePrecision] + N[Sqrt[N[(N[Power[N[(N[(N[(N[(N[Power[N[(a * N[Sin[N[(N[(angle / 180.0), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[N[(b * N[Cos[N[(N[(angle / 180.0), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] / x$45$scale), $MachinePrecision] / x$45$scale), $MachinePrecision] - N[(N[(N[(N[Power[N[(a * N[Cos[N[(N[(angle / 180.0), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[N[(b * N[Sin[N[(N[(angle / 180.0), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] / y$45$scale), $MachinePrecision] / y$45$scale), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[N[(N[(N[(N[(N[(2.0 * N[(N[Power[b, 2.0], $MachinePrecision] - N[Power[a, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Sin[N[(N[(angle / 180.0), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * N[Cos[N[(N[(angle / 180.0), $MachinePrecision] * Pi), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / x$45$scale), $MachinePrecision] / y$45$scale), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / N[(N[(4.0 * N[(N[(b * a), $MachinePrecision] * N[(b * (-a)), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[Power[N[(x$45$scale * y$45$scale), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
code[a_, b_, angle_, x$45$scale_, y$45$scale_] := Block[{t$95$0 = N[(0.005555555555555556 * N[(angle * Pi), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(a * N[Cos[t$95$0], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(b * N[Sqrt[8.0], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y$45$scale, -3e-106], N[(0.25 * N[Abs[N[(N[Sqrt[2.0], $MachinePrecision] * N[(y$45$scale * N[(N[Cos[N[(angle * N[(Pi * 0.005555555555555556), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y$45$scale, 9.5e-195], N[(0.25 * N[(x$45$scale * N[(N[Sqrt[8.0], $MachinePrecision] * N[(N[Sqrt[2.0], $MachinePrecision] * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y$45$scale, 1.4e-37], N[(0.25 * N[(x$45$scale * N[(N[Sqrt[8.0], $MachinePrecision] * N[(N[Sqrt[2.0], $MachinePrecision] * N[Sqrt[N[(b * N[Sin[t$95$0], $MachinePrecision]), $MachinePrecision] ^ 2 + t$95$1 ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y$45$scale * 0.25), $MachinePrecision] * N[(N[Sqrt[2.0], $MachinePrecision] * N[Abs[t$95$2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]
\frac{-\sqrt{\left(\left(2 \cdot \frac{4 \cdot \left(\left(b \cdot a\right) \cdot \left(b \cdot \left(-a\right)\right)\right)}{{\left(x-scale \cdot y-scale\right)}^{2}}\right) \cdot \left(\left(b \cdot a\right) \cdot \left(b \cdot \left(-a\right)\right)\right)\right) \cdot \left(\left(\frac{\frac{{\left(a \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{x-scale}}{x-scale} + \frac{\frac{{\left(a \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{y-scale}}{y-scale}\right) + \sqrt{{\left(\frac{\frac{{\left(a \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{x-scale}}{x-scale} - \frac{\frac{{\left(a \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{y-scale}}{y-scale}\right)}^{2} + {\left(\frac{\frac{\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right) \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)}{x-scale}}{y-scale}\right)}^{2}}\right)}}{\frac{4 \cdot \left(\left(b \cdot a\right) \cdot \left(b \cdot \left(-a\right)\right)\right)}{{\left(x-scale \cdot y-scale\right)}^{2}}}
\begin{array}{l}
t_0 := 0.005555555555555556 \cdot \left(angle \cdot \pi\right)\\
t_1 := a \cdot \cos t_0\\
t_2 := b \cdot \sqrt{8}\\
\mathbf{if}\;y-scale \leq -3 \cdot 10^{-106}:\\
\;\;\;\;0.25 \cdot \left|\sqrt{2} \cdot \left(y-scale \cdot \left(\cos \left(angle \cdot \left(\pi \cdot 0.005555555555555556\right)\right) \cdot t_2\right)\right)\right|\\
\mathbf{elif}\;y-scale \leq 9.5 \cdot 10^{-195}:\\
\;\;\;\;0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \left(\sqrt{2} \cdot t_1\right)\right)\right)\\
\mathbf{elif}\;y-scale \leq 1.4 \cdot 10^{-37}:\\
\;\;\;\;0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \left(\sqrt{2} \cdot \mathsf{hypot}\left(b \cdot \sin t_0, t_1\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\left(y-scale \cdot 0.25\right) \cdot \left(\sqrt{2} \cdot \left|t_2\right|\right)\\
\end{array}
Results
if y-scale < -3.00000000000000019e-106Initial program 63.3
Simplified62.8
[Start]63.3 | \[ \frac{-\sqrt{\left(\left(2 \cdot \frac{4 \cdot \left(\left(b \cdot a\right) \cdot \left(b \cdot \left(-a\right)\right)\right)}{{\left(x-scale \cdot y-scale\right)}^{2}}\right) \cdot \left(\left(b \cdot a\right) \cdot \left(b \cdot \left(-a\right)\right)\right)\right) \cdot \left(\left(\frac{\frac{{\left(a \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{x-scale}}{x-scale} + \frac{\frac{{\left(a \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{y-scale}}{y-scale}\right) + \sqrt{{\left(\frac{\frac{{\left(a \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{x-scale}}{x-scale} - \frac{\frac{{\left(a \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{y-scale}}{y-scale}\right)}^{2} + {\left(\frac{\frac{\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right) \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)}{x-scale}}{y-scale}\right)}^{2}}\right)}}{\frac{4 \cdot \left(\left(b \cdot a\right) \cdot \left(b \cdot \left(-a\right)\right)\right)}{{\left(x-scale \cdot y-scale\right)}^{2}}}
\] |
|---|
Taylor expanded in b around inf 59.9
Taylor expanded in x-scale around 0 54.6
Applied egg-rr54.6
Applied egg-rr53.2
Simplified42.1
[Start]53.2 | \[ 0.25 \cdot \sqrt{{\left(\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(x-scale \cdot \left(\left(y-scale \cdot \sqrt{8}\right) \cdot b\right)\right) \cdot \frac{\sqrt{2}}{x-scale}\right)\right)}^{2}}
\] |
|---|---|
unpow2 [=>]53.2 | \[ 0.25 \cdot \sqrt{\color{blue}{\left(\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(x-scale \cdot \left(\left(y-scale \cdot \sqrt{8}\right) \cdot b\right)\right) \cdot \frac{\sqrt{2}}{x-scale}\right)\right) \cdot \left(\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(x-scale \cdot \left(\left(y-scale \cdot \sqrt{8}\right) \cdot b\right)\right) \cdot \frac{\sqrt{2}}{x-scale}\right)\right)}}
\] |
rem-sqrt-square [=>]45.8 | \[ 0.25 \cdot \color{blue}{\left|\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right) \cdot \left(\left(x-scale \cdot \left(\left(y-scale \cdot \sqrt{8}\right) \cdot b\right)\right) \cdot \frac{\sqrt{2}}{x-scale}\right)\right|}
\] |
associate-*r/ [=>]45.8 | \[ 0.25 \cdot \left|\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right) \cdot \color{blue}{\frac{\left(x-scale \cdot \left(\left(y-scale \cdot \sqrt{8}\right) \cdot b\right)\right) \cdot \sqrt{2}}{x-scale}}\right|
\] |
associate-*l/ [<=]45.8 | \[ 0.25 \cdot \left|\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right) \cdot \color{blue}{\left(\frac{x-scale \cdot \left(\left(y-scale \cdot \sqrt{8}\right) \cdot b\right)}{x-scale} \cdot \sqrt{2}\right)}\right|
\] |
*-commutative [=>]45.8 | \[ 0.25 \cdot \left|\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right) \cdot \color{blue}{\left(\sqrt{2} \cdot \frac{x-scale \cdot \left(\left(y-scale \cdot \sqrt{8}\right) \cdot b\right)}{x-scale}\right)}\right|
\] |
associate-*r* [=>]45.8 | \[ 0.25 \cdot \left|\color{blue}{\left(\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right) \cdot \sqrt{2}\right) \cdot \frac{x-scale \cdot \left(\left(y-scale \cdot \sqrt{8}\right) \cdot b\right)}{x-scale}}\right|
\] |
*-commutative [<=]45.8 | \[ 0.25 \cdot \left|\color{blue}{\left(\sqrt{2} \cdot \cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right)} \cdot \frac{x-scale \cdot \left(\left(y-scale \cdot \sqrt{8}\right) \cdot b\right)}{x-scale}\right|
\] |
associate-/l* [=>]47.8 | \[ 0.25 \cdot \left|\left(\sqrt{2} \cdot \cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right) \cdot \color{blue}{\frac{x-scale}{\frac{x-scale}{\left(y-scale \cdot \sqrt{8}\right) \cdot b}}}\right|
\] |
associate-/r/ [=>]42.1 | \[ 0.25 \cdot \left|\left(\sqrt{2} \cdot \cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right) \cdot \color{blue}{\left(\frac{x-scale}{x-scale} \cdot \left(\left(y-scale \cdot \sqrt{8}\right) \cdot b\right)\right)}\right|
\] |
*-inverses [=>]42.1 | \[ 0.25 \cdot \left|\left(\sqrt{2} \cdot \cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right) \cdot \left(\color{blue}{1} \cdot \left(\left(y-scale \cdot \sqrt{8}\right) \cdot b\right)\right)\right|
\] |
*-lft-identity [=>]42.1 | \[ 0.25 \cdot \left|\left(\sqrt{2} \cdot \cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right) \cdot \color{blue}{\left(\left(y-scale \cdot \sqrt{8}\right) \cdot b\right)}\right|
\] |
associate-*l* [=>]42.1 | \[ 0.25 \cdot \left|\left(\sqrt{2} \cdot \cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right) \cdot \color{blue}{\left(y-scale \cdot \left(\sqrt{8} \cdot b\right)\right)}\right|
\] |
*-commutative [<=]42.1 | \[ 0.25 \cdot \left|\left(\sqrt{2} \cdot \cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right) \cdot \left(y-scale \cdot \color{blue}{\left(b \cdot \sqrt{8}\right)}\right)\right|
\] |
*-commutative [=>]42.1 | \[ 0.25 \cdot \left|\left(\sqrt{2} \cdot \cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right) \cdot \color{blue}{\left(\left(b \cdot \sqrt{8}\right) \cdot y-scale\right)}\right|
\] |
if -3.00000000000000019e-106 < y-scale < 9.5000000000000007e-195Initial program 64.0
Simplified63.8
[Start]64.0 | \[ \frac{-\sqrt{\left(\left(2 \cdot \frac{4 \cdot \left(\left(b \cdot a\right) \cdot \left(b \cdot \left(-a\right)\right)\right)}{{\left(x-scale \cdot y-scale\right)}^{2}}\right) \cdot \left(\left(b \cdot a\right) \cdot \left(b \cdot \left(-a\right)\right)\right)\right) \cdot \left(\left(\frac{\frac{{\left(a \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{x-scale}}{x-scale} + \frac{\frac{{\left(a \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{y-scale}}{y-scale}\right) + \sqrt{{\left(\frac{\frac{{\left(a \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{x-scale}}{x-scale} - \frac{\frac{{\left(a \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{y-scale}}{y-scale}\right)}^{2} + {\left(\frac{\frac{\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right) \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)}{x-scale}}{y-scale}\right)}^{2}}\right)}}{\frac{4 \cdot \left(\left(b \cdot a\right) \cdot \left(b \cdot \left(-a\right)\right)\right)}{{\left(x-scale \cdot y-scale\right)}^{2}}}
\] |
|---|
Taylor expanded in y-scale around 0 52.5
Simplified52.4
[Start]52.5 | \[ 0.25 \cdot \left(\left(x-scale \cdot \sqrt{8}\right) \cdot \sqrt{2 \cdot \left({a}^{2} \cdot {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}\right) + 2 \cdot \left({b}^{2} \cdot {\sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}\right)}\right)
\] |
|---|---|
associate-*l* [=>]52.4 | \[ 0.25 \cdot \color{blue}{\left(x-scale \cdot \left(\sqrt{8} \cdot \sqrt{2 \cdot \left({a}^{2} \cdot {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}\right) + 2 \cdot \left({b}^{2} \cdot {\sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}\right)}\right)\right)}
\] |
distribute-lft-out [=>]52.4 | \[ 0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \sqrt{\color{blue}{2 \cdot \left({a}^{2} \cdot {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2} + {b}^{2} \cdot {\sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}\right)}}\right)\right)
\] |
fma-def [=>]52.4 | \[ 0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \sqrt{2 \cdot \color{blue}{\mathsf{fma}\left({a}^{2}, {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}, {b}^{2} \cdot {\sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}\right)}}\right)\right)
\] |
unpow2 [=>]52.4 | \[ 0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \sqrt{2 \cdot \mathsf{fma}\left(\color{blue}{a \cdot a}, {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}, {b}^{2} \cdot {\sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}\right)}\right)\right)
\] |
*-commutative [=>]52.4 | \[ 0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \sqrt{2 \cdot \mathsf{fma}\left(a \cdot a, {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}, \color{blue}{{\sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2} \cdot {b}^{2}}\right)}\right)\right)
\] |
unpow2 [=>]52.4 | \[ 0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \sqrt{2 \cdot \mathsf{fma}\left(a \cdot a, {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}, {\sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2} \cdot \color{blue}{\left(b \cdot b\right)}\right)}\right)\right)
\] |
Taylor expanded in a around inf 49.0
if 9.5000000000000007e-195 < y-scale < 1.4000000000000001e-37Initial program 63.6
Simplified63.4
[Start]63.6 | \[ \frac{-\sqrt{\left(\left(2 \cdot \frac{4 \cdot \left(\left(b \cdot a\right) \cdot \left(b \cdot \left(-a\right)\right)\right)}{{\left(x-scale \cdot y-scale\right)}^{2}}\right) \cdot \left(\left(b \cdot a\right) \cdot \left(b \cdot \left(-a\right)\right)\right)\right) \cdot \left(\left(\frac{\frac{{\left(a \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{x-scale}}{x-scale} + \frac{\frac{{\left(a \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{y-scale}}{y-scale}\right) + \sqrt{{\left(\frac{\frac{{\left(a \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{x-scale}}{x-scale} - \frac{\frac{{\left(a \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{y-scale}}{y-scale}\right)}^{2} + {\left(\frac{\frac{\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right) \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)}{x-scale}}{y-scale}\right)}^{2}}\right)}}{\frac{4 \cdot \left(\left(b \cdot a\right) \cdot \left(b \cdot \left(-a\right)\right)\right)}{{\left(x-scale \cdot y-scale\right)}^{2}}}
\] |
|---|
Taylor expanded in y-scale around 0 55.0
Simplified55.0
[Start]55.0 | \[ 0.25 \cdot \left(\left(x-scale \cdot \sqrt{8}\right) \cdot \sqrt{2 \cdot \left({a}^{2} \cdot {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}\right) + 2 \cdot \left({b}^{2} \cdot {\sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}\right)}\right)
\] |
|---|---|
associate-*l* [=>]55.0 | \[ 0.25 \cdot \color{blue}{\left(x-scale \cdot \left(\sqrt{8} \cdot \sqrt{2 \cdot \left({a}^{2} \cdot {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}\right) + 2 \cdot \left({b}^{2} \cdot {\sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}\right)}\right)\right)}
\] |
distribute-lft-out [=>]55.0 | \[ 0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \sqrt{\color{blue}{2 \cdot \left({a}^{2} \cdot {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2} + {b}^{2} \cdot {\sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}\right)}}\right)\right)
\] |
fma-def [=>]55.0 | \[ 0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \sqrt{2 \cdot \color{blue}{\mathsf{fma}\left({a}^{2}, {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}, {b}^{2} \cdot {\sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}\right)}}\right)\right)
\] |
unpow2 [=>]55.0 | \[ 0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \sqrt{2 \cdot \mathsf{fma}\left(\color{blue}{a \cdot a}, {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}, {b}^{2} \cdot {\sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}\right)}\right)\right)
\] |
*-commutative [=>]55.0 | \[ 0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \sqrt{2 \cdot \mathsf{fma}\left(a \cdot a, {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}, \color{blue}{{\sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2} \cdot {b}^{2}}\right)}\right)\right)
\] |
unpow2 [=>]55.0 | \[ 0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \sqrt{2 \cdot \mathsf{fma}\left(a \cdot a, {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}, {\sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2} \cdot \color{blue}{\left(b \cdot b\right)}\right)}\right)\right)
\] |
Taylor expanded in angle around inf 55.1
Simplified49.0
[Start]55.1 | \[ 0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \left(\sqrt{2} \cdot \sqrt{{a}^{2} \cdot {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2} + {b}^{2} \cdot {\sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}}\right)\right)\right)
\] |
|---|---|
+-commutative [=>]55.1 | \[ 0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \left(\sqrt{2} \cdot \sqrt{\color{blue}{{b}^{2} \cdot {\sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2} + {a}^{2} \cdot {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}}}\right)\right)\right)
\] |
unpow2 [=>]55.1 | \[ 0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \left(\sqrt{2} \cdot \sqrt{\color{blue}{\left(b \cdot b\right)} \cdot {\sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2} + {a}^{2} \cdot {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}}\right)\right)\right)
\] |
unpow2 [=>]55.1 | \[ 0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \left(\sqrt{2} \cdot \sqrt{\left(b \cdot b\right) \cdot \color{blue}{\left(\sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right) \cdot \sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right)} + {a}^{2} \cdot {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}}\right)\right)\right)
\] |
swap-sqr [<=]54.0 | \[ 0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \left(\sqrt{2} \cdot \sqrt{\color{blue}{\left(b \cdot \sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right) \cdot \left(b \cdot \sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right)} + {a}^{2} \cdot {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}}\right)\right)\right)
\] |
unpow2 [=>]54.0 | \[ 0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \left(\sqrt{2} \cdot \sqrt{\left(b \cdot \sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right) \cdot \left(b \cdot \sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right) + \color{blue}{\left(a \cdot a\right)} \cdot {\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)}^{2}}\right)\right)\right)
\] |
unpow2 [=>]54.0 | \[ 0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \left(\sqrt{2} \cdot \sqrt{\left(b \cdot \sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right) \cdot \left(b \cdot \sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right) + \left(a \cdot a\right) \cdot \color{blue}{\left(\cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right) \cdot \cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right)}}\right)\right)\right)
\] |
swap-sqr [<=]54.0 | \[ 0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \left(\sqrt{2} \cdot \sqrt{\left(b \cdot \sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right) \cdot \left(b \cdot \sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right) + \color{blue}{\left(a \cdot \cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right) \cdot \left(a \cdot \cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right)}}\right)\right)\right)
\] |
hypot-def [=>]49.0 | \[ 0.25 \cdot \left(x-scale \cdot \left(\sqrt{8} \cdot \left(\sqrt{2} \cdot \color{blue}{\mathsf{hypot}\left(b \cdot \sin \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right), a \cdot \cos \left(0.005555555555555556 \cdot \left(angle \cdot \pi\right)\right)\right)}\right)\right)\right)
\] |
if 1.4000000000000001e-37 < y-scale Initial program 63.1
Simplified62.7
[Start]63.1 | \[ \frac{-\sqrt{\left(\left(2 \cdot \frac{4 \cdot \left(\left(b \cdot a\right) \cdot \left(b \cdot \left(-a\right)\right)\right)}{{\left(x-scale \cdot y-scale\right)}^{2}}\right) \cdot \left(\left(b \cdot a\right) \cdot \left(b \cdot \left(-a\right)\right)\right)\right) \cdot \left(\left(\frac{\frac{{\left(a \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{x-scale}}{x-scale} + \frac{\frac{{\left(a \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{y-scale}}{y-scale}\right) + \sqrt{{\left(\frac{\frac{{\left(a \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{x-scale}}{x-scale} - \frac{\frac{{\left(a \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2} + {\left(b \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right)}^{2}}{y-scale}}{y-scale}\right)}^{2} + {\left(\frac{\frac{\left(\left(2 \cdot \left({b}^{2} - {a}^{2}\right)\right) \cdot \sin \left(\frac{angle}{180} \cdot \pi\right)\right) \cdot \cos \left(\frac{angle}{180} \cdot \pi\right)}{x-scale}}{y-scale}\right)}^{2}}\right)}}{\frac{4 \cdot \left(\left(b \cdot a\right) \cdot \left(b \cdot \left(-a\right)\right)\right)}{{\left(x-scale \cdot y-scale\right)}^{2}}}
\] |
|---|
Taylor expanded in angle around 0 52.8
Simplified52.8
[Start]52.8 | \[ 0.25 \cdot \left(y-scale \cdot \left(\sqrt{2} \cdot \left(b \cdot \sqrt{8}\right)\right)\right)
\] |
|---|---|
associate-*r* [=>]52.8 | \[ \color{blue}{\left(0.25 \cdot y-scale\right) \cdot \left(\sqrt{2} \cdot \left(b \cdot \sqrt{8}\right)\right)}
\] |
*-commutative [=>]52.8 | \[ \left(0.25 \cdot y-scale\right) \cdot \color{blue}{\left(\left(b \cdot \sqrt{8}\right) \cdot \sqrt{2}\right)}
\] |
*-commutative [=>]52.8 | \[ \left(0.25 \cdot y-scale\right) \cdot \left(\color{blue}{\left(\sqrt{8} \cdot b\right)} \cdot \sqrt{2}\right)
\] |
Applied egg-rr41.4
Final simplification45.1
| Alternative 1 | |
|---|---|
| Error | 45.2 |
| Cost | 33028 |
| Alternative 2 | |
|---|---|
| Error | 47.4 |
| Cost | 26760 |
| Alternative 3 | |
|---|---|
| Error | 47.4 |
| Cost | 26760 |
| Alternative 4 | |
|---|---|
| Error | 47.4 |
| Cost | 26180 |
| Alternative 5 | |
|---|---|
| Error | 49.5 |
| Cost | 20572 |
| Alternative 6 | |
|---|---|
| Error | 48.5 |
| Cost | 20040 |
| Alternative 7 | |
|---|---|
| Error | 50.7 |
| Cost | 13640 |
| Alternative 8 | |
|---|---|
| Error | 53.3 |
| Cost | 7565 |
| Alternative 9 | |
|---|---|
| Error | 54.2 |
| Cost | 7432 |
| Alternative 10 | |
|---|---|
| Error | 54.4 |
| Cost | 785 |
| Alternative 11 | |
|---|---|
| Error | 54.3 |
| Cost | 192 |
herbie shell --seed 2023027
(FPCore (a b angle x-scale y-scale)
:name "a from scale-rotated-ellipse"
:precision binary64
(/ (- (sqrt (* (* (* 2.0 (/ (* 4.0 (* (* b a) (* b (- a)))) (pow (* x-scale y-scale) 2.0))) (* (* b a) (* b (- a)))) (+ (+ (/ (/ (+ (pow (* a (sin (* (/ angle 180.0) PI))) 2.0) (pow (* b (cos (* (/ angle 180.0) PI))) 2.0)) x-scale) x-scale) (/ (/ (+ (pow (* a (cos (* (/ angle 180.0) PI))) 2.0) (pow (* b (sin (* (/ angle 180.0) PI))) 2.0)) y-scale) y-scale)) (sqrt (+ (pow (- (/ (/ (+ (pow (* a (sin (* (/ angle 180.0) PI))) 2.0) (pow (* b (cos (* (/ angle 180.0) PI))) 2.0)) x-scale) x-scale) (/ (/ (+ (pow (* a (cos (* (/ angle 180.0) PI))) 2.0) (pow (* b (sin (* (/ angle 180.0) PI))) 2.0)) y-scale) y-scale)) 2.0) (pow (/ (/ (* (* (* 2.0 (- (pow b 2.0) (pow a 2.0))) (sin (* (/ angle 180.0) PI))) (cos (* (/ angle 180.0) PI))) x-scale) y-scale) 2.0))))))) (/ (* 4.0 (* (* b a) (* b (- a)))) (pow (* x-scale y-scale) 2.0))))