Example from Robby

Percentage Accurate: 99.8% → 99.8%
Time: 11.9s
Alternatives: 10
Speedup: N/A×

Specification

?
\[\begin{array}{l} \\ \begin{array}{l} t_1 := \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\\ \left|\left(ew \cdot \sin t\right) \cdot \cos t\_1 + \left(eh \cdot \cos t\right) \cdot \sin t\_1\right| \end{array} \end{array} \]
(FPCore (eh ew t)
 :precision binary64
 (let* ((t_1 (atan (/ (/ eh ew) (tan t)))))
   (fabs (+ (* (* ew (sin t)) (cos t_1)) (* (* eh (cos t)) (sin t_1))))))
double code(double eh, double ew, double t) {
	double t_1 = atan(((eh / ew) / tan(t)));
	return fabs((((ew * sin(t)) * cos(t_1)) + ((eh * cos(t)) * sin(t_1))));
}
real(8) function code(eh, ew, t)
    real(8), intent (in) :: eh
    real(8), intent (in) :: ew
    real(8), intent (in) :: t
    real(8) :: t_1
    t_1 = atan(((eh / ew) / tan(t)))
    code = abs((((ew * sin(t)) * cos(t_1)) + ((eh * cos(t)) * sin(t_1))))
end function
public static double code(double eh, double ew, double t) {
	double t_1 = Math.atan(((eh / ew) / Math.tan(t)));
	return Math.abs((((ew * Math.sin(t)) * Math.cos(t_1)) + ((eh * Math.cos(t)) * Math.sin(t_1))));
}
def code(eh, ew, t):
	t_1 = math.atan(((eh / ew) / math.tan(t)))
	return math.fabs((((ew * math.sin(t)) * math.cos(t_1)) + ((eh * math.cos(t)) * math.sin(t_1))))
function code(eh, ew, t)
	t_1 = atan(Float64(Float64(eh / ew) / tan(t)))
	return abs(Float64(Float64(Float64(ew * sin(t)) * cos(t_1)) + Float64(Float64(eh * cos(t)) * sin(t_1))))
end
function tmp = code(eh, ew, t)
	t_1 = atan(((eh / ew) / tan(t)));
	tmp = abs((((ew * sin(t)) * cos(t_1)) + ((eh * cos(t)) * sin(t_1))));
end
code[eh_, ew_, t_] := Block[{t$95$1 = N[ArcTan[N[(N[(eh / ew), $MachinePrecision] / N[Tan[t], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, N[Abs[N[(N[(N[(ew * N[Sin[t], $MachinePrecision]), $MachinePrecision] * N[Cos[t$95$1], $MachinePrecision]), $MachinePrecision] + N[(N[(eh * N[Cos[t], $MachinePrecision]), $MachinePrecision] * N[Sin[t$95$1], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\\
\left|\left(ew \cdot \sin t\right) \cdot \cos t\_1 + \left(eh \cdot \cos t\right) \cdot \sin t\_1\right|
\end{array}
\end{array}

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

The average percentage accuracy by input value. Horizontal axis shows value of an input variable; the variable is choosen in the title. Vertical axis is accuracy; higher is better. Red represent the original program, while blue represents Herbie's suggestion. These can be toggled with buttons below the plot. The line is an average while dots represent individual samples.

Accuracy vs Speed?

Herbie found 10 alternatives:

AlternativeAccuracySpeedup
The accuracy (vertical axis) and speed (horizontal axis) of each alternatives. Up and to the right is better. The red square shows the initial program, and each blue circle shows an alternative.The line shows the best available speed-accuracy tradeoffs.

Initial Program: 99.8% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\\ \left|\left(ew \cdot \sin t\right) \cdot \cos t\_1 + \left(eh \cdot \cos t\right) \cdot \sin t\_1\right| \end{array} \end{array} \]
(FPCore (eh ew t)
 :precision binary64
 (let* ((t_1 (atan (/ (/ eh ew) (tan t)))))
   (fabs (+ (* (* ew (sin t)) (cos t_1)) (* (* eh (cos t)) (sin t_1))))))
double code(double eh, double ew, double t) {
	double t_1 = atan(((eh / ew) / tan(t)));
	return fabs((((ew * sin(t)) * cos(t_1)) + ((eh * cos(t)) * sin(t_1))));
}
real(8) function code(eh, ew, t)
    real(8), intent (in) :: eh
    real(8), intent (in) :: ew
    real(8), intent (in) :: t
    real(8) :: t_1
    t_1 = atan(((eh / ew) / tan(t)))
    code = abs((((ew * sin(t)) * cos(t_1)) + ((eh * cos(t)) * sin(t_1))))
end function
public static double code(double eh, double ew, double t) {
	double t_1 = Math.atan(((eh / ew) / Math.tan(t)));
	return Math.abs((((ew * Math.sin(t)) * Math.cos(t_1)) + ((eh * Math.cos(t)) * Math.sin(t_1))));
}
def code(eh, ew, t):
	t_1 = math.atan(((eh / ew) / math.tan(t)))
	return math.fabs((((ew * math.sin(t)) * math.cos(t_1)) + ((eh * math.cos(t)) * math.sin(t_1))))
function code(eh, ew, t)
	t_1 = atan(Float64(Float64(eh / ew) / tan(t)))
	return abs(Float64(Float64(Float64(ew * sin(t)) * cos(t_1)) + Float64(Float64(eh * cos(t)) * sin(t_1))))
end
function tmp = code(eh, ew, t)
	t_1 = atan(((eh / ew) / tan(t)));
	tmp = abs((((ew * sin(t)) * cos(t_1)) + ((eh * cos(t)) * sin(t_1))));
end
code[eh_, ew_, t_] := Block[{t$95$1 = N[ArcTan[N[(N[(eh / ew), $MachinePrecision] / N[Tan[t], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, N[Abs[N[(N[(N[(ew * N[Sin[t], $MachinePrecision]), $MachinePrecision] * N[Cos[t$95$1], $MachinePrecision]), $MachinePrecision] + N[(N[(eh * N[Cos[t], $MachinePrecision]), $MachinePrecision] * N[Sin[t$95$1], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\\
\left|\left(ew \cdot \sin t\right) \cdot \cos t\_1 + \left(eh \cdot \cos t\right) \cdot \sin t\_1\right|
\end{array}
\end{array}

Alternative 1: 99.8% accurate, 1.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{eh}{\tan t \cdot ew}\\ \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + {t\_1}^{2}}}, \sin t, \left(\cos t \cdot eh\right) \cdot \sin \tan^{-1} t\_1\right)\right| \end{array} \end{array} \]
(FPCore (eh ew t)
 :precision binary64
 (let* ((t_1 (/ eh (* (tan t) ew))))
   (fabs
    (fma
     (/ ew (sqrt (+ 1.0 (pow t_1 2.0))))
     (sin t)
     (* (* (cos t) eh) (sin (atan t_1)))))))
double code(double eh, double ew, double t) {
	double t_1 = eh / (tan(t) * ew);
	return fabs(fma((ew / sqrt((1.0 + pow(t_1, 2.0)))), sin(t), ((cos(t) * eh) * sin(atan(t_1)))));
}
function code(eh, ew, t)
	t_1 = Float64(eh / Float64(tan(t) * ew))
	return abs(fma(Float64(ew / sqrt(Float64(1.0 + (t_1 ^ 2.0)))), sin(t), Float64(Float64(cos(t) * eh) * sin(atan(t_1)))))
end
code[eh_, ew_, t_] := Block[{t$95$1 = N[(eh / N[(N[Tan[t], $MachinePrecision] * ew), $MachinePrecision]), $MachinePrecision]}, N[Abs[N[(N[(ew / N[Sqrt[N[(1.0 + N[Power[t$95$1, 2.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * N[Sin[t], $MachinePrecision] + N[(N[(N[Cos[t], $MachinePrecision] * eh), $MachinePrecision] * N[Sin[N[ArcTan[t$95$1], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{eh}{\tan t \cdot ew}\\
\left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + {t\_1}^{2}}}, \sin t, \left(\cos t \cdot eh\right) \cdot \sin \tan^{-1} t\_1\right)\right|
\end{array}
\end{array}
Derivation
  1. Initial program 99.8%

    \[\left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
  2. Add Preprocessing
  3. Step-by-step derivation
    1. lift-+.f64N/A

      \[\leadsto \left|\color{blue}{\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)}\right| \]
    2. lift-*.f64N/A

      \[\leadsto \left|\color{blue}{\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
    3. *-commutativeN/A

      \[\leadsto \left|\color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \left(ew \cdot \sin t\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
    4. lift-*.f64N/A

      \[\leadsto \left|\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \color{blue}{\left(ew \cdot \sin t\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
    5. associate-*r*N/A

      \[\leadsto \left|\color{blue}{\left(\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot ew\right) \cdot \sin t} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
    6. lower-fma.f64N/A

      \[\leadsto \left|\color{blue}{\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot ew, \sin t, \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right)}\right| \]
  4. Applied rewrites99.8%

    \[\leadsto \left|\color{blue}{\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot \left(\cos t \cdot eh\right)\right)}\right| \]
  5. Step-by-step derivation
    1. lift-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{\frac{eh}{\tan t}}{ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    2. lift-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{\color{blue}{\frac{eh}{\tan t}}}{ew}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    3. associate-/r*N/A

      \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{\tan t \cdot ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    4. lower-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{\tan t \cdot ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    5. *-commutativeN/A

      \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    6. lower-*.f6499.8

      \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
  6. Applied rewrites99.8%

    \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \tan t}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
  7. Step-by-step derivation
    1. lift-*.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    2. *-commutativeN/A

      \[\leadsto \left|\mathsf{fma}\left(\color{blue}{ew \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    3. lift-cos.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(ew \cdot \color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    4. lift-atan.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(ew \cdot \cos \color{blue}{\tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    5. cos-atanN/A

      \[\leadsto \left|\mathsf{fma}\left(ew \cdot \color{blue}{\frac{1}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    6. un-div-invN/A

      \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    7. lower-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    8. lift-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{\frac{eh}{\tan t}}{ew}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    9. lift-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{\color{blue}{\frac{eh}{\tan t}}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    10. associate-/l/N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{eh}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    11. lift-*.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{\color{blue}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    12. lift-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{eh}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    13. lift-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    14. lift-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \frac{\color{blue}{\frac{eh}{\tan t}}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    15. associate-/l/N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{eh}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    16. lift-*.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \frac{eh}{\color{blue}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    17. lift-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{eh}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
  8. Applied rewrites99.8%

    \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{{\left(\frac{\frac{eh}{\tan t}}{ew}\right)}^{2} + 1}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
  9. Step-by-step derivation
    1. lift-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{{\color{blue}{\left(\frac{\frac{eh}{\tan t}}{ew}\right)}}^{2} + 1}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    2. lift-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{{\left(\frac{\color{blue}{\frac{eh}{\tan t}}}{ew}\right)}^{2} + 1}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    3. associate-/l/N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{{\color{blue}{\left(\frac{eh}{ew \cdot \tan t}\right)}}^{2} + 1}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    4. lift-*.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{{\left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right)}^{2} + 1}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    5. lift-/.f6499.8

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{{\color{blue}{\left(\frac{eh}{ew \cdot \tan t}\right)}}^{2} + 1}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    6. lift-*.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{{\left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right)}^{2} + 1}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    7. *-commutativeN/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{{\left(\frac{eh}{\color{blue}{\tan t \cdot ew}}\right)}^{2} + 1}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    8. lower-*.f6499.8

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{{\left(\frac{eh}{\color{blue}{\tan t \cdot ew}}\right)}^{2} + 1}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
  10. Applied rewrites99.8%

    \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{{\color{blue}{\left(\frac{eh}{\tan t \cdot ew}\right)}}^{2} + 1}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
  11. Final simplification99.8%

    \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + {\left(\frac{eh}{\tan t \cdot ew}\right)}^{2}}}, \sin t, \left(\cos t \cdot eh\right) \cdot \sin \tan^{-1} \left(\frac{eh}{\tan t \cdot ew}\right)\right)\right| \]
  12. Add Preprocessing

Alternative 2: 99.0% accurate, 1.1× speedup?

\[\begin{array}{l} \\ \left|\sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \left(\cos t \cdot eh\right) + \cos \tan^{-1} \left(\frac{eh}{t \cdot ew}\right) \cdot \left(\sin t \cdot ew\right)\right| \end{array} \]
(FPCore (eh ew t)
 :precision binary64
 (fabs
  (+
   (* (sin (atan (/ (/ eh ew) (tan t)))) (* (cos t) eh))
   (* (cos (atan (/ eh (* t ew)))) (* (sin t) ew)))))
double code(double eh, double ew, double t) {
	return fabs(((sin(atan(((eh / ew) / tan(t)))) * (cos(t) * eh)) + (cos(atan((eh / (t * ew)))) * (sin(t) * ew))));
}
real(8) function code(eh, ew, t)
    real(8), intent (in) :: eh
    real(8), intent (in) :: ew
    real(8), intent (in) :: t
    code = abs(((sin(atan(((eh / ew) / tan(t)))) * (cos(t) * eh)) + (cos(atan((eh / (t * ew)))) * (sin(t) * ew))))
end function
public static double code(double eh, double ew, double t) {
	return Math.abs(((Math.sin(Math.atan(((eh / ew) / Math.tan(t)))) * (Math.cos(t) * eh)) + (Math.cos(Math.atan((eh / (t * ew)))) * (Math.sin(t) * ew))));
}
def code(eh, ew, t):
	return math.fabs(((math.sin(math.atan(((eh / ew) / math.tan(t)))) * (math.cos(t) * eh)) + (math.cos(math.atan((eh / (t * ew)))) * (math.sin(t) * ew))))
function code(eh, ew, t)
	return abs(Float64(Float64(sin(atan(Float64(Float64(eh / ew) / tan(t)))) * Float64(cos(t) * eh)) + Float64(cos(atan(Float64(eh / Float64(t * ew)))) * Float64(sin(t) * ew))))
end
function tmp = code(eh, ew, t)
	tmp = abs(((sin(atan(((eh / ew) / tan(t)))) * (cos(t) * eh)) + (cos(atan((eh / (t * ew)))) * (sin(t) * ew))));
end
code[eh_, ew_, t_] := N[Abs[N[(N[(N[Sin[N[ArcTan[N[(N[(eh / ew), $MachinePrecision] / N[Tan[t], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] * N[(N[Cos[t], $MachinePrecision] * eh), $MachinePrecision]), $MachinePrecision] + N[(N[Cos[N[ArcTan[N[(eh / N[(t * ew), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] * N[(N[Sin[t], $MachinePrecision] * ew), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}

\\
\left|\sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \left(\cos t \cdot eh\right) + \cos \tan^{-1} \left(\frac{eh}{t \cdot ew}\right) \cdot \left(\sin t \cdot ew\right)\right|
\end{array}
Derivation
  1. Initial program 99.8%

    \[\left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
  2. Add Preprocessing
  3. Taylor expanded in t around 0

    \[\leadsto \left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot t}\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
  4. Step-by-step derivation
    1. lower-/.f64N/A

      \[\leadsto \left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot t}\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
    2. *-commutativeN/A

      \[\leadsto \left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{eh}{\color{blue}{t \cdot ew}}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
    3. lower-*.f6498.8

      \[\leadsto \left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{eh}{\color{blue}{t \cdot ew}}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
  5. Applied rewrites98.8%

    \[\leadsto \left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \color{blue}{\left(\frac{eh}{t \cdot ew}\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
  6. Final simplification98.8%

    \[\leadsto \left|\sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \left(\cos t \cdot eh\right) + \cos \tan^{-1} \left(\frac{eh}{t \cdot ew}\right) \cdot \left(\sin t \cdot ew\right)\right| \]
  7. Add Preprocessing

Alternative 3: 74.5% accurate, 1.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \left|\sin \tan^{-1} \left(\frac{\frac{eh}{\sin t}}{ew} \cdot \cos t\right) \cdot \left(\cos t \cdot eh\right)\right|\\ \mathbf{if}\;eh \leq -2.25 \cdot 10^{-79}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;eh \leq 1.2 \cdot 10^{-62}:\\ \;\;\;\;\left|\sin t \cdot ew\right|\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (eh ew t)
 :precision binary64
 (let* ((t_1
         (fabs
          (* (sin (atan (* (/ (/ eh (sin t)) ew) (cos t)))) (* (cos t) eh)))))
   (if (<= eh -2.25e-79) t_1 (if (<= eh 1.2e-62) (fabs (* (sin t) ew)) t_1))))
double code(double eh, double ew, double t) {
	double t_1 = fabs((sin(atan((((eh / sin(t)) / ew) * cos(t)))) * (cos(t) * eh)));
	double tmp;
	if (eh <= -2.25e-79) {
		tmp = t_1;
	} else if (eh <= 1.2e-62) {
		tmp = fabs((sin(t) * ew));
	} else {
		tmp = t_1;
	}
	return tmp;
}
real(8) function code(eh, ew, t)
    real(8), intent (in) :: eh
    real(8), intent (in) :: ew
    real(8), intent (in) :: t
    real(8) :: t_1
    real(8) :: tmp
    t_1 = abs((sin(atan((((eh / sin(t)) / ew) * cos(t)))) * (cos(t) * eh)))
    if (eh <= (-2.25d-79)) then
        tmp = t_1
    else if (eh <= 1.2d-62) then
        tmp = abs((sin(t) * ew))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double eh, double ew, double t) {
	double t_1 = Math.abs((Math.sin(Math.atan((((eh / Math.sin(t)) / ew) * Math.cos(t)))) * (Math.cos(t) * eh)));
	double tmp;
	if (eh <= -2.25e-79) {
		tmp = t_1;
	} else if (eh <= 1.2e-62) {
		tmp = Math.abs((Math.sin(t) * ew));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(eh, ew, t):
	t_1 = math.fabs((math.sin(math.atan((((eh / math.sin(t)) / ew) * math.cos(t)))) * (math.cos(t) * eh)))
	tmp = 0
	if eh <= -2.25e-79:
		tmp = t_1
	elif eh <= 1.2e-62:
		tmp = math.fabs((math.sin(t) * ew))
	else:
		tmp = t_1
	return tmp
function code(eh, ew, t)
	t_1 = abs(Float64(sin(atan(Float64(Float64(Float64(eh / sin(t)) / ew) * cos(t)))) * Float64(cos(t) * eh)))
	tmp = 0.0
	if (eh <= -2.25e-79)
		tmp = t_1;
	elseif (eh <= 1.2e-62)
		tmp = abs(Float64(sin(t) * ew));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(eh, ew, t)
	t_1 = abs((sin(atan((((eh / sin(t)) / ew) * cos(t)))) * (cos(t) * eh)));
	tmp = 0.0;
	if (eh <= -2.25e-79)
		tmp = t_1;
	elseif (eh <= 1.2e-62)
		tmp = abs((sin(t) * ew));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[eh_, ew_, t_] := Block[{t$95$1 = N[Abs[N[(N[Sin[N[ArcTan[N[(N[(N[(eh / N[Sin[t], $MachinePrecision]), $MachinePrecision] / ew), $MachinePrecision] * N[Cos[t], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] * N[(N[Cos[t], $MachinePrecision] * eh), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[eh, -2.25e-79], t$95$1, If[LessEqual[eh, 1.2e-62], N[Abs[N[(N[Sin[t], $MachinePrecision] * ew), $MachinePrecision]], $MachinePrecision], t$95$1]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \left|\sin \tan^{-1} \left(\frac{\frac{eh}{\sin t}}{ew} \cdot \cos t\right) \cdot \left(\cos t \cdot eh\right)\right|\\
\mathbf{if}\;eh \leq -2.25 \cdot 10^{-79}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;eh \leq 1.2 \cdot 10^{-62}:\\
\;\;\;\;\left|\sin t \cdot ew\right|\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if eh < -2.2500000000000001e-79 or 1.19999999999999992e-62 < eh

    1. Initial program 99.9%

      \[\left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
    2. Add Preprocessing
    3. Taylor expanded in eh around inf

      \[\leadsto \left|\color{blue}{eh \cdot \left(\cos t \cdot \sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right)\right)}\right| \]
    4. Step-by-step derivation
      1. associate-*r*N/A

        \[\leadsto \left|\color{blue}{\left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right)}\right| \]
      2. *-commutativeN/A

        \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right) \cdot \left(eh \cdot \cos t\right)}\right| \]
      3. lower-*.f64N/A

        \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right) \cdot \left(eh \cdot \cos t\right)}\right| \]
      4. lower-sin.f64N/A

        \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right)} \cdot \left(eh \cdot \cos t\right)\right| \]
      5. lower-atan.f64N/A

        \[\leadsto \left|\sin \color{blue}{\tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right)} \cdot \left(eh \cdot \cos t\right)\right| \]
      6. *-commutativeN/A

        \[\leadsto \left|\sin \tan^{-1} \left(\frac{\color{blue}{\cos t \cdot eh}}{ew \cdot \sin t}\right) \cdot \left(eh \cdot \cos t\right)\right| \]
      7. associate-/l*N/A

        \[\leadsto \left|\sin \tan^{-1} \color{blue}{\left(\cos t \cdot \frac{eh}{ew \cdot \sin t}\right)} \cdot \left(eh \cdot \cos t\right)\right| \]
      8. *-commutativeN/A

        \[\leadsto \left|\sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \sin t} \cdot \cos t\right)} \cdot \left(eh \cdot \cos t\right)\right| \]
      9. lower-*.f64N/A

        \[\leadsto \left|\sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \sin t} \cdot \cos t\right)} \cdot \left(eh \cdot \cos t\right)\right| \]
      10. *-commutativeN/A

        \[\leadsto \left|\sin \tan^{-1} \left(\frac{eh}{\color{blue}{\sin t \cdot ew}} \cdot \cos t\right) \cdot \left(eh \cdot \cos t\right)\right| \]
      11. associate-/r*N/A

        \[\leadsto \left|\sin \tan^{-1} \left(\color{blue}{\frac{\frac{eh}{\sin t}}{ew}} \cdot \cos t\right) \cdot \left(eh \cdot \cos t\right)\right| \]
      12. lower-/.f64N/A

        \[\leadsto \left|\sin \tan^{-1} \left(\color{blue}{\frac{\frac{eh}{\sin t}}{ew}} \cdot \cos t\right) \cdot \left(eh \cdot \cos t\right)\right| \]
      13. lower-/.f64N/A

        \[\leadsto \left|\sin \tan^{-1} \left(\frac{\color{blue}{\frac{eh}{\sin t}}}{ew} \cdot \cos t\right) \cdot \left(eh \cdot \cos t\right)\right| \]
      14. lower-sin.f64N/A

        \[\leadsto \left|\sin \tan^{-1} \left(\frac{\frac{eh}{\color{blue}{\sin t}}}{ew} \cdot \cos t\right) \cdot \left(eh \cdot \cos t\right)\right| \]
      15. lower-cos.f64N/A

        \[\leadsto \left|\sin \tan^{-1} \left(\frac{\frac{eh}{\sin t}}{ew} \cdot \color{blue}{\cos t}\right) \cdot \left(eh \cdot \cos t\right)\right| \]
      16. *-commutativeN/A

        \[\leadsto \left|\sin \tan^{-1} \left(\frac{\frac{eh}{\sin t}}{ew} \cdot \cos t\right) \cdot \color{blue}{\left(\cos t \cdot eh\right)}\right| \]
    5. Applied rewrites82.5%

      \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{\frac{eh}{\sin t}}{ew} \cdot \cos t\right) \cdot \left(\cos t \cdot eh\right)}\right| \]

    if -2.2500000000000001e-79 < eh < 1.19999999999999992e-62

    1. Initial program 99.8%

      \[\left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. lift-+.f64N/A

        \[\leadsto \left|\color{blue}{\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)}\right| \]
      2. lift-*.f64N/A

        \[\leadsto \left|\color{blue}{\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
      3. *-commutativeN/A

        \[\leadsto \left|\color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \left(ew \cdot \sin t\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
      4. lift-*.f64N/A

        \[\leadsto \left|\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \color{blue}{\left(ew \cdot \sin t\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
      5. associate-*r*N/A

        \[\leadsto \left|\color{blue}{\left(\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot ew\right) \cdot \sin t} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
      6. lower-fma.f64N/A

        \[\leadsto \left|\color{blue}{\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot ew, \sin t, \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right)}\right| \]
    4. Applied rewrites99.8%

      \[\leadsto \left|\color{blue}{\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot \left(\cos t \cdot eh\right)\right)}\right| \]
    5. Step-by-step derivation
      1. lift-/.f64N/A

        \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{\frac{eh}{\tan t}}{ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      2. lift-/.f64N/A

        \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{\color{blue}{\frac{eh}{\tan t}}}{ew}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      3. associate-/r*N/A

        \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{\tan t \cdot ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      4. lower-/.f64N/A

        \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{\tan t \cdot ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      5. *-commutativeN/A

        \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      6. lower-*.f6499.8

        \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    6. Applied rewrites99.8%

      \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \tan t}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    7. Step-by-step derivation
      1. lift-*.f64N/A

        \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      2. *-commutativeN/A

        \[\leadsto \left|\mathsf{fma}\left(\color{blue}{ew \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      3. lift-cos.f64N/A

        \[\leadsto \left|\mathsf{fma}\left(ew \cdot \color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      4. lift-atan.f64N/A

        \[\leadsto \left|\mathsf{fma}\left(ew \cdot \cos \color{blue}{\tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      5. cos-atanN/A

        \[\leadsto \left|\mathsf{fma}\left(ew \cdot \color{blue}{\frac{1}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      6. un-div-invN/A

        \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      7. lower-/.f64N/A

        \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      8. lift-/.f64N/A

        \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{\frac{eh}{\tan t}}{ew}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      9. lift-/.f64N/A

        \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{\color{blue}{\frac{eh}{\tan t}}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      10. associate-/l/N/A

        \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{eh}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      11. lift-*.f64N/A

        \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{\color{blue}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      12. lift-/.f64N/A

        \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{eh}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      13. lift-/.f64N/A

        \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      14. lift-/.f64N/A

        \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \frac{\color{blue}{\frac{eh}{\tan t}}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      15. associate-/l/N/A

        \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{eh}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      16. lift-*.f64N/A

        \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \frac{eh}{\color{blue}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      17. lift-/.f64N/A

        \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{eh}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    8. Applied rewrites99.8%

      \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{{\left(\frac{\frac{eh}{\tan t}}{ew}\right)}^{2} + 1}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    9. Taylor expanded in eh around 0

      \[\leadsto \left|\color{blue}{ew \cdot \sin t}\right| \]
    10. Step-by-step derivation
      1. *-commutativeN/A

        \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]
      2. lower-*.f64N/A

        \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]
      3. lower-sin.f6472.8

        \[\leadsto \left|\color{blue}{\sin t} \cdot ew\right| \]
    11. Applied rewrites72.8%

      \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 4: 98.4% accurate, 1.6× speedup?

\[\begin{array}{l} \\ \left|\mathsf{fma}\left(\frac{ew}{1}, \sin t, \left(\cos t \cdot eh\right) \cdot \sin \tan^{-1} \left(\frac{eh}{\tan t \cdot ew}\right)\right)\right| \end{array} \]
(FPCore (eh ew t)
 :precision binary64
 (fabs
  (fma
   (/ ew 1.0)
   (sin t)
   (* (* (cos t) eh) (sin (atan (/ eh (* (tan t) ew))))))))
double code(double eh, double ew, double t) {
	return fabs(fma((ew / 1.0), sin(t), ((cos(t) * eh) * sin(atan((eh / (tan(t) * ew)))))));
}
function code(eh, ew, t)
	return abs(fma(Float64(ew / 1.0), sin(t), Float64(Float64(cos(t) * eh) * sin(atan(Float64(eh / Float64(tan(t) * ew)))))))
end
code[eh_, ew_, t_] := N[Abs[N[(N[(ew / 1.0), $MachinePrecision] * N[Sin[t], $MachinePrecision] + N[(N[(N[Cos[t], $MachinePrecision] * eh), $MachinePrecision] * N[Sin[N[ArcTan[N[(eh / N[(N[Tan[t], $MachinePrecision] * ew), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}

\\
\left|\mathsf{fma}\left(\frac{ew}{1}, \sin t, \left(\cos t \cdot eh\right) \cdot \sin \tan^{-1} \left(\frac{eh}{\tan t \cdot ew}\right)\right)\right|
\end{array}
Derivation
  1. Initial program 99.8%

    \[\left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
  2. Add Preprocessing
  3. Step-by-step derivation
    1. lift-+.f64N/A

      \[\leadsto \left|\color{blue}{\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)}\right| \]
    2. lift-*.f64N/A

      \[\leadsto \left|\color{blue}{\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
    3. *-commutativeN/A

      \[\leadsto \left|\color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \left(ew \cdot \sin t\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
    4. lift-*.f64N/A

      \[\leadsto \left|\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \color{blue}{\left(ew \cdot \sin t\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
    5. associate-*r*N/A

      \[\leadsto \left|\color{blue}{\left(\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot ew\right) \cdot \sin t} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
    6. lower-fma.f64N/A

      \[\leadsto \left|\color{blue}{\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot ew, \sin t, \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right)}\right| \]
  4. Applied rewrites99.8%

    \[\leadsto \left|\color{blue}{\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot \left(\cos t \cdot eh\right)\right)}\right| \]
  5. Step-by-step derivation
    1. lift-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{\frac{eh}{\tan t}}{ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    2. lift-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{\color{blue}{\frac{eh}{\tan t}}}{ew}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    3. associate-/r*N/A

      \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{\tan t \cdot ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    4. lower-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{\tan t \cdot ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    5. *-commutativeN/A

      \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    6. lower-*.f6499.8

      \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
  6. Applied rewrites99.8%

    \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \tan t}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
  7. Step-by-step derivation
    1. lift-*.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    2. *-commutativeN/A

      \[\leadsto \left|\mathsf{fma}\left(\color{blue}{ew \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    3. lift-cos.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(ew \cdot \color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    4. lift-atan.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(ew \cdot \cos \color{blue}{\tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    5. cos-atanN/A

      \[\leadsto \left|\mathsf{fma}\left(ew \cdot \color{blue}{\frac{1}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    6. un-div-invN/A

      \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    7. lower-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    8. lift-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{\frac{eh}{\tan t}}{ew}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    9. lift-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{\color{blue}{\frac{eh}{\tan t}}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    10. associate-/l/N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{eh}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    11. lift-*.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{\color{blue}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    12. lift-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{eh}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    13. lift-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    14. lift-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \frac{\color{blue}{\frac{eh}{\tan t}}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    15. associate-/l/N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{eh}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    16. lift-*.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \frac{eh}{\color{blue}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    17. lift-/.f64N/A

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{eh}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
  8. Applied rewrites99.8%

    \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{{\left(\frac{\frac{eh}{\tan t}}{ew}\right)}^{2} + 1}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
  9. Taylor expanded in eh around 0

    \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\color{blue}{1}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
  10. Step-by-step derivation
    1. Applied rewrites98.7%

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\color{blue}{1}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
    2. Final simplification98.7%

      \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{1}, \sin t, \left(\cos t \cdot eh\right) \cdot \sin \tan^{-1} \left(\frac{eh}{\tan t \cdot ew}\right)\right)\right| \]
    3. Add Preprocessing

    Alternative 5: 61.2% accurate, 3.3× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left|\sin t \cdot ew\right|\\ \mathbf{if}\;t \leq -0.0013:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t \leq 4.5 \cdot 10^{-38}:\\ \;\;\;\;\left|\sin \tan^{-1} \left(\frac{1}{\frac{t}{\mathsf{fma}\left(t \cdot t, -0.3333333333333333, 1\right) \cdot eh} \cdot ew}\right) \cdot eh\right|\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
    (FPCore (eh ew t)
     :precision binary64
     (let* ((t_1 (fabs (* (sin t) ew))))
       (if (<= t -0.0013)
         t_1
         (if (<= t 4.5e-38)
           (fabs
            (*
             (sin
              (atan
               (/ 1.0 (* (/ t (* (fma (* t t) -0.3333333333333333 1.0) eh)) ew))))
             eh))
           t_1))))
    double code(double eh, double ew, double t) {
    	double t_1 = fabs((sin(t) * ew));
    	double tmp;
    	if (t <= -0.0013) {
    		tmp = t_1;
    	} else if (t <= 4.5e-38) {
    		tmp = fabs((sin(atan((1.0 / ((t / (fma((t * t), -0.3333333333333333, 1.0) * eh)) * ew)))) * eh));
    	} else {
    		tmp = t_1;
    	}
    	return tmp;
    }
    
    function code(eh, ew, t)
    	t_1 = abs(Float64(sin(t) * ew))
    	tmp = 0.0
    	if (t <= -0.0013)
    		tmp = t_1;
    	elseif (t <= 4.5e-38)
    		tmp = abs(Float64(sin(atan(Float64(1.0 / Float64(Float64(t / Float64(fma(Float64(t * t), -0.3333333333333333, 1.0) * eh)) * ew)))) * eh));
    	else
    		tmp = t_1;
    	end
    	return tmp
    end
    
    code[eh_, ew_, t_] := Block[{t$95$1 = N[Abs[N[(N[Sin[t], $MachinePrecision] * ew), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[t, -0.0013], t$95$1, If[LessEqual[t, 4.5e-38], N[Abs[N[(N[Sin[N[ArcTan[N[(1.0 / N[(N[(t / N[(N[(N[(t * t), $MachinePrecision] * -0.3333333333333333 + 1.0), $MachinePrecision] * eh), $MachinePrecision]), $MachinePrecision] * ew), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] * eh), $MachinePrecision]], $MachinePrecision], t$95$1]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_1 := \left|\sin t \cdot ew\right|\\
    \mathbf{if}\;t \leq -0.0013:\\
    \;\;\;\;t\_1\\
    
    \mathbf{elif}\;t \leq 4.5 \cdot 10^{-38}:\\
    \;\;\;\;\left|\sin \tan^{-1} \left(\frac{1}{\frac{t}{\mathsf{fma}\left(t \cdot t, -0.3333333333333333, 1\right) \cdot eh} \cdot ew}\right) \cdot eh\right|\\
    
    \mathbf{else}:\\
    \;\;\;\;t\_1\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if t < -0.0012999999999999999 or 4.50000000000000009e-38 < t

      1. Initial program 99.7%

        \[\left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
      2. Add Preprocessing
      3. Step-by-step derivation
        1. lift-+.f64N/A

          \[\leadsto \left|\color{blue}{\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)}\right| \]
        2. lift-*.f64N/A

          \[\leadsto \left|\color{blue}{\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
        3. *-commutativeN/A

          \[\leadsto \left|\color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \left(ew \cdot \sin t\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
        4. lift-*.f64N/A

          \[\leadsto \left|\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \color{blue}{\left(ew \cdot \sin t\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
        5. associate-*r*N/A

          \[\leadsto \left|\color{blue}{\left(\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot ew\right) \cdot \sin t} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
        6. lower-fma.f64N/A

          \[\leadsto \left|\color{blue}{\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot ew, \sin t, \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right)}\right| \]
      4. Applied rewrites99.7%

        \[\leadsto \left|\color{blue}{\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot \left(\cos t \cdot eh\right)\right)}\right| \]
      5. Step-by-step derivation
        1. lift-/.f64N/A

          \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{\frac{eh}{\tan t}}{ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        2. lift-/.f64N/A

          \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{\color{blue}{\frac{eh}{\tan t}}}{ew}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        3. associate-/r*N/A

          \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{\tan t \cdot ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        4. lower-/.f64N/A

          \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{\tan t \cdot ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        5. *-commutativeN/A

          \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        6. lower-*.f6499.7

          \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      6. Applied rewrites99.7%

        \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \tan t}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      7. Step-by-step derivation
        1. lift-*.f64N/A

          \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        2. *-commutativeN/A

          \[\leadsto \left|\mathsf{fma}\left(\color{blue}{ew \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        3. lift-cos.f64N/A

          \[\leadsto \left|\mathsf{fma}\left(ew \cdot \color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        4. lift-atan.f64N/A

          \[\leadsto \left|\mathsf{fma}\left(ew \cdot \cos \color{blue}{\tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        5. cos-atanN/A

          \[\leadsto \left|\mathsf{fma}\left(ew \cdot \color{blue}{\frac{1}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        6. un-div-invN/A

          \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        7. lower-/.f64N/A

          \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        8. lift-/.f64N/A

          \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{\frac{eh}{\tan t}}{ew}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        9. lift-/.f64N/A

          \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{\color{blue}{\frac{eh}{\tan t}}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        10. associate-/l/N/A

          \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{eh}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        11. lift-*.f64N/A

          \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{\color{blue}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        12. lift-/.f64N/A

          \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{eh}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        13. lift-/.f64N/A

          \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        14. lift-/.f64N/A

          \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \frac{\color{blue}{\frac{eh}{\tan t}}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        15. associate-/l/N/A

          \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{eh}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        16. lift-*.f64N/A

          \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \frac{eh}{\color{blue}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
        17. lift-/.f64N/A

          \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{eh}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      8. Applied rewrites99.7%

        \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{{\left(\frac{\frac{eh}{\tan t}}{ew}\right)}^{2} + 1}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
      9. Taylor expanded in eh around 0

        \[\leadsto \left|\color{blue}{ew \cdot \sin t}\right| \]
      10. Step-by-step derivation
        1. *-commutativeN/A

          \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]
        2. lower-*.f64N/A

          \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]
        3. lower-sin.f6450.9

          \[\leadsto \left|\color{blue}{\sin t} \cdot ew\right| \]
      11. Applied rewrites50.9%

        \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]

      if -0.0012999999999999999 < t < 4.50000000000000009e-38

      1. Initial program 100.0%

        \[\left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
      2. Add Preprocessing
      3. Taylor expanded in t around 0

        \[\leadsto \left|\color{blue}{eh \cdot \sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right)}\right| \]
      4. Step-by-step derivation
        1. *-commutativeN/A

          \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right) \cdot eh}\right| \]
        2. lower-*.f64N/A

          \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right) \cdot eh}\right| \]
        3. lower-sin.f64N/A

          \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right)} \cdot eh\right| \]
        4. lower-atan.f64N/A

          \[\leadsto \left|\sin \color{blue}{\tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right)} \cdot eh\right| \]
        5. *-commutativeN/A

          \[\leadsto \left|\sin \tan^{-1} \left(\frac{\color{blue}{\cos t \cdot eh}}{ew \cdot \sin t}\right) \cdot eh\right| \]
        6. associate-/l*N/A

          \[\leadsto \left|\sin \tan^{-1} \color{blue}{\left(\cos t \cdot \frac{eh}{ew \cdot \sin t}\right)} \cdot eh\right| \]
        7. *-commutativeN/A

          \[\leadsto \left|\sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \sin t} \cdot \cos t\right)} \cdot eh\right| \]
        8. lower-*.f64N/A

          \[\leadsto \left|\sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \sin t} \cdot \cos t\right)} \cdot eh\right| \]
        9. *-commutativeN/A

          \[\leadsto \left|\sin \tan^{-1} \left(\frac{eh}{\color{blue}{\sin t \cdot ew}} \cdot \cos t\right) \cdot eh\right| \]
        10. associate-/r*N/A

          \[\leadsto \left|\sin \tan^{-1} \left(\color{blue}{\frac{\frac{eh}{\sin t}}{ew}} \cdot \cos t\right) \cdot eh\right| \]
        11. lower-/.f64N/A

          \[\leadsto \left|\sin \tan^{-1} \left(\color{blue}{\frac{\frac{eh}{\sin t}}{ew}} \cdot \cos t\right) \cdot eh\right| \]
        12. lower-/.f64N/A

          \[\leadsto \left|\sin \tan^{-1} \left(\frac{\color{blue}{\frac{eh}{\sin t}}}{ew} \cdot \cos t\right) \cdot eh\right| \]
        13. lower-sin.f64N/A

          \[\leadsto \left|\sin \tan^{-1} \left(\frac{\frac{eh}{\color{blue}{\sin t}}}{ew} \cdot \cos t\right) \cdot eh\right| \]
        14. lower-cos.f6477.4

          \[\leadsto \left|\sin \tan^{-1} \left(\frac{\frac{eh}{\sin t}}{ew} \cdot \color{blue}{\cos t}\right) \cdot eh\right| \]
      5. Applied rewrites77.4%

        \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{\frac{eh}{\sin t}}{ew} \cdot \cos t\right) \cdot eh}\right| \]
      6. Taylor expanded in t around 0

        \[\leadsto \left|\sin \tan^{-1} \left(\frac{{t}^{2} \cdot \left(\frac{-1}{2} \cdot \frac{eh}{ew} - \frac{-1}{6} \cdot \frac{eh}{ew}\right) + \frac{eh}{ew}}{t}\right) \cdot eh\right| \]
      7. Step-by-step derivation
        1. Applied rewrites67.1%

          \[\leadsto \left|\sin \tan^{-1} \left(\frac{\mathsf{fma}\left(-0.3333333333333333 \cdot \frac{eh}{ew}, t \cdot t, \frac{eh}{ew}\right)}{t}\right) \cdot eh\right| \]
        2. Step-by-step derivation
          1. Applied rewrites77.4%

            \[\leadsto \left|\sin \tan^{-1} \left(\frac{1}{\frac{t}{\mathsf{fma}\left(t \cdot t, -0.3333333333333333, 1\right) \cdot eh} \cdot ew}\right) \cdot eh\right| \]
        3. Recombined 2 regimes into one program.
        4. Add Preprocessing

        Alternative 6: 61.2% accurate, 3.5× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left|\sin t \cdot ew\right|\\ \mathbf{if}\;t \leq -0.0013:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t \leq 4.5 \cdot 10^{-38}:\\ \;\;\;\;\left|\sin \tan^{-1} \left(\frac{\mathsf{fma}\left(t \cdot t, -0.3333333333333333, 1\right) \cdot eh}{t \cdot ew}\right) \cdot eh\right|\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
        (FPCore (eh ew t)
         :precision binary64
         (let* ((t_1 (fabs (* (sin t) ew))))
           (if (<= t -0.0013)
             t_1
             (if (<= t 4.5e-38)
               (fabs
                (*
                 (sin (atan (/ (* (fma (* t t) -0.3333333333333333 1.0) eh) (* t ew))))
                 eh))
               t_1))))
        double code(double eh, double ew, double t) {
        	double t_1 = fabs((sin(t) * ew));
        	double tmp;
        	if (t <= -0.0013) {
        		tmp = t_1;
        	} else if (t <= 4.5e-38) {
        		tmp = fabs((sin(atan(((fma((t * t), -0.3333333333333333, 1.0) * eh) / (t * ew)))) * eh));
        	} else {
        		tmp = t_1;
        	}
        	return tmp;
        }
        
        function code(eh, ew, t)
        	t_1 = abs(Float64(sin(t) * ew))
        	tmp = 0.0
        	if (t <= -0.0013)
        		tmp = t_1;
        	elseif (t <= 4.5e-38)
        		tmp = abs(Float64(sin(atan(Float64(Float64(fma(Float64(t * t), -0.3333333333333333, 1.0) * eh) / Float64(t * ew)))) * eh));
        	else
        		tmp = t_1;
        	end
        	return tmp
        end
        
        code[eh_, ew_, t_] := Block[{t$95$1 = N[Abs[N[(N[Sin[t], $MachinePrecision] * ew), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[t, -0.0013], t$95$1, If[LessEqual[t, 4.5e-38], N[Abs[N[(N[Sin[N[ArcTan[N[(N[(N[(N[(t * t), $MachinePrecision] * -0.3333333333333333 + 1.0), $MachinePrecision] * eh), $MachinePrecision] / N[(t * ew), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] * eh), $MachinePrecision]], $MachinePrecision], t$95$1]]]
        
        \begin{array}{l}
        
        \\
        \begin{array}{l}
        t_1 := \left|\sin t \cdot ew\right|\\
        \mathbf{if}\;t \leq -0.0013:\\
        \;\;\;\;t\_1\\
        
        \mathbf{elif}\;t \leq 4.5 \cdot 10^{-38}:\\
        \;\;\;\;\left|\sin \tan^{-1} \left(\frac{\mathsf{fma}\left(t \cdot t, -0.3333333333333333, 1\right) \cdot eh}{t \cdot ew}\right) \cdot eh\right|\\
        
        \mathbf{else}:\\
        \;\;\;\;t\_1\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 2 regimes
        2. if t < -0.0012999999999999999 or 4.50000000000000009e-38 < t

          1. Initial program 99.7%

            \[\left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
          2. Add Preprocessing
          3. Step-by-step derivation
            1. lift-+.f64N/A

              \[\leadsto \left|\color{blue}{\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)}\right| \]
            2. lift-*.f64N/A

              \[\leadsto \left|\color{blue}{\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
            3. *-commutativeN/A

              \[\leadsto \left|\color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \left(ew \cdot \sin t\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
            4. lift-*.f64N/A

              \[\leadsto \left|\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \color{blue}{\left(ew \cdot \sin t\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
            5. associate-*r*N/A

              \[\leadsto \left|\color{blue}{\left(\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot ew\right) \cdot \sin t} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
            6. lower-fma.f64N/A

              \[\leadsto \left|\color{blue}{\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot ew, \sin t, \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right)}\right| \]
          4. Applied rewrites99.7%

            \[\leadsto \left|\color{blue}{\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot \left(\cos t \cdot eh\right)\right)}\right| \]
          5. Step-by-step derivation
            1. lift-/.f64N/A

              \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{\frac{eh}{\tan t}}{ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            2. lift-/.f64N/A

              \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{\color{blue}{\frac{eh}{\tan t}}}{ew}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            3. associate-/r*N/A

              \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{\tan t \cdot ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            4. lower-/.f64N/A

              \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{\tan t \cdot ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            5. *-commutativeN/A

              \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            6. lower-*.f6499.7

              \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
          6. Applied rewrites99.7%

            \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \tan t}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
          7. Step-by-step derivation
            1. lift-*.f64N/A

              \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            2. *-commutativeN/A

              \[\leadsto \left|\mathsf{fma}\left(\color{blue}{ew \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            3. lift-cos.f64N/A

              \[\leadsto \left|\mathsf{fma}\left(ew \cdot \color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            4. lift-atan.f64N/A

              \[\leadsto \left|\mathsf{fma}\left(ew \cdot \cos \color{blue}{\tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            5. cos-atanN/A

              \[\leadsto \left|\mathsf{fma}\left(ew \cdot \color{blue}{\frac{1}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            6. un-div-invN/A

              \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            7. lower-/.f64N/A

              \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            8. lift-/.f64N/A

              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{\frac{eh}{\tan t}}{ew}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            9. lift-/.f64N/A

              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{\color{blue}{\frac{eh}{\tan t}}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            10. associate-/l/N/A

              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{eh}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            11. lift-*.f64N/A

              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{\color{blue}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            12. lift-/.f64N/A

              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{eh}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            13. lift-/.f64N/A

              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            14. lift-/.f64N/A

              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \frac{\color{blue}{\frac{eh}{\tan t}}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            15. associate-/l/N/A

              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{eh}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            16. lift-*.f64N/A

              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \frac{eh}{\color{blue}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
            17. lift-/.f64N/A

              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{eh}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
          8. Applied rewrites99.7%

            \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{{\left(\frac{\frac{eh}{\tan t}}{ew}\right)}^{2} + 1}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
          9. Taylor expanded in eh around 0

            \[\leadsto \left|\color{blue}{ew \cdot \sin t}\right| \]
          10. Step-by-step derivation
            1. *-commutativeN/A

              \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]
            2. lower-*.f64N/A

              \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]
            3. lower-sin.f6450.9

              \[\leadsto \left|\color{blue}{\sin t} \cdot ew\right| \]
          11. Applied rewrites50.9%

            \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]

          if -0.0012999999999999999 < t < 4.50000000000000009e-38

          1. Initial program 100.0%

            \[\left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
          2. Add Preprocessing
          3. Taylor expanded in t around 0

            \[\leadsto \left|\color{blue}{eh \cdot \sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right)}\right| \]
          4. Step-by-step derivation
            1. *-commutativeN/A

              \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right) \cdot eh}\right| \]
            2. lower-*.f64N/A

              \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right) \cdot eh}\right| \]
            3. lower-sin.f64N/A

              \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right)} \cdot eh\right| \]
            4. lower-atan.f64N/A

              \[\leadsto \left|\sin \color{blue}{\tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right)} \cdot eh\right| \]
            5. *-commutativeN/A

              \[\leadsto \left|\sin \tan^{-1} \left(\frac{\color{blue}{\cos t \cdot eh}}{ew \cdot \sin t}\right) \cdot eh\right| \]
            6. associate-/l*N/A

              \[\leadsto \left|\sin \tan^{-1} \color{blue}{\left(\cos t \cdot \frac{eh}{ew \cdot \sin t}\right)} \cdot eh\right| \]
            7. *-commutativeN/A

              \[\leadsto \left|\sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \sin t} \cdot \cos t\right)} \cdot eh\right| \]
            8. lower-*.f64N/A

              \[\leadsto \left|\sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \sin t} \cdot \cos t\right)} \cdot eh\right| \]
            9. *-commutativeN/A

              \[\leadsto \left|\sin \tan^{-1} \left(\frac{eh}{\color{blue}{\sin t \cdot ew}} \cdot \cos t\right) \cdot eh\right| \]
            10. associate-/r*N/A

              \[\leadsto \left|\sin \tan^{-1} \left(\color{blue}{\frac{\frac{eh}{\sin t}}{ew}} \cdot \cos t\right) \cdot eh\right| \]
            11. lower-/.f64N/A

              \[\leadsto \left|\sin \tan^{-1} \left(\color{blue}{\frac{\frac{eh}{\sin t}}{ew}} \cdot \cos t\right) \cdot eh\right| \]
            12. lower-/.f64N/A

              \[\leadsto \left|\sin \tan^{-1} \left(\frac{\color{blue}{\frac{eh}{\sin t}}}{ew} \cdot \cos t\right) \cdot eh\right| \]
            13. lower-sin.f64N/A

              \[\leadsto \left|\sin \tan^{-1} \left(\frac{\frac{eh}{\color{blue}{\sin t}}}{ew} \cdot \cos t\right) \cdot eh\right| \]
            14. lower-cos.f6477.4

              \[\leadsto \left|\sin \tan^{-1} \left(\frac{\frac{eh}{\sin t}}{ew} \cdot \color{blue}{\cos t}\right) \cdot eh\right| \]
          5. Applied rewrites77.4%

            \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{\frac{eh}{\sin t}}{ew} \cdot \cos t\right) \cdot eh}\right| \]
          6. Taylor expanded in t around 0

            \[\leadsto \left|\sin \tan^{-1} \left(\frac{{t}^{2} \cdot \left(\frac{-1}{2} \cdot \frac{eh}{ew} - \frac{-1}{6} \cdot \frac{eh}{ew}\right) + \frac{eh}{ew}}{t}\right) \cdot eh\right| \]
          7. Step-by-step derivation
            1. Applied rewrites67.1%

              \[\leadsto \left|\sin \tan^{-1} \left(\frac{\mathsf{fma}\left(-0.3333333333333333 \cdot \frac{eh}{ew}, t \cdot t, \frac{eh}{ew}\right)}{t}\right) \cdot eh\right| \]
            2. Step-by-step derivation
              1. Applied rewrites77.4%

                \[\leadsto \left|\sin \tan^{-1} \left(\frac{\mathsf{fma}\left(t \cdot t, -0.3333333333333333, 1\right) \cdot eh}{t \cdot ew}\right) \cdot eh\right| \]
            3. Recombined 2 regimes into one program.
            4. Add Preprocessing

            Alternative 7: 61.2% accurate, 3.6× speedup?

            \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left|\sin t \cdot ew\right|\\ \mathbf{if}\;t \leq -0.0013:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t \leq 4.5 \cdot 10^{-38}:\\ \;\;\;\;\left|\sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{t}\right) \cdot eh\right|\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
            (FPCore (eh ew t)
             :precision binary64
             (let* ((t_1 (fabs (* (sin t) ew))))
               (if (<= t -0.0013)
                 t_1
                 (if (<= t 4.5e-38) (fabs (* (sin (atan (/ (/ eh ew) t))) eh)) t_1))))
            double code(double eh, double ew, double t) {
            	double t_1 = fabs((sin(t) * ew));
            	double tmp;
            	if (t <= -0.0013) {
            		tmp = t_1;
            	} else if (t <= 4.5e-38) {
            		tmp = fabs((sin(atan(((eh / ew) / t))) * eh));
            	} else {
            		tmp = t_1;
            	}
            	return tmp;
            }
            
            real(8) function code(eh, ew, t)
                real(8), intent (in) :: eh
                real(8), intent (in) :: ew
                real(8), intent (in) :: t
                real(8) :: t_1
                real(8) :: tmp
                t_1 = abs((sin(t) * ew))
                if (t <= (-0.0013d0)) then
                    tmp = t_1
                else if (t <= 4.5d-38) then
                    tmp = abs((sin(atan(((eh / ew) / t))) * eh))
                else
                    tmp = t_1
                end if
                code = tmp
            end function
            
            public static double code(double eh, double ew, double t) {
            	double t_1 = Math.abs((Math.sin(t) * ew));
            	double tmp;
            	if (t <= -0.0013) {
            		tmp = t_1;
            	} else if (t <= 4.5e-38) {
            		tmp = Math.abs((Math.sin(Math.atan(((eh / ew) / t))) * eh));
            	} else {
            		tmp = t_1;
            	}
            	return tmp;
            }
            
            def code(eh, ew, t):
            	t_1 = math.fabs((math.sin(t) * ew))
            	tmp = 0
            	if t <= -0.0013:
            		tmp = t_1
            	elif t <= 4.5e-38:
            		tmp = math.fabs((math.sin(math.atan(((eh / ew) / t))) * eh))
            	else:
            		tmp = t_1
            	return tmp
            
            function code(eh, ew, t)
            	t_1 = abs(Float64(sin(t) * ew))
            	tmp = 0.0
            	if (t <= -0.0013)
            		tmp = t_1;
            	elseif (t <= 4.5e-38)
            		tmp = abs(Float64(sin(atan(Float64(Float64(eh / ew) / t))) * eh));
            	else
            		tmp = t_1;
            	end
            	return tmp
            end
            
            function tmp_2 = code(eh, ew, t)
            	t_1 = abs((sin(t) * ew));
            	tmp = 0.0;
            	if (t <= -0.0013)
            		tmp = t_1;
            	elseif (t <= 4.5e-38)
            		tmp = abs((sin(atan(((eh / ew) / t))) * eh));
            	else
            		tmp = t_1;
            	end
            	tmp_2 = tmp;
            end
            
            code[eh_, ew_, t_] := Block[{t$95$1 = N[Abs[N[(N[Sin[t], $MachinePrecision] * ew), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[t, -0.0013], t$95$1, If[LessEqual[t, 4.5e-38], N[Abs[N[(N[Sin[N[ArcTan[N[(N[(eh / ew), $MachinePrecision] / t), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] * eh), $MachinePrecision]], $MachinePrecision], t$95$1]]]
            
            \begin{array}{l}
            
            \\
            \begin{array}{l}
            t_1 := \left|\sin t \cdot ew\right|\\
            \mathbf{if}\;t \leq -0.0013:\\
            \;\;\;\;t\_1\\
            
            \mathbf{elif}\;t \leq 4.5 \cdot 10^{-38}:\\
            \;\;\;\;\left|\sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{t}\right) \cdot eh\right|\\
            
            \mathbf{else}:\\
            \;\;\;\;t\_1\\
            
            
            \end{array}
            \end{array}
            
            Derivation
            1. Split input into 2 regimes
            2. if t < -0.0012999999999999999 or 4.50000000000000009e-38 < t

              1. Initial program 99.7%

                \[\left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
              2. Add Preprocessing
              3. Step-by-step derivation
                1. lift-+.f64N/A

                  \[\leadsto \left|\color{blue}{\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)}\right| \]
                2. lift-*.f64N/A

                  \[\leadsto \left|\color{blue}{\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                3. *-commutativeN/A

                  \[\leadsto \left|\color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \left(ew \cdot \sin t\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                4. lift-*.f64N/A

                  \[\leadsto \left|\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \color{blue}{\left(ew \cdot \sin t\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                5. associate-*r*N/A

                  \[\leadsto \left|\color{blue}{\left(\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot ew\right) \cdot \sin t} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                6. lower-fma.f64N/A

                  \[\leadsto \left|\color{blue}{\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot ew, \sin t, \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right)}\right| \]
              4. Applied rewrites99.7%

                \[\leadsto \left|\color{blue}{\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot \left(\cos t \cdot eh\right)\right)}\right| \]
              5. Step-by-step derivation
                1. lift-/.f64N/A

                  \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{\frac{eh}{\tan t}}{ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                2. lift-/.f64N/A

                  \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{\color{blue}{\frac{eh}{\tan t}}}{ew}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                3. associate-/r*N/A

                  \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{\tan t \cdot ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                4. lower-/.f64N/A

                  \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{\tan t \cdot ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                5. *-commutativeN/A

                  \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                6. lower-*.f6499.7

                  \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
              6. Applied rewrites99.7%

                \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \tan t}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
              7. Step-by-step derivation
                1. lift-*.f64N/A

                  \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                2. *-commutativeN/A

                  \[\leadsto \left|\mathsf{fma}\left(\color{blue}{ew \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                3. lift-cos.f64N/A

                  \[\leadsto \left|\mathsf{fma}\left(ew \cdot \color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                4. lift-atan.f64N/A

                  \[\leadsto \left|\mathsf{fma}\left(ew \cdot \cos \color{blue}{\tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                5. cos-atanN/A

                  \[\leadsto \left|\mathsf{fma}\left(ew \cdot \color{blue}{\frac{1}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                6. un-div-invN/A

                  \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                7. lower-/.f64N/A

                  \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                8. lift-/.f64N/A

                  \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{\frac{eh}{\tan t}}{ew}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                9. lift-/.f64N/A

                  \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{\color{blue}{\frac{eh}{\tan t}}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                10. associate-/l/N/A

                  \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{eh}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                11. lift-*.f64N/A

                  \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{\color{blue}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                12. lift-/.f64N/A

                  \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{eh}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                13. lift-/.f64N/A

                  \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                14. lift-/.f64N/A

                  \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \frac{\color{blue}{\frac{eh}{\tan t}}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                15. associate-/l/N/A

                  \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{eh}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                16. lift-*.f64N/A

                  \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \frac{eh}{\color{blue}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                17. lift-/.f64N/A

                  \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{eh}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
              8. Applied rewrites99.7%

                \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{{\left(\frac{\frac{eh}{\tan t}}{ew}\right)}^{2} + 1}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
              9. Taylor expanded in eh around 0

                \[\leadsto \left|\color{blue}{ew \cdot \sin t}\right| \]
              10. Step-by-step derivation
                1. *-commutativeN/A

                  \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]
                2. lower-*.f64N/A

                  \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]
                3. lower-sin.f6450.9

                  \[\leadsto \left|\color{blue}{\sin t} \cdot ew\right| \]
              11. Applied rewrites50.9%

                \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]

              if -0.0012999999999999999 < t < 4.50000000000000009e-38

              1. Initial program 100.0%

                \[\left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
              2. Add Preprocessing
              3. Taylor expanded in t around 0

                \[\leadsto \left|\color{blue}{eh \cdot \sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right)}\right| \]
              4. Step-by-step derivation
                1. *-commutativeN/A

                  \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right) \cdot eh}\right| \]
                2. lower-*.f64N/A

                  \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right) \cdot eh}\right| \]
                3. lower-sin.f64N/A

                  \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right)} \cdot eh\right| \]
                4. lower-atan.f64N/A

                  \[\leadsto \left|\sin \color{blue}{\tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right)} \cdot eh\right| \]
                5. *-commutativeN/A

                  \[\leadsto \left|\sin \tan^{-1} \left(\frac{\color{blue}{\cos t \cdot eh}}{ew \cdot \sin t}\right) \cdot eh\right| \]
                6. associate-/l*N/A

                  \[\leadsto \left|\sin \tan^{-1} \color{blue}{\left(\cos t \cdot \frac{eh}{ew \cdot \sin t}\right)} \cdot eh\right| \]
                7. *-commutativeN/A

                  \[\leadsto \left|\sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \sin t} \cdot \cos t\right)} \cdot eh\right| \]
                8. lower-*.f64N/A

                  \[\leadsto \left|\sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \sin t} \cdot \cos t\right)} \cdot eh\right| \]
                9. *-commutativeN/A

                  \[\leadsto \left|\sin \tan^{-1} \left(\frac{eh}{\color{blue}{\sin t \cdot ew}} \cdot \cos t\right) \cdot eh\right| \]
                10. associate-/r*N/A

                  \[\leadsto \left|\sin \tan^{-1} \left(\color{blue}{\frac{\frac{eh}{\sin t}}{ew}} \cdot \cos t\right) \cdot eh\right| \]
                11. lower-/.f64N/A

                  \[\leadsto \left|\sin \tan^{-1} \left(\color{blue}{\frac{\frac{eh}{\sin t}}{ew}} \cdot \cos t\right) \cdot eh\right| \]
                12. lower-/.f64N/A

                  \[\leadsto \left|\sin \tan^{-1} \left(\frac{\color{blue}{\frac{eh}{\sin t}}}{ew} \cdot \cos t\right) \cdot eh\right| \]
                13. lower-sin.f64N/A

                  \[\leadsto \left|\sin \tan^{-1} \left(\frac{\frac{eh}{\color{blue}{\sin t}}}{ew} \cdot \cos t\right) \cdot eh\right| \]
                14. lower-cos.f6477.4

                  \[\leadsto \left|\sin \tan^{-1} \left(\frac{\frac{eh}{\sin t}}{ew} \cdot \color{blue}{\cos t}\right) \cdot eh\right| \]
              5. Applied rewrites77.4%

                \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{\frac{eh}{\sin t}}{ew} \cdot \cos t\right) \cdot eh}\right| \]
              6. Taylor expanded in t around 0

                \[\leadsto \left|\sin \tan^{-1} \left(\frac{{t}^{2} \cdot \left(\frac{-1}{2} \cdot \frac{eh}{ew} - \frac{-1}{6} \cdot \frac{eh}{ew}\right) + \frac{eh}{ew}}{t}\right) \cdot eh\right| \]
              7. Step-by-step derivation
                1. Applied rewrites67.1%

                  \[\leadsto \left|\sin \tan^{-1} \left(\frac{\mathsf{fma}\left(-0.3333333333333333 \cdot \frac{eh}{ew}, t \cdot t, \frac{eh}{ew}\right)}{t}\right) \cdot eh\right| \]
                2. Taylor expanded in t around 0

                  \[\leadsto \left|\sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{t}\right) \cdot eh\right| \]
                3. Step-by-step derivation
                  1. Applied rewrites77.4%

                    \[\leadsto \left|\sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{t}\right) \cdot eh\right| \]
                4. Recombined 2 regimes into one program.
                5. Add Preprocessing

                Alternative 8: 50.4% accurate, 3.6× speedup?

                \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left|\sin \tan^{-1} \left(\frac{t \cdot eh}{ew} \cdot -0.3333333333333333\right) \cdot eh\right|\\ \mathbf{if}\;eh \leq -1.42 \cdot 10^{+116}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;eh \leq 4.8 \cdot 10^{+132}:\\ \;\;\;\;\left|\sin t \cdot ew\right|\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
                (FPCore (eh ew t)
                 :precision binary64
                 (let* ((t_1
                         (fabs (* (sin (atan (* (/ (* t eh) ew) -0.3333333333333333))) eh))))
                   (if (<= eh -1.42e+116)
                     t_1
                     (if (<= eh 4.8e+132) (fabs (* (sin t) ew)) t_1))))
                double code(double eh, double ew, double t) {
                	double t_1 = fabs((sin(atan((((t * eh) / ew) * -0.3333333333333333))) * eh));
                	double tmp;
                	if (eh <= -1.42e+116) {
                		tmp = t_1;
                	} else if (eh <= 4.8e+132) {
                		tmp = fabs((sin(t) * ew));
                	} else {
                		tmp = t_1;
                	}
                	return tmp;
                }
                
                real(8) function code(eh, ew, t)
                    real(8), intent (in) :: eh
                    real(8), intent (in) :: ew
                    real(8), intent (in) :: t
                    real(8) :: t_1
                    real(8) :: tmp
                    t_1 = abs((sin(atan((((t * eh) / ew) * (-0.3333333333333333d0)))) * eh))
                    if (eh <= (-1.42d+116)) then
                        tmp = t_1
                    else if (eh <= 4.8d+132) then
                        tmp = abs((sin(t) * ew))
                    else
                        tmp = t_1
                    end if
                    code = tmp
                end function
                
                public static double code(double eh, double ew, double t) {
                	double t_1 = Math.abs((Math.sin(Math.atan((((t * eh) / ew) * -0.3333333333333333))) * eh));
                	double tmp;
                	if (eh <= -1.42e+116) {
                		tmp = t_1;
                	} else if (eh <= 4.8e+132) {
                		tmp = Math.abs((Math.sin(t) * ew));
                	} else {
                		tmp = t_1;
                	}
                	return tmp;
                }
                
                def code(eh, ew, t):
                	t_1 = math.fabs((math.sin(math.atan((((t * eh) / ew) * -0.3333333333333333))) * eh))
                	tmp = 0
                	if eh <= -1.42e+116:
                		tmp = t_1
                	elif eh <= 4.8e+132:
                		tmp = math.fabs((math.sin(t) * ew))
                	else:
                		tmp = t_1
                	return tmp
                
                function code(eh, ew, t)
                	t_1 = abs(Float64(sin(atan(Float64(Float64(Float64(t * eh) / ew) * -0.3333333333333333))) * eh))
                	tmp = 0.0
                	if (eh <= -1.42e+116)
                		tmp = t_1;
                	elseif (eh <= 4.8e+132)
                		tmp = abs(Float64(sin(t) * ew));
                	else
                		tmp = t_1;
                	end
                	return tmp
                end
                
                function tmp_2 = code(eh, ew, t)
                	t_1 = abs((sin(atan((((t * eh) / ew) * -0.3333333333333333))) * eh));
                	tmp = 0.0;
                	if (eh <= -1.42e+116)
                		tmp = t_1;
                	elseif (eh <= 4.8e+132)
                		tmp = abs((sin(t) * ew));
                	else
                		tmp = t_1;
                	end
                	tmp_2 = tmp;
                end
                
                code[eh_, ew_, t_] := Block[{t$95$1 = N[Abs[N[(N[Sin[N[ArcTan[N[(N[(N[(t * eh), $MachinePrecision] / ew), $MachinePrecision] * -0.3333333333333333), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] * eh), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[eh, -1.42e+116], t$95$1, If[LessEqual[eh, 4.8e+132], N[Abs[N[(N[Sin[t], $MachinePrecision] * ew), $MachinePrecision]], $MachinePrecision], t$95$1]]]
                
                \begin{array}{l}
                
                \\
                \begin{array}{l}
                t_1 := \left|\sin \tan^{-1} \left(\frac{t \cdot eh}{ew} \cdot -0.3333333333333333\right) \cdot eh\right|\\
                \mathbf{if}\;eh \leq -1.42 \cdot 10^{+116}:\\
                \;\;\;\;t\_1\\
                
                \mathbf{elif}\;eh \leq 4.8 \cdot 10^{+132}:\\
                \;\;\;\;\left|\sin t \cdot ew\right|\\
                
                \mathbf{else}:\\
                \;\;\;\;t\_1\\
                
                
                \end{array}
                \end{array}
                
                Derivation
                1. Split input into 2 regimes
                2. if eh < -1.4199999999999999e116 or 4.8000000000000002e132 < eh

                  1. Initial program 99.9%

                    \[\left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                  2. Add Preprocessing
                  3. Taylor expanded in t around 0

                    \[\leadsto \left|\color{blue}{eh \cdot \sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right)}\right| \]
                  4. Step-by-step derivation
                    1. *-commutativeN/A

                      \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right) \cdot eh}\right| \]
                    2. lower-*.f64N/A

                      \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right) \cdot eh}\right| \]
                    3. lower-sin.f64N/A

                      \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right)} \cdot eh\right| \]
                    4. lower-atan.f64N/A

                      \[\leadsto \left|\sin \color{blue}{\tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right)} \cdot eh\right| \]
                    5. *-commutativeN/A

                      \[\leadsto \left|\sin \tan^{-1} \left(\frac{\color{blue}{\cos t \cdot eh}}{ew \cdot \sin t}\right) \cdot eh\right| \]
                    6. associate-/l*N/A

                      \[\leadsto \left|\sin \tan^{-1} \color{blue}{\left(\cos t \cdot \frac{eh}{ew \cdot \sin t}\right)} \cdot eh\right| \]
                    7. *-commutativeN/A

                      \[\leadsto \left|\sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \sin t} \cdot \cos t\right)} \cdot eh\right| \]
                    8. lower-*.f64N/A

                      \[\leadsto \left|\sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \sin t} \cdot \cos t\right)} \cdot eh\right| \]
                    9. *-commutativeN/A

                      \[\leadsto \left|\sin \tan^{-1} \left(\frac{eh}{\color{blue}{\sin t \cdot ew}} \cdot \cos t\right) \cdot eh\right| \]
                    10. associate-/r*N/A

                      \[\leadsto \left|\sin \tan^{-1} \left(\color{blue}{\frac{\frac{eh}{\sin t}}{ew}} \cdot \cos t\right) \cdot eh\right| \]
                    11. lower-/.f64N/A

                      \[\leadsto \left|\sin \tan^{-1} \left(\color{blue}{\frac{\frac{eh}{\sin t}}{ew}} \cdot \cos t\right) \cdot eh\right| \]
                    12. lower-/.f64N/A

                      \[\leadsto \left|\sin \tan^{-1} \left(\frac{\color{blue}{\frac{eh}{\sin t}}}{ew} \cdot \cos t\right) \cdot eh\right| \]
                    13. lower-sin.f64N/A

                      \[\leadsto \left|\sin \tan^{-1} \left(\frac{\frac{eh}{\color{blue}{\sin t}}}{ew} \cdot \cos t\right) \cdot eh\right| \]
                    14. lower-cos.f6459.3

                      \[\leadsto \left|\sin \tan^{-1} \left(\frac{\frac{eh}{\sin t}}{ew} \cdot \color{blue}{\cos t}\right) \cdot eh\right| \]
                  5. Applied rewrites59.3%

                    \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{\frac{eh}{\sin t}}{ew} \cdot \cos t\right) \cdot eh}\right| \]
                  6. Taylor expanded in t around 0

                    \[\leadsto \left|\sin \tan^{-1} \left(\frac{{t}^{2} \cdot \left(\frac{-1}{2} \cdot \frac{eh}{ew} - \frac{-1}{6} \cdot \frac{eh}{ew}\right) + \frac{eh}{ew}}{t}\right) \cdot eh\right| \]
                  7. Step-by-step derivation
                    1. Applied rewrites40.6%

                      \[\leadsto \left|\sin \tan^{-1} \left(\frac{\mathsf{fma}\left(-0.3333333333333333 \cdot \frac{eh}{ew}, t \cdot t, \frac{eh}{ew}\right)}{t}\right) \cdot eh\right| \]
                    2. Taylor expanded in t around inf

                      \[\leadsto \left|\sin \tan^{-1} \left(\frac{-1}{3} \cdot \frac{eh \cdot t}{ew}\right) \cdot eh\right| \]
                    3. Step-by-step derivation
                      1. Applied rewrites40.6%

                        \[\leadsto \left|\sin \tan^{-1} \left(\left(-0.3333333333333333 \cdot \frac{eh}{ew}\right) \cdot t\right) \cdot eh\right| \]
                      2. Taylor expanded in eh around 0

                        \[\leadsto \left|\sin \tan^{-1} \left(\frac{-1}{3} \cdot \frac{eh \cdot t}{ew}\right) \cdot eh\right| \]
                      3. Step-by-step derivation
                        1. Applied rewrites40.6%

                          \[\leadsto \left|\sin \tan^{-1} \left(\frac{t \cdot eh}{ew} \cdot -0.3333333333333333\right) \cdot eh\right| \]

                        if -1.4199999999999999e116 < eh < 4.8000000000000002e132

                        1. Initial program 99.8%

                          \[\left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                        2. Add Preprocessing
                        3. Step-by-step derivation
                          1. lift-+.f64N/A

                            \[\leadsto \left|\color{blue}{\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)}\right| \]
                          2. lift-*.f64N/A

                            \[\leadsto \left|\color{blue}{\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                          3. *-commutativeN/A

                            \[\leadsto \left|\color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \left(ew \cdot \sin t\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                          4. lift-*.f64N/A

                            \[\leadsto \left|\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \color{blue}{\left(ew \cdot \sin t\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                          5. associate-*r*N/A

                            \[\leadsto \left|\color{blue}{\left(\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot ew\right) \cdot \sin t} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                          6. lower-fma.f64N/A

                            \[\leadsto \left|\color{blue}{\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot ew, \sin t, \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right)}\right| \]
                        4. Applied rewrites99.8%

                          \[\leadsto \left|\color{blue}{\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot \left(\cos t \cdot eh\right)\right)}\right| \]
                        5. Step-by-step derivation
                          1. lift-/.f64N/A

                            \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{\frac{eh}{\tan t}}{ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          2. lift-/.f64N/A

                            \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{\color{blue}{\frac{eh}{\tan t}}}{ew}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          3. associate-/r*N/A

                            \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{\tan t \cdot ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          4. lower-/.f64N/A

                            \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{\tan t \cdot ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          5. *-commutativeN/A

                            \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          6. lower-*.f6499.8

                            \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                        6. Applied rewrites99.8%

                          \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \tan t}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                        7. Step-by-step derivation
                          1. lift-*.f64N/A

                            \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          2. *-commutativeN/A

                            \[\leadsto \left|\mathsf{fma}\left(\color{blue}{ew \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          3. lift-cos.f64N/A

                            \[\leadsto \left|\mathsf{fma}\left(ew \cdot \color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          4. lift-atan.f64N/A

                            \[\leadsto \left|\mathsf{fma}\left(ew \cdot \cos \color{blue}{\tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          5. cos-atanN/A

                            \[\leadsto \left|\mathsf{fma}\left(ew \cdot \color{blue}{\frac{1}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          6. un-div-invN/A

                            \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          7. lower-/.f64N/A

                            \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          8. lift-/.f64N/A

                            \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{\frac{eh}{\tan t}}{ew}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          9. lift-/.f64N/A

                            \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{\color{blue}{\frac{eh}{\tan t}}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          10. associate-/l/N/A

                            \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{eh}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          11. lift-*.f64N/A

                            \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{\color{blue}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          12. lift-/.f64N/A

                            \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{eh}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          13. lift-/.f64N/A

                            \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          14. lift-/.f64N/A

                            \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \frac{\color{blue}{\frac{eh}{\tan t}}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          15. associate-/l/N/A

                            \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{eh}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          16. lift-*.f64N/A

                            \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \frac{eh}{\color{blue}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          17. lift-/.f64N/A

                            \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{eh}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                        8. Applied rewrites99.8%

                          \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{{\left(\frac{\frac{eh}{\tan t}}{ew}\right)}^{2} + 1}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                        9. Taylor expanded in eh around 0

                          \[\leadsto \left|\color{blue}{ew \cdot \sin t}\right| \]
                        10. Step-by-step derivation
                          1. *-commutativeN/A

                            \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]
                          2. lower-*.f64N/A

                            \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]
                          3. lower-sin.f6455.5

                            \[\leadsto \left|\color{blue}{\sin t} \cdot ew\right| \]
                        11. Applied rewrites55.5%

                          \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]
                      4. Recombined 2 regimes into one program.
                      5. Add Preprocessing

                      Alternative 9: 41.9% accurate, 4.8× speedup?

                      \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(-0.3333333333333333 \cdot \frac{eh}{ew}\right) \cdot t\\ \mathbf{if}\;eh \leq -2.3 \cdot 10^{+187}:\\ \;\;\;\;\left|\frac{t\_1}{\sqrt{{t\_1}^{2} + 1}} \cdot eh\right|\\ \mathbf{else}:\\ \;\;\;\;\left|\sin t \cdot ew\right|\\ \end{array} \end{array} \]
                      (FPCore (eh ew t)
                       :precision binary64
                       (let* ((t_1 (* (* -0.3333333333333333 (/ eh ew)) t)))
                         (if (<= eh -2.3e+187)
                           (fabs (* (/ t_1 (sqrt (+ (pow t_1 2.0) 1.0))) eh))
                           (fabs (* (sin t) ew)))))
                      double code(double eh, double ew, double t) {
                      	double t_1 = (-0.3333333333333333 * (eh / ew)) * t;
                      	double tmp;
                      	if (eh <= -2.3e+187) {
                      		tmp = fabs(((t_1 / sqrt((pow(t_1, 2.0) + 1.0))) * eh));
                      	} else {
                      		tmp = fabs((sin(t) * ew));
                      	}
                      	return tmp;
                      }
                      
                      real(8) function code(eh, ew, t)
                          real(8), intent (in) :: eh
                          real(8), intent (in) :: ew
                          real(8), intent (in) :: t
                          real(8) :: t_1
                          real(8) :: tmp
                          t_1 = ((-0.3333333333333333d0) * (eh / ew)) * t
                          if (eh <= (-2.3d+187)) then
                              tmp = abs(((t_1 / sqrt(((t_1 ** 2.0d0) + 1.0d0))) * eh))
                          else
                              tmp = abs((sin(t) * ew))
                          end if
                          code = tmp
                      end function
                      
                      public static double code(double eh, double ew, double t) {
                      	double t_1 = (-0.3333333333333333 * (eh / ew)) * t;
                      	double tmp;
                      	if (eh <= -2.3e+187) {
                      		tmp = Math.abs(((t_1 / Math.sqrt((Math.pow(t_1, 2.0) + 1.0))) * eh));
                      	} else {
                      		tmp = Math.abs((Math.sin(t) * ew));
                      	}
                      	return tmp;
                      }
                      
                      def code(eh, ew, t):
                      	t_1 = (-0.3333333333333333 * (eh / ew)) * t
                      	tmp = 0
                      	if eh <= -2.3e+187:
                      		tmp = math.fabs(((t_1 / math.sqrt((math.pow(t_1, 2.0) + 1.0))) * eh))
                      	else:
                      		tmp = math.fabs((math.sin(t) * ew))
                      	return tmp
                      
                      function code(eh, ew, t)
                      	t_1 = Float64(Float64(-0.3333333333333333 * Float64(eh / ew)) * t)
                      	tmp = 0.0
                      	if (eh <= -2.3e+187)
                      		tmp = abs(Float64(Float64(t_1 / sqrt(Float64((t_1 ^ 2.0) + 1.0))) * eh));
                      	else
                      		tmp = abs(Float64(sin(t) * ew));
                      	end
                      	return tmp
                      end
                      
                      function tmp_2 = code(eh, ew, t)
                      	t_1 = (-0.3333333333333333 * (eh / ew)) * t;
                      	tmp = 0.0;
                      	if (eh <= -2.3e+187)
                      		tmp = abs(((t_1 / sqrt(((t_1 ^ 2.0) + 1.0))) * eh));
                      	else
                      		tmp = abs((sin(t) * ew));
                      	end
                      	tmp_2 = tmp;
                      end
                      
                      code[eh_, ew_, t_] := Block[{t$95$1 = N[(N[(-0.3333333333333333 * N[(eh / ew), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision]}, If[LessEqual[eh, -2.3e+187], N[Abs[N[(N[(t$95$1 / N[Sqrt[N[(N[Power[t$95$1, 2.0], $MachinePrecision] + 1.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * eh), $MachinePrecision]], $MachinePrecision], N[Abs[N[(N[Sin[t], $MachinePrecision] * ew), $MachinePrecision]], $MachinePrecision]]]
                      
                      \begin{array}{l}
                      
                      \\
                      \begin{array}{l}
                      t_1 := \left(-0.3333333333333333 \cdot \frac{eh}{ew}\right) \cdot t\\
                      \mathbf{if}\;eh \leq -2.3 \cdot 10^{+187}:\\
                      \;\;\;\;\left|\frac{t\_1}{\sqrt{{t\_1}^{2} + 1}} \cdot eh\right|\\
                      
                      \mathbf{else}:\\
                      \;\;\;\;\left|\sin t \cdot ew\right|\\
                      
                      
                      \end{array}
                      \end{array}
                      
                      Derivation
                      1. Split input into 2 regimes
                      2. if eh < -2.30000000000000004e187

                        1. Initial program 99.9%

                          \[\left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                        2. Add Preprocessing
                        3. Taylor expanded in t around 0

                          \[\leadsto \left|\color{blue}{eh \cdot \sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right)}\right| \]
                        4. Step-by-step derivation
                          1. *-commutativeN/A

                            \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right) \cdot eh}\right| \]
                          2. lower-*.f64N/A

                            \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right) \cdot eh}\right| \]
                          3. lower-sin.f64N/A

                            \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right)} \cdot eh\right| \]
                          4. lower-atan.f64N/A

                            \[\leadsto \left|\sin \color{blue}{\tan^{-1} \left(\frac{eh \cdot \cos t}{ew \cdot \sin t}\right)} \cdot eh\right| \]
                          5. *-commutativeN/A

                            \[\leadsto \left|\sin \tan^{-1} \left(\frac{\color{blue}{\cos t \cdot eh}}{ew \cdot \sin t}\right) \cdot eh\right| \]
                          6. associate-/l*N/A

                            \[\leadsto \left|\sin \tan^{-1} \color{blue}{\left(\cos t \cdot \frac{eh}{ew \cdot \sin t}\right)} \cdot eh\right| \]
                          7. *-commutativeN/A

                            \[\leadsto \left|\sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \sin t} \cdot \cos t\right)} \cdot eh\right| \]
                          8. lower-*.f64N/A

                            \[\leadsto \left|\sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \sin t} \cdot \cos t\right)} \cdot eh\right| \]
                          9. *-commutativeN/A

                            \[\leadsto \left|\sin \tan^{-1} \left(\frac{eh}{\color{blue}{\sin t \cdot ew}} \cdot \cos t\right) \cdot eh\right| \]
                          10. associate-/r*N/A

                            \[\leadsto \left|\sin \tan^{-1} \left(\color{blue}{\frac{\frac{eh}{\sin t}}{ew}} \cdot \cos t\right) \cdot eh\right| \]
                          11. lower-/.f64N/A

                            \[\leadsto \left|\sin \tan^{-1} \left(\color{blue}{\frac{\frac{eh}{\sin t}}{ew}} \cdot \cos t\right) \cdot eh\right| \]
                          12. lower-/.f64N/A

                            \[\leadsto \left|\sin \tan^{-1} \left(\frac{\color{blue}{\frac{eh}{\sin t}}}{ew} \cdot \cos t\right) \cdot eh\right| \]
                          13. lower-sin.f64N/A

                            \[\leadsto \left|\sin \tan^{-1} \left(\frac{\frac{eh}{\color{blue}{\sin t}}}{ew} \cdot \cos t\right) \cdot eh\right| \]
                          14. lower-cos.f6465.2

                            \[\leadsto \left|\sin \tan^{-1} \left(\frac{\frac{eh}{\sin t}}{ew} \cdot \color{blue}{\cos t}\right) \cdot eh\right| \]
                        5. Applied rewrites65.2%

                          \[\leadsto \left|\color{blue}{\sin \tan^{-1} \left(\frac{\frac{eh}{\sin t}}{ew} \cdot \cos t\right) \cdot eh}\right| \]
                        6. Taylor expanded in t around 0

                          \[\leadsto \left|\sin \tan^{-1} \left(\frac{{t}^{2} \cdot \left(\frac{-1}{2} \cdot \frac{eh}{ew} - \frac{-1}{6} \cdot \frac{eh}{ew}\right) + \frac{eh}{ew}}{t}\right) \cdot eh\right| \]
                        7. Step-by-step derivation
                          1. Applied rewrites40.0%

                            \[\leadsto \left|\sin \tan^{-1} \left(\frac{\mathsf{fma}\left(-0.3333333333333333 \cdot \frac{eh}{ew}, t \cdot t, \frac{eh}{ew}\right)}{t}\right) \cdot eh\right| \]
                          2. Taylor expanded in t around inf

                            \[\leadsto \left|\sin \tan^{-1} \left(\frac{-1}{3} \cdot \frac{eh \cdot t}{ew}\right) \cdot eh\right| \]
                          3. Step-by-step derivation
                            1. Applied rewrites54.2%

                              \[\leadsto \left|\sin \tan^{-1} \left(\left(-0.3333333333333333 \cdot \frac{eh}{ew}\right) \cdot t\right) \cdot eh\right| \]
                            2. Applied rewrites25.8%

                              \[\leadsto \left|\frac{\left(-0.3333333333333333 \cdot \frac{eh}{ew}\right) \cdot t}{\sqrt{{\left(\left(-0.3333333333333333 \cdot \frac{eh}{ew}\right) \cdot t\right)}^{2} + 1}} \cdot eh\right| \]

                            if -2.30000000000000004e187 < eh

                            1. Initial program 99.8%

                              \[\left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                            2. Add Preprocessing
                            3. Step-by-step derivation
                              1. lift-+.f64N/A

                                \[\leadsto \left|\color{blue}{\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)}\right| \]
                              2. lift-*.f64N/A

                                \[\leadsto \left|\color{blue}{\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                              3. *-commutativeN/A

                                \[\leadsto \left|\color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \left(ew \cdot \sin t\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                              4. lift-*.f64N/A

                                \[\leadsto \left|\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \color{blue}{\left(ew \cdot \sin t\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                              5. associate-*r*N/A

                                \[\leadsto \left|\color{blue}{\left(\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot ew\right) \cdot \sin t} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                              6. lower-fma.f64N/A

                                \[\leadsto \left|\color{blue}{\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot ew, \sin t, \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right)}\right| \]
                            4. Applied rewrites99.8%

                              \[\leadsto \left|\color{blue}{\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot \left(\cos t \cdot eh\right)\right)}\right| \]
                            5. Step-by-step derivation
                              1. lift-/.f64N/A

                                \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{\frac{eh}{\tan t}}{ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              2. lift-/.f64N/A

                                \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{\color{blue}{\frac{eh}{\tan t}}}{ew}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              3. associate-/r*N/A

                                \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{\tan t \cdot ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              4. lower-/.f64N/A

                                \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{\tan t \cdot ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              5. *-commutativeN/A

                                \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              6. lower-*.f6499.8

                                \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            6. Applied rewrites99.8%

                              \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \tan t}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            7. Step-by-step derivation
                              1. lift-*.f64N/A

                                \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              2. *-commutativeN/A

                                \[\leadsto \left|\mathsf{fma}\left(\color{blue}{ew \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              3. lift-cos.f64N/A

                                \[\leadsto \left|\mathsf{fma}\left(ew \cdot \color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              4. lift-atan.f64N/A

                                \[\leadsto \left|\mathsf{fma}\left(ew \cdot \cos \color{blue}{\tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              5. cos-atanN/A

                                \[\leadsto \left|\mathsf{fma}\left(ew \cdot \color{blue}{\frac{1}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              6. un-div-invN/A

                                \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              7. lower-/.f64N/A

                                \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              8. lift-/.f64N/A

                                \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{\frac{eh}{\tan t}}{ew}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              9. lift-/.f64N/A

                                \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{\color{blue}{\frac{eh}{\tan t}}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              10. associate-/l/N/A

                                \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{eh}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              11. lift-*.f64N/A

                                \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{\color{blue}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              12. lift-/.f64N/A

                                \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{eh}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              13. lift-/.f64N/A

                                \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              14. lift-/.f64N/A

                                \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \frac{\color{blue}{\frac{eh}{\tan t}}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              15. associate-/l/N/A

                                \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{eh}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              16. lift-*.f64N/A

                                \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \frac{eh}{\color{blue}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                              17. lift-/.f64N/A

                                \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{eh}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            8. Applied rewrites99.8%

                              \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{{\left(\frac{\frac{eh}{\tan t}}{ew}\right)}^{2} + 1}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            9. Taylor expanded in eh around 0

                              \[\leadsto \left|\color{blue}{ew \cdot \sin t}\right| \]
                            10. Step-by-step derivation
                              1. *-commutativeN/A

                                \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]
                              2. lower-*.f64N/A

                                \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]
                              3. lower-sin.f6443.9

                                \[\leadsto \left|\color{blue}{\sin t} \cdot ew\right| \]
                            11. Applied rewrites43.9%

                              \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]
                          4. Recombined 2 regimes into one program.
                          5. Add Preprocessing

                          Alternative 10: 41.7% accurate, 8.1× speedup?

                          \[\begin{array}{l} \\ \left|\sin t \cdot ew\right| \end{array} \]
                          (FPCore (eh ew t) :precision binary64 (fabs (* (sin t) ew)))
                          double code(double eh, double ew, double t) {
                          	return fabs((sin(t) * ew));
                          }
                          
                          real(8) function code(eh, ew, t)
                              real(8), intent (in) :: eh
                              real(8), intent (in) :: ew
                              real(8), intent (in) :: t
                              code = abs((sin(t) * ew))
                          end function
                          
                          public static double code(double eh, double ew, double t) {
                          	return Math.abs((Math.sin(t) * ew));
                          }
                          
                          def code(eh, ew, t):
                          	return math.fabs((math.sin(t) * ew))
                          
                          function code(eh, ew, t)
                          	return abs(Float64(sin(t) * ew))
                          end
                          
                          function tmp = code(eh, ew, t)
                          	tmp = abs((sin(t) * ew));
                          end
                          
                          code[eh_, ew_, t_] := N[Abs[N[(N[Sin[t], $MachinePrecision] * ew), $MachinePrecision]], $MachinePrecision]
                          
                          \begin{array}{l}
                          
                          \\
                          \left|\sin t \cdot ew\right|
                          \end{array}
                          
                          Derivation
                          1. Initial program 99.8%

                            \[\left|\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                          2. Add Preprocessing
                          3. Step-by-step derivation
                            1. lift-+.f64N/A

                              \[\leadsto \left|\color{blue}{\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)}\right| \]
                            2. lift-*.f64N/A

                              \[\leadsto \left|\color{blue}{\left(ew \cdot \sin t\right) \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                            3. *-commutativeN/A

                              \[\leadsto \left|\color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \left(ew \cdot \sin t\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                            4. lift-*.f64N/A

                              \[\leadsto \left|\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot \color{blue}{\left(ew \cdot \sin t\right)} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                            5. associate-*r*N/A

                              \[\leadsto \left|\color{blue}{\left(\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot ew\right) \cdot \sin t} + \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right| \]
                            6. lower-fma.f64N/A

                              \[\leadsto \left|\color{blue}{\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right) \cdot ew, \sin t, \left(eh \cdot \cos t\right) \cdot \sin \tan^{-1} \left(\frac{\frac{eh}{ew}}{\tan t}\right)\right)}\right| \]
                          4. Applied rewrites99.8%

                            \[\leadsto \left|\color{blue}{\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot \left(\cos t \cdot eh\right)\right)}\right| \]
                          5. Step-by-step derivation
                            1. lift-/.f64N/A

                              \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{\frac{eh}{\tan t}}{ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            2. lift-/.f64N/A

                              \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{\color{blue}{\frac{eh}{\tan t}}}{ew}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            3. associate-/r*N/A

                              \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{\tan t \cdot ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            4. lower-/.f64N/A

                              \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{\tan t \cdot ew}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            5. *-commutativeN/A

                              \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            6. lower-*.f6499.8

                              \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \left(\frac{eh}{\color{blue}{ew \cdot \tan t}}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          6. Applied rewrites99.8%

                            \[\leadsto \left|\mathsf{fma}\left(\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew, \sin t, \sin \tan^{-1} \color{blue}{\left(\frac{eh}{ew \cdot \tan t}\right)} \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          7. Step-by-step derivation
                            1. lift-*.f64N/A

                              \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right) \cdot ew}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            2. *-commutativeN/A

                              \[\leadsto \left|\mathsf{fma}\left(\color{blue}{ew \cdot \cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            3. lift-cos.f64N/A

                              \[\leadsto \left|\mathsf{fma}\left(ew \cdot \color{blue}{\cos \tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            4. lift-atan.f64N/A

                              \[\leadsto \left|\mathsf{fma}\left(ew \cdot \cos \color{blue}{\tan^{-1} \left(\frac{\frac{eh}{\tan t}}{ew}\right)}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            5. cos-atanN/A

                              \[\leadsto \left|\mathsf{fma}\left(ew \cdot \color{blue}{\frac{1}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            6. un-div-invN/A

                              \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            7. lower-/.f64N/A

                              \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{1 + \frac{\frac{eh}{\tan t}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            8. lift-/.f64N/A

                              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{\frac{eh}{\tan t}}{ew}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            9. lift-/.f64N/A

                              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{\color{blue}{\frac{eh}{\tan t}}}{ew} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            10. associate-/l/N/A

                              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{eh}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            11. lift-*.f64N/A

                              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{\color{blue}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            12. lift-/.f64N/A

                              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \color{blue}{\frac{eh}{ew \cdot \tan t}} \cdot \frac{\frac{eh}{\tan t}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            13. lift-/.f64N/A

                              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{\frac{eh}{\tan t}}{ew}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            14. lift-/.f64N/A

                              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \frac{\color{blue}{\frac{eh}{\tan t}}}{ew}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            15. associate-/l/N/A

                              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{eh}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            16. lift-*.f64N/A

                              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \frac{eh}{\color{blue}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                            17. lift-/.f64N/A

                              \[\leadsto \left|\mathsf{fma}\left(\frac{ew}{\sqrt{1 + \frac{eh}{ew \cdot \tan t} \cdot \color{blue}{\frac{eh}{ew \cdot \tan t}}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          8. Applied rewrites99.8%

                            \[\leadsto \left|\mathsf{fma}\left(\color{blue}{\frac{ew}{\sqrt{{\left(\frac{\frac{eh}{\tan t}}{ew}\right)}^{2} + 1}}}, \sin t, \sin \tan^{-1} \left(\frac{eh}{ew \cdot \tan t}\right) \cdot \left(\cos t \cdot eh\right)\right)\right| \]
                          9. Taylor expanded in eh around 0

                            \[\leadsto \left|\color{blue}{ew \cdot \sin t}\right| \]
                          10. Step-by-step derivation
                            1. *-commutativeN/A

                              \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]
                            2. lower-*.f64N/A

                              \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]
                            3. lower-sin.f6439.8

                              \[\leadsto \left|\color{blue}{\sin t} \cdot ew\right| \]
                          11. Applied rewrites39.8%

                            \[\leadsto \left|\color{blue}{\sin t \cdot ew}\right| \]
                          12. Add Preprocessing

                          Reproduce

                          ?
                          herbie shell --seed 2024332 
                          (FPCore (eh ew t)
                            :name "Example from Robby"
                            :precision binary64
                            (fabs (+ (* (* ew (sin t)) (cos (atan (/ (/ eh ew) (tan t))))) (* (* eh (cos t)) (sin (atan (/ (/ eh ew) (tan t))))))))