Toniolo and Linder, Equation (10+)

Percentage Accurate: 55.9% → 88.7%
Time: 18.5s
Alternatives: 21
Speedup: 1.9×

Specification

?
\[\begin{array}{l} \\ \frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \end{array} \]
(FPCore (t l k)
 :precision binary64
 (/
  2.0
  (*
   (* (* (/ (pow t 3.0) (* l l)) (sin k)) (tan k))
   (+ (+ 1.0 (pow (/ k t) 2.0)) 1.0))))
double code(double t, double l, double k) {
	return 2.0 / ((((pow(t, 3.0) / (l * l)) * sin(k)) * tan(k)) * ((1.0 + pow((k / t), 2.0)) + 1.0));
}
real(8) function code(t, l, k)
    real(8), intent (in) :: t
    real(8), intent (in) :: l
    real(8), intent (in) :: k
    code = 2.0d0 / (((((t ** 3.0d0) / (l * l)) * sin(k)) * tan(k)) * ((1.0d0 + ((k / t) ** 2.0d0)) + 1.0d0))
end function
public static double code(double t, double l, double k) {
	return 2.0 / ((((Math.pow(t, 3.0) / (l * l)) * Math.sin(k)) * Math.tan(k)) * ((1.0 + Math.pow((k / t), 2.0)) + 1.0));
}
def code(t, l, k):
	return 2.0 / ((((math.pow(t, 3.0) / (l * l)) * math.sin(k)) * math.tan(k)) * ((1.0 + math.pow((k / t), 2.0)) + 1.0))
function code(t, l, k)
	return Float64(2.0 / Float64(Float64(Float64(Float64((t ^ 3.0) / Float64(l * l)) * sin(k)) * tan(k)) * Float64(Float64(1.0 + (Float64(k / t) ^ 2.0)) + 1.0)))
end
function tmp = code(t, l, k)
	tmp = 2.0 / (((((t ^ 3.0) / (l * l)) * sin(k)) * tan(k)) * ((1.0 + ((k / t) ^ 2.0)) + 1.0));
end
code[t_, l_, k_] := N[(2.0 / N[(N[(N[(N[(N[Power[t, 3.0], $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision] * N[Sin[k], $MachinePrecision]), $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision] * N[(N[(1.0 + N[Power[N[(k / t), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)}
\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 21 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: 55.9% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \end{array} \]
(FPCore (t l k)
 :precision binary64
 (/
  2.0
  (*
   (* (* (/ (pow t 3.0) (* l l)) (sin k)) (tan k))
   (+ (+ 1.0 (pow (/ k t) 2.0)) 1.0))))
double code(double t, double l, double k) {
	return 2.0 / ((((pow(t, 3.0) / (l * l)) * sin(k)) * tan(k)) * ((1.0 + pow((k / t), 2.0)) + 1.0));
}
real(8) function code(t, l, k)
    real(8), intent (in) :: t
    real(8), intent (in) :: l
    real(8), intent (in) :: k
    code = 2.0d0 / (((((t ** 3.0d0) / (l * l)) * sin(k)) * tan(k)) * ((1.0d0 + ((k / t) ** 2.0d0)) + 1.0d0))
end function
public static double code(double t, double l, double k) {
	return 2.0 / ((((Math.pow(t, 3.0) / (l * l)) * Math.sin(k)) * Math.tan(k)) * ((1.0 + Math.pow((k / t), 2.0)) + 1.0));
}
def code(t, l, k):
	return 2.0 / ((((math.pow(t, 3.0) / (l * l)) * math.sin(k)) * math.tan(k)) * ((1.0 + math.pow((k / t), 2.0)) + 1.0))
function code(t, l, k)
	return Float64(2.0 / Float64(Float64(Float64(Float64((t ^ 3.0) / Float64(l * l)) * sin(k)) * tan(k)) * Float64(Float64(1.0 + (Float64(k / t) ^ 2.0)) + 1.0)))
end
function tmp = code(t, l, k)
	tmp = 2.0 / (((((t ^ 3.0) / (l * l)) * sin(k)) * tan(k)) * ((1.0 + ((k / t) ^ 2.0)) + 1.0));
end
code[t_, l_, k_] := N[(2.0 / N[(N[(N[(N[(N[Power[t, 3.0], $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision] * N[Sin[k], $MachinePrecision]), $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision] * N[(N[(1.0 + N[Power[N[(k / t), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)}
\end{array}

Alternative 1: 88.7% accurate, 0.5× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ \begin{array}{l} t_2 := \sqrt[3]{\frac{1}{\ell}}\\ t\_s \cdot \begin{array}{l} \mathbf{if}\;t\_m \leq 3.7 \cdot 10^{-193}:\\ \;\;\;\;\frac{2}{\frac{\left(t\_m \cdot {k}^{2}\right) \cdot {\sin k}^{2}}{{\ell}^{2} \cdot \cos k}}\\ \mathbf{elif}\;t\_m \leq 2 \cdot 10^{-71}:\\ \;\;\;\;\frac{\frac{2}{{\left(\frac{{t\_m}^{1.5} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t\_m}\right)\right)}{\ell}\right)}^{2}}}{\sin k \cdot \tan k}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{{\left(\left(t\_m \cdot \left(t\_2 \cdot t\_2\right)\right) \cdot \left(\sqrt[3]{\sin k} \cdot \sqrt[3]{\tan k \cdot \left(2 + {\left(\frac{k}{t\_m}\right)}^{2}\right)}\right)\right)}^{3}}\\ \end{array} \end{array} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (let* ((t_2 (cbrt (/ 1.0 l))))
   (*
    t_s
    (if (<= t_m 3.7e-193)
      (/
       2.0
       (/ (* (* t_m (pow k 2.0)) (pow (sin k) 2.0)) (* (pow l 2.0) (cos k))))
      (if (<= t_m 2e-71)
        (/
         (/
          2.0
          (pow (/ (* (pow t_m 1.5) (hypot 1.0 (hypot 1.0 (/ k t_m)))) l) 2.0))
         (* (sin k) (tan k)))
        (/
         2.0
         (pow
          (*
           (* t_m (* t_2 t_2))
           (* (cbrt (sin k)) (cbrt (* (tan k) (+ 2.0 (pow (/ k t_m) 2.0))))))
          3.0)))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	double t_2 = cbrt((1.0 / l));
	double tmp;
	if (t_m <= 3.7e-193) {
		tmp = 2.0 / (((t_m * pow(k, 2.0)) * pow(sin(k), 2.0)) / (pow(l, 2.0) * cos(k)));
	} else if (t_m <= 2e-71) {
		tmp = (2.0 / pow(((pow(t_m, 1.5) * hypot(1.0, hypot(1.0, (k / t_m)))) / l), 2.0)) / (sin(k) * tan(k));
	} else {
		tmp = 2.0 / pow(((t_m * (t_2 * t_2)) * (cbrt(sin(k)) * cbrt((tan(k) * (2.0 + pow((k / t_m), 2.0)))))), 3.0);
	}
	return t_s * tmp;
}
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	double t_2 = Math.cbrt((1.0 / l));
	double tmp;
	if (t_m <= 3.7e-193) {
		tmp = 2.0 / (((t_m * Math.pow(k, 2.0)) * Math.pow(Math.sin(k), 2.0)) / (Math.pow(l, 2.0) * Math.cos(k)));
	} else if (t_m <= 2e-71) {
		tmp = (2.0 / Math.pow(((Math.pow(t_m, 1.5) * Math.hypot(1.0, Math.hypot(1.0, (k / t_m)))) / l), 2.0)) / (Math.sin(k) * Math.tan(k));
	} else {
		tmp = 2.0 / Math.pow(((t_m * (t_2 * t_2)) * (Math.cbrt(Math.sin(k)) * Math.cbrt((Math.tan(k) * (2.0 + Math.pow((k / t_m), 2.0)))))), 3.0);
	}
	return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	t_2 = cbrt(Float64(1.0 / l))
	tmp = 0.0
	if (t_m <= 3.7e-193)
		tmp = Float64(2.0 / Float64(Float64(Float64(t_m * (k ^ 2.0)) * (sin(k) ^ 2.0)) / Float64((l ^ 2.0) * cos(k))));
	elseif (t_m <= 2e-71)
		tmp = Float64(Float64(2.0 / (Float64(Float64((t_m ^ 1.5) * hypot(1.0, hypot(1.0, Float64(k / t_m)))) / l) ^ 2.0)) / Float64(sin(k) * tan(k)));
	else
		tmp = Float64(2.0 / (Float64(Float64(t_m * Float64(t_2 * t_2)) * Float64(cbrt(sin(k)) * cbrt(Float64(tan(k) * Float64(2.0 + (Float64(k / t_m) ^ 2.0)))))) ^ 3.0));
	end
	return Float64(t_s * tmp)
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := Block[{t$95$2 = N[Power[N[(1.0 / l), $MachinePrecision], 1/3], $MachinePrecision]}, N[(t$95$s * If[LessEqual[t$95$m, 3.7e-193], N[(2.0 / N[(N[(N[(t$95$m * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[Power[N[Sin[k], $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] / N[(N[Power[l, 2.0], $MachinePrecision] * N[Cos[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 2e-71], N[(N[(2.0 / N[Power[N[(N[(N[Power[t$95$m, 1.5], $MachinePrecision] * N[Sqrt[1.0 ^ 2 + N[Sqrt[1.0 ^ 2 + N[(k / t$95$m), $MachinePrecision] ^ 2], $MachinePrecision] ^ 2], $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] / N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[Power[N[(N[(t$95$m * N[(t$95$2 * t$95$2), $MachinePrecision]), $MachinePrecision] * N[(N[Power[N[Sin[k], $MachinePrecision], 1/3], $MachinePrecision] * N[Power[N[(N[Tan[k], $MachinePrecision] * N[(2.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
\begin{array}{l}
t_2 := \sqrt[3]{\frac{1}{\ell}}\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 3.7 \cdot 10^{-193}:\\
\;\;\;\;\frac{2}{\frac{\left(t\_m \cdot {k}^{2}\right) \cdot {\sin k}^{2}}{{\ell}^{2} \cdot \cos k}}\\

\mathbf{elif}\;t\_m \leq 2 \cdot 10^{-71}:\\
\;\;\;\;\frac{\frac{2}{{\left(\frac{{t\_m}^{1.5} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t\_m}\right)\right)}{\ell}\right)}^{2}}}{\sin k \cdot \tan k}\\

\mathbf{else}:\\
\;\;\;\;\frac{2}{{\left(\left(t\_m \cdot \left(t\_2 \cdot t\_2\right)\right) \cdot \left(\sqrt[3]{\sin k} \cdot \sqrt[3]{\tan k \cdot \left(2 + {\left(\frac{k}{t\_m}\right)}^{2}\right)}\right)\right)}^{3}}\\


\end{array}
\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < 3.7000000000000002e-193

    1. Initial program 48.9%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified48.9%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in t around 0 67.1%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot \left(t \cdot {\sin k}^{2}\right)}{{\ell}^{2} \cdot \cos k}}} \]
    5. Step-by-step derivation
      1. associate-*r*67.1%

        \[\leadsto \frac{2}{\frac{\color{blue}{\left({k}^{2} \cdot t\right) \cdot {\sin k}^{2}}}{{\ell}^{2} \cdot \cos k}} \]
    6. Simplified67.1%

      \[\leadsto \frac{2}{\color{blue}{\frac{\left({k}^{2} \cdot t\right) \cdot {\sin k}^{2}}{{\ell}^{2} \cdot \cos k}}} \]

    if 3.7000000000000002e-193 < t < 1.9999999999999998e-71

    1. Initial program 56.3%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified56.3%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Applied egg-rr70.3%

      \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)\right)}^{2}}} \]
    5. Step-by-step derivation
      1. *-un-lft-identity70.3%

        \[\leadsto \color{blue}{1 \cdot \frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)\right)}^{2}}} \]
      2. associate-*r*70.3%

        \[\leadsto 1 \cdot \frac{2}{{\color{blue}{\left(\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)}}^{2}} \]
      3. unpow-prod-down70.4%

        \[\leadsto 1 \cdot \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2} \cdot {\left(\sqrt{\sin k \cdot \tan k}\right)}^{2}}} \]
      4. pow270.4%

        \[\leadsto 1 \cdot \frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2} \cdot \color{blue}{\left(\sqrt{\sin k \cdot \tan k} \cdot \sqrt{\sin k \cdot \tan k}\right)}} \]
      5. add-sqr-sqrt96.0%

        \[\leadsto 1 \cdot \frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2} \cdot \color{blue}{\left(\sin k \cdot \tan k\right)}} \]
    6. Applied egg-rr96.0%

      \[\leadsto \color{blue}{1 \cdot \frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2} \cdot \left(\sin k \cdot \tan k\right)}} \]
    7. Step-by-step derivation
      1. *-lft-identity96.0%

        \[\leadsto \color{blue}{\frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2} \cdot \left(\sin k \cdot \tan k\right)}} \]
      2. associate-/r*96.0%

        \[\leadsto \color{blue}{\frac{\frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2}}}{\sin k \cdot \tan k}} \]
      3. associate-*l/96.1%

        \[\leadsto \frac{\frac{2}{{\color{blue}{\left(\frac{{t}^{1.5} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)}{\ell}\right)}}^{2}}}{\sin k \cdot \tan k} \]
    8. Simplified96.1%

      \[\leadsto \color{blue}{\frac{\frac{2}{{\left(\frac{{t}^{1.5} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)}{\ell}\right)}^{2}}}{\sin k \cdot \tan k}} \]

    if 1.9999999999999998e-71 < t

    1. Initial program 70.4%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified70.4%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. associate-*l*60.6%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell \cdot \ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)}} \]
      2. associate-/r*63.4%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell}}{\ell}} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)} \]
      3. associate-+r+63.4%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \color{blue}{\left(\left(1 + 1\right) + {\left(\frac{k}{t}\right)}^{2}\right)}\right)\right)} \]
      4. metadata-eval63.4%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(\color{blue}{2} + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]
      5. associate-*l*63.4%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \color{blue}{\left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}} \]
      6. add-cube-cbrt63.3%

        \[\leadsto \frac{2}{\color{blue}{\left(\sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)} \cdot \sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}\right) \cdot \sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}}} \]
      7. pow363.3%

        \[\leadsto \frac{2}{\color{blue}{{\left(\sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}\right)}^{3}}} \]
    5. Applied egg-rr65.5%

      \[\leadsto \frac{2}{\color{blue}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}}} \]
    6. Step-by-step derivation
      1. pow1/364.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{{\left({\ell}^{-2}\right)}^{0.3333333333333333}}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      2. sqr-pow64.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\color{blue}{\left({\ell}^{\left(\frac{-2}{2}\right)} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      3. metadata-eval64.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left({\ell}^{\color{blue}{-1}} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      4. inv-pow64.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\color{blue}{\frac{1}{\ell}} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      5. metadata-eval64.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\frac{1}{\ell} \cdot {\ell}^{\color{blue}{-1}}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      6. inv-pow64.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\frac{1}{\ell} \cdot \color{blue}{\frac{1}{\ell}}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      7. unpow-prod-down32.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left({\left(\frac{1}{\ell}\right)}^{0.3333333333333333} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    7. Applied egg-rr32.9%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left({\left(\frac{1}{\ell}\right)}^{0.3333333333333333} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    8. Step-by-step derivation
      1. unpow1/333.0%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\color{blue}{\sqrt[3]{\frac{1}{\ell}}} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      2. unpow1/374.0%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \color{blue}{\sqrt[3]{\frac{1}{\ell}}}\right)\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    9. Simplified74.0%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    10. Step-by-step derivation
      1. associate-*l*74.1%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \sqrt[3]{\color{blue}{\sin k \cdot \left(\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}}\right)}^{3}} \]
      2. cbrt-prod95.0%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \color{blue}{\left(\sqrt[3]{\sin k} \cdot \sqrt[3]{\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}\right)}^{3}} \]
    11. Applied egg-rr95.0%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \color{blue}{\left(\sqrt[3]{\sin k} \cdot \sqrt[3]{\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}\right)}^{3}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification78.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq 3.7 \cdot 10^{-193}:\\ \;\;\;\;\frac{2}{\frac{\left(t \cdot {k}^{2}\right) \cdot {\sin k}^{2}}{{\ell}^{2} \cdot \cos k}}\\ \mathbf{elif}\;t \leq 2 \cdot 10^{-71}:\\ \;\;\;\;\frac{\frac{2}{{\left(\frac{{t}^{1.5} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)}{\ell}\right)}^{2}}}{\sin k \cdot \tan k}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\sqrt[3]{\sin k} \cdot \sqrt[3]{\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)\right)}^{3}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 2: 78.5% accurate, 0.7× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ \begin{array}{l} t_2 := \sqrt[3]{\frac{1}{\ell}}\\ t\_s \cdot \begin{array}{l} \mathbf{if}\;k \leq 2.1 \cdot 10^{-84}:\\ \;\;\;\;\frac{2}{{\left(\left(t\_m \cdot \left(t\_2 \cdot t\_2\right)\right) \cdot \left({\left(\sqrt[3]{k}\right)}^{2} \cdot \sqrt[3]{2}\right)\right)}^{3}}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{2}{{\left(\frac{{t\_m}^{1.5} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t\_m}\right)\right)}{\ell}\right)}^{2}}}{\sin k \cdot \tan k}\\ \end{array} \end{array} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (let* ((t_2 (cbrt (/ 1.0 l))))
   (*
    t_s
    (if (<= k 2.1e-84)
      (/
       2.0
       (pow (* (* t_m (* t_2 t_2)) (* (pow (cbrt k) 2.0) (cbrt 2.0))) 3.0))
      (/
       (/
        2.0
        (pow (/ (* (pow t_m 1.5) (hypot 1.0 (hypot 1.0 (/ k t_m)))) l) 2.0))
       (* (sin k) (tan k)))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	double t_2 = cbrt((1.0 / l));
	double tmp;
	if (k <= 2.1e-84) {
		tmp = 2.0 / pow(((t_m * (t_2 * t_2)) * (pow(cbrt(k), 2.0) * cbrt(2.0))), 3.0);
	} else {
		tmp = (2.0 / pow(((pow(t_m, 1.5) * hypot(1.0, hypot(1.0, (k / t_m)))) / l), 2.0)) / (sin(k) * tan(k));
	}
	return t_s * tmp;
}
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	double t_2 = Math.cbrt((1.0 / l));
	double tmp;
	if (k <= 2.1e-84) {
		tmp = 2.0 / Math.pow(((t_m * (t_2 * t_2)) * (Math.pow(Math.cbrt(k), 2.0) * Math.cbrt(2.0))), 3.0);
	} else {
		tmp = (2.0 / Math.pow(((Math.pow(t_m, 1.5) * Math.hypot(1.0, Math.hypot(1.0, (k / t_m)))) / l), 2.0)) / (Math.sin(k) * Math.tan(k));
	}
	return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	t_2 = cbrt(Float64(1.0 / l))
	tmp = 0.0
	if (k <= 2.1e-84)
		tmp = Float64(2.0 / (Float64(Float64(t_m * Float64(t_2 * t_2)) * Float64((cbrt(k) ^ 2.0) * cbrt(2.0))) ^ 3.0));
	else
		tmp = Float64(Float64(2.0 / (Float64(Float64((t_m ^ 1.5) * hypot(1.0, hypot(1.0, Float64(k / t_m)))) / l) ^ 2.0)) / Float64(sin(k) * tan(k)));
	end
	return Float64(t_s * tmp)
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := Block[{t$95$2 = N[Power[N[(1.0 / l), $MachinePrecision], 1/3], $MachinePrecision]}, N[(t$95$s * If[LessEqual[k, 2.1e-84], N[(2.0 / N[Power[N[(N[(t$95$m * N[(t$95$2 * t$95$2), $MachinePrecision]), $MachinePrecision] * N[(N[Power[N[Power[k, 1/3], $MachinePrecision], 2.0], $MachinePrecision] * N[Power[2.0, 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision], N[(N[(2.0 / N[Power[N[(N[(N[Power[t$95$m, 1.5], $MachinePrecision] * N[Sqrt[1.0 ^ 2 + N[Sqrt[1.0 ^ 2 + N[(k / t$95$m), $MachinePrecision] ^ 2], $MachinePrecision] ^ 2], $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] / N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
\begin{array}{l}
t_2 := \sqrt[3]{\frac{1}{\ell}}\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 2.1 \cdot 10^{-84}:\\
\;\;\;\;\frac{2}{{\left(\left(t\_m \cdot \left(t\_2 \cdot t\_2\right)\right) \cdot \left({\left(\sqrt[3]{k}\right)}^{2} \cdot \sqrt[3]{2}\right)\right)}^{3}}\\

\mathbf{else}:\\
\;\;\;\;\frac{\frac{2}{{\left(\frac{{t\_m}^{1.5} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t\_m}\right)\right)}{\ell}\right)}^{2}}}{\sin k \cdot \tan k}\\


\end{array}
\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if k < 2.09999999999999998e-84

    1. Initial program 56.1%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified56.1%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. associate-*l*50.8%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell \cdot \ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)}} \]
      2. associate-/r*55.4%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell}}{\ell}} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)} \]
      3. associate-+r+55.4%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \color{blue}{\left(\left(1 + 1\right) + {\left(\frac{k}{t}\right)}^{2}\right)}\right)\right)} \]
      4. metadata-eval55.4%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(\color{blue}{2} + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]
      5. associate-*l*55.4%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \color{blue}{\left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}} \]
      6. add-cube-cbrt55.4%

        \[\leadsto \frac{2}{\color{blue}{\left(\sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)} \cdot \sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}\right) \cdot \sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}}} \]
      7. pow355.4%

        \[\leadsto \frac{2}{\color{blue}{{\left(\sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}\right)}^{3}}} \]
    5. Applied egg-rr62.4%

      \[\leadsto \frac{2}{\color{blue}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}}} \]
    6. Step-by-step derivation
      1. pow1/361.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{{\left({\ell}^{-2}\right)}^{0.3333333333333333}}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      2. sqr-pow61.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\color{blue}{\left({\ell}^{\left(\frac{-2}{2}\right)} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      3. metadata-eval61.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left({\ell}^{\color{blue}{-1}} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      4. inv-pow61.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\color{blue}{\frac{1}{\ell}} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      5. metadata-eval61.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\frac{1}{\ell} \cdot {\ell}^{\color{blue}{-1}}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      6. inv-pow61.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\frac{1}{\ell} \cdot \color{blue}{\frac{1}{\ell}}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      7. unpow-prod-down36.8%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left({\left(\frac{1}{\ell}\right)}^{0.3333333333333333} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    7. Applied egg-rr36.8%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left({\left(\frac{1}{\ell}\right)}^{0.3333333333333333} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    8. Step-by-step derivation
      1. unpow1/336.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\color{blue}{\sqrt[3]{\frac{1}{\ell}}} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      2. unpow1/372.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \color{blue}{\sqrt[3]{\frac{1}{\ell}}}\right)\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    9. Simplified72.2%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    10. Taylor expanded in k around 0 67.0%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \color{blue}{\left(\sqrt[3]{{k}^{2}} \cdot \sqrt[3]{2}\right)}\right)}^{3}} \]
    11. Step-by-step derivation
      1. *-un-lft-identity67.0%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\color{blue}{\left(1 \cdot \sqrt[3]{{k}^{2}}\right)} \cdot \sqrt[3]{2}\right)\right)}^{3}} \]
      2. unpow267.0%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\left(1 \cdot \sqrt[3]{\color{blue}{k \cdot k}}\right) \cdot \sqrt[3]{2}\right)\right)}^{3}} \]
      3. cbrt-prod79.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\left(1 \cdot \color{blue}{\left(\sqrt[3]{k} \cdot \sqrt[3]{k}\right)}\right) \cdot \sqrt[3]{2}\right)\right)}^{3}} \]
      4. pow279.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\left(1 \cdot \color{blue}{{\left(\sqrt[3]{k}\right)}^{2}}\right) \cdot \sqrt[3]{2}\right)\right)}^{3}} \]
    12. Applied egg-rr79.9%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\color{blue}{\left(1 \cdot {\left(\sqrt[3]{k}\right)}^{2}\right)} \cdot \sqrt[3]{2}\right)\right)}^{3}} \]
    13. Step-by-step derivation
      1. *-lft-identity79.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\color{blue}{{\left(\sqrt[3]{k}\right)}^{2}} \cdot \sqrt[3]{2}\right)\right)}^{3}} \]
    14. Simplified79.9%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\color{blue}{{\left(\sqrt[3]{k}\right)}^{2}} \cdot \sqrt[3]{2}\right)\right)}^{3}} \]

    if 2.09999999999999998e-84 < k

    1. Initial program 54.9%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified54.9%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Applied egg-rr31.6%

      \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)\right)}^{2}}} \]
    5. Step-by-step derivation
      1. *-un-lft-identity31.6%

        \[\leadsto \color{blue}{1 \cdot \frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)\right)}^{2}}} \]
      2. associate-*r*31.5%

        \[\leadsto 1 \cdot \frac{2}{{\color{blue}{\left(\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)}}^{2}} \]
      3. unpow-prod-down31.5%

        \[\leadsto 1 \cdot \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2} \cdot {\left(\sqrt{\sin k \cdot \tan k}\right)}^{2}}} \]
      4. pow231.5%

        \[\leadsto 1 \cdot \frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2} \cdot \color{blue}{\left(\sqrt{\sin k \cdot \tan k} \cdot \sqrt{\sin k \cdot \tan k}\right)}} \]
      5. add-sqr-sqrt43.6%

        \[\leadsto 1 \cdot \frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2} \cdot \color{blue}{\left(\sin k \cdot \tan k\right)}} \]
    6. Applied egg-rr43.6%

      \[\leadsto \color{blue}{1 \cdot \frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2} \cdot \left(\sin k \cdot \tan k\right)}} \]
    7. Step-by-step derivation
      1. *-lft-identity43.6%

        \[\leadsto \color{blue}{\frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2} \cdot \left(\sin k \cdot \tan k\right)}} \]
      2. associate-/r*43.6%

        \[\leadsto \color{blue}{\frac{\frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2}}}{\sin k \cdot \tan k}} \]
      3. associate-*l/43.7%

        \[\leadsto \frac{\frac{2}{{\color{blue}{\left(\frac{{t}^{1.5} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)}{\ell}\right)}}^{2}}}{\sin k \cdot \tan k} \]
    8. Simplified43.7%

      \[\leadsto \color{blue}{\frac{\frac{2}{{\left(\frac{{t}^{1.5} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)}{\ell}\right)}^{2}}}{\sin k \cdot \tan k}} \]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 3: 78.4% accurate, 0.7× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ \begin{array}{l} t_2 := \sqrt[3]{\frac{1}{\ell}}\\ t\_s \cdot \begin{array}{l} \mathbf{if}\;k \leq 10^{-84}:\\ \;\;\;\;\frac{2}{{\left(\left(t\_m \cdot \left(t\_2 \cdot t\_2\right)\right) \cdot \left({\left(\sqrt[3]{k}\right)}^{2} \cdot \sqrt[3]{2}\right)\right)}^{3}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{\left(\sin k \cdot \tan k\right) \cdot {\left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t\_m}\right)\right) \cdot \frac{{t\_m}^{1.5}}{\ell}\right)}^{2}}\\ \end{array} \end{array} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (let* ((t_2 (cbrt (/ 1.0 l))))
   (*
    t_s
    (if (<= k 1e-84)
      (/
       2.0
       (pow (* (* t_m (* t_2 t_2)) (* (pow (cbrt k) 2.0) (cbrt 2.0))) 3.0))
      (/
       2.0
       (*
        (* (sin k) (tan k))
        (pow
         (* (hypot 1.0 (hypot 1.0 (/ k t_m))) (/ (pow t_m 1.5) l))
         2.0)))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	double t_2 = cbrt((1.0 / l));
	double tmp;
	if (k <= 1e-84) {
		tmp = 2.0 / pow(((t_m * (t_2 * t_2)) * (pow(cbrt(k), 2.0) * cbrt(2.0))), 3.0);
	} else {
		tmp = 2.0 / ((sin(k) * tan(k)) * pow((hypot(1.0, hypot(1.0, (k / t_m))) * (pow(t_m, 1.5) / l)), 2.0));
	}
	return t_s * tmp;
}
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	double t_2 = Math.cbrt((1.0 / l));
	double tmp;
	if (k <= 1e-84) {
		tmp = 2.0 / Math.pow(((t_m * (t_2 * t_2)) * (Math.pow(Math.cbrt(k), 2.0) * Math.cbrt(2.0))), 3.0);
	} else {
		tmp = 2.0 / ((Math.sin(k) * Math.tan(k)) * Math.pow((Math.hypot(1.0, Math.hypot(1.0, (k / t_m))) * (Math.pow(t_m, 1.5) / l)), 2.0));
	}
	return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	t_2 = cbrt(Float64(1.0 / l))
	tmp = 0.0
	if (k <= 1e-84)
		tmp = Float64(2.0 / (Float64(Float64(t_m * Float64(t_2 * t_2)) * Float64((cbrt(k) ^ 2.0) * cbrt(2.0))) ^ 3.0));
	else
		tmp = Float64(2.0 / Float64(Float64(sin(k) * tan(k)) * (Float64(hypot(1.0, hypot(1.0, Float64(k / t_m))) * Float64((t_m ^ 1.5) / l)) ^ 2.0)));
	end
	return Float64(t_s * tmp)
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := Block[{t$95$2 = N[Power[N[(1.0 / l), $MachinePrecision], 1/3], $MachinePrecision]}, N[(t$95$s * If[LessEqual[k, 1e-84], N[(2.0 / N[Power[N[(N[(t$95$m * N[(t$95$2 * t$95$2), $MachinePrecision]), $MachinePrecision] * N[(N[Power[N[Power[k, 1/3], $MachinePrecision], 2.0], $MachinePrecision] * N[Power[2.0, 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision] * N[Power[N[(N[Sqrt[1.0 ^ 2 + N[Sqrt[1.0 ^ 2 + N[(k / t$95$m), $MachinePrecision] ^ 2], $MachinePrecision] ^ 2], $MachinePrecision] * N[(N[Power[t$95$m, 1.5], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
\begin{array}{l}
t_2 := \sqrt[3]{\frac{1}{\ell}}\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 10^{-84}:\\
\;\;\;\;\frac{2}{{\left(\left(t\_m \cdot \left(t\_2 \cdot t\_2\right)\right) \cdot \left({\left(\sqrt[3]{k}\right)}^{2} \cdot \sqrt[3]{2}\right)\right)}^{3}}\\

\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(\sin k \cdot \tan k\right) \cdot {\left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t\_m}\right)\right) \cdot \frac{{t\_m}^{1.5}}{\ell}\right)}^{2}}\\


\end{array}
\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if k < 1e-84

    1. Initial program 56.1%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified56.1%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. associate-*l*50.8%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell \cdot \ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)}} \]
      2. associate-/r*55.4%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell}}{\ell}} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)} \]
      3. associate-+r+55.4%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \color{blue}{\left(\left(1 + 1\right) + {\left(\frac{k}{t}\right)}^{2}\right)}\right)\right)} \]
      4. metadata-eval55.4%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(\color{blue}{2} + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]
      5. associate-*l*55.4%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \color{blue}{\left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}} \]
      6. add-cube-cbrt55.4%

        \[\leadsto \frac{2}{\color{blue}{\left(\sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)} \cdot \sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}\right) \cdot \sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}}} \]
      7. pow355.4%

        \[\leadsto \frac{2}{\color{blue}{{\left(\sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}\right)}^{3}}} \]
    5. Applied egg-rr62.4%

      \[\leadsto \frac{2}{\color{blue}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}}} \]
    6. Step-by-step derivation
      1. pow1/361.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{{\left({\ell}^{-2}\right)}^{0.3333333333333333}}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      2. sqr-pow61.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\color{blue}{\left({\ell}^{\left(\frac{-2}{2}\right)} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      3. metadata-eval61.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left({\ell}^{\color{blue}{-1}} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      4. inv-pow61.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\color{blue}{\frac{1}{\ell}} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      5. metadata-eval61.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\frac{1}{\ell} \cdot {\ell}^{\color{blue}{-1}}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      6. inv-pow61.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\frac{1}{\ell} \cdot \color{blue}{\frac{1}{\ell}}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      7. unpow-prod-down36.8%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left({\left(\frac{1}{\ell}\right)}^{0.3333333333333333} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    7. Applied egg-rr36.8%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left({\left(\frac{1}{\ell}\right)}^{0.3333333333333333} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    8. Step-by-step derivation
      1. unpow1/336.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\color{blue}{\sqrt[3]{\frac{1}{\ell}}} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      2. unpow1/372.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \color{blue}{\sqrt[3]{\frac{1}{\ell}}}\right)\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    9. Simplified72.2%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    10. Taylor expanded in k around 0 67.0%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \color{blue}{\left(\sqrt[3]{{k}^{2}} \cdot \sqrt[3]{2}\right)}\right)}^{3}} \]
    11. Step-by-step derivation
      1. *-un-lft-identity67.0%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\color{blue}{\left(1 \cdot \sqrt[3]{{k}^{2}}\right)} \cdot \sqrt[3]{2}\right)\right)}^{3}} \]
      2. unpow267.0%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\left(1 \cdot \sqrt[3]{\color{blue}{k \cdot k}}\right) \cdot \sqrt[3]{2}\right)\right)}^{3}} \]
      3. cbrt-prod79.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\left(1 \cdot \color{blue}{\left(\sqrt[3]{k} \cdot \sqrt[3]{k}\right)}\right) \cdot \sqrt[3]{2}\right)\right)}^{3}} \]
      4. pow279.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\left(1 \cdot \color{blue}{{\left(\sqrt[3]{k}\right)}^{2}}\right) \cdot \sqrt[3]{2}\right)\right)}^{3}} \]
    12. Applied egg-rr79.9%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\color{blue}{\left(1 \cdot {\left(\sqrt[3]{k}\right)}^{2}\right)} \cdot \sqrt[3]{2}\right)\right)}^{3}} \]
    13. Step-by-step derivation
      1. *-lft-identity79.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\color{blue}{{\left(\sqrt[3]{k}\right)}^{2}} \cdot \sqrt[3]{2}\right)\right)}^{3}} \]
    14. Simplified79.9%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\color{blue}{{\left(\sqrt[3]{k}\right)}^{2}} \cdot \sqrt[3]{2}\right)\right)}^{3}} \]

    if 1e-84 < k

    1. Initial program 54.9%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified54.9%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Applied egg-rr31.6%

      \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)\right)}^{2}}} \]
    5. Step-by-step derivation
      1. associate-*r*31.5%

        \[\leadsto \frac{2}{{\color{blue}{\left(\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)}}^{2}} \]
      2. unpow-prod-down31.5%

        \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2} \cdot {\left(\sqrt{\sin k \cdot \tan k}\right)}^{2}}} \]
      3. pow231.5%

        \[\leadsto \frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2} \cdot \color{blue}{\left(\sqrt{\sin k \cdot \tan k} \cdot \sqrt{\sin k \cdot \tan k}\right)}} \]
      4. add-sqr-sqrt43.6%

        \[\leadsto \frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2} \cdot \color{blue}{\left(\sin k \cdot \tan k\right)}} \]
    6. Applied egg-rr43.6%

      \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2} \cdot \left(\sin k \cdot \tan k\right)}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification69.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;k \leq 10^{-84}:\\ \;\;\;\;\frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left({\left(\sqrt[3]{k}\right)}^{2} \cdot \sqrt[3]{2}\right)\right)}^{3}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{\left(\sin k \cdot \tan k\right) \cdot {\left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \frac{{t}^{1.5}}{\ell}\right)}^{2}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 42.0% accurate, 0.7× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ \begin{array}{l} t_2 := \sqrt[3]{\frac{1}{\ell}}\\ t\_s \cdot \begin{array}{l} \mathbf{if}\;k \leq 6.5 \cdot 10^{-85}:\\ \;\;\;\;\frac{2}{{\left(\left(t\_m \cdot \left(t\_2 \cdot t\_2\right)\right) \cdot \left(\sqrt[3]{2} \cdot {k}^{0.6666666666666666}\right)\right)}^{3}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{\left(\sin k \cdot \tan k\right) \cdot {\left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t\_m}\right)\right) \cdot \frac{{t\_m}^{1.5}}{\ell}\right)}^{2}}\\ \end{array} \end{array} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (let* ((t_2 (cbrt (/ 1.0 l))))
   (*
    t_s
    (if (<= k 6.5e-85)
      (/
       2.0
       (pow
        (* (* t_m (* t_2 t_2)) (* (cbrt 2.0) (pow k 0.6666666666666666)))
        3.0))
      (/
       2.0
       (*
        (* (sin k) (tan k))
        (pow
         (* (hypot 1.0 (hypot 1.0 (/ k t_m))) (/ (pow t_m 1.5) l))
         2.0)))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	double t_2 = cbrt((1.0 / l));
	double tmp;
	if (k <= 6.5e-85) {
		tmp = 2.0 / pow(((t_m * (t_2 * t_2)) * (cbrt(2.0) * pow(k, 0.6666666666666666))), 3.0);
	} else {
		tmp = 2.0 / ((sin(k) * tan(k)) * pow((hypot(1.0, hypot(1.0, (k / t_m))) * (pow(t_m, 1.5) / l)), 2.0));
	}
	return t_s * tmp;
}
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	double t_2 = Math.cbrt((1.0 / l));
	double tmp;
	if (k <= 6.5e-85) {
		tmp = 2.0 / Math.pow(((t_m * (t_2 * t_2)) * (Math.cbrt(2.0) * Math.pow(k, 0.6666666666666666))), 3.0);
	} else {
		tmp = 2.0 / ((Math.sin(k) * Math.tan(k)) * Math.pow((Math.hypot(1.0, Math.hypot(1.0, (k / t_m))) * (Math.pow(t_m, 1.5) / l)), 2.0));
	}
	return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	t_2 = cbrt(Float64(1.0 / l))
	tmp = 0.0
	if (k <= 6.5e-85)
		tmp = Float64(2.0 / (Float64(Float64(t_m * Float64(t_2 * t_2)) * Float64(cbrt(2.0) * (k ^ 0.6666666666666666))) ^ 3.0));
	else
		tmp = Float64(2.0 / Float64(Float64(sin(k) * tan(k)) * (Float64(hypot(1.0, hypot(1.0, Float64(k / t_m))) * Float64((t_m ^ 1.5) / l)) ^ 2.0)));
	end
	return Float64(t_s * tmp)
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := Block[{t$95$2 = N[Power[N[(1.0 / l), $MachinePrecision], 1/3], $MachinePrecision]}, N[(t$95$s * If[LessEqual[k, 6.5e-85], N[(2.0 / N[Power[N[(N[(t$95$m * N[(t$95$2 * t$95$2), $MachinePrecision]), $MachinePrecision] * N[(N[Power[2.0, 1/3], $MachinePrecision] * N[Power[k, 0.6666666666666666], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision] * N[Power[N[(N[Sqrt[1.0 ^ 2 + N[Sqrt[1.0 ^ 2 + N[(k / t$95$m), $MachinePrecision] ^ 2], $MachinePrecision] ^ 2], $MachinePrecision] * N[(N[Power[t$95$m, 1.5], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
\begin{array}{l}
t_2 := \sqrt[3]{\frac{1}{\ell}}\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 6.5 \cdot 10^{-85}:\\
\;\;\;\;\frac{2}{{\left(\left(t\_m \cdot \left(t\_2 \cdot t\_2\right)\right) \cdot \left(\sqrt[3]{2} \cdot {k}^{0.6666666666666666}\right)\right)}^{3}}\\

\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(\sin k \cdot \tan k\right) \cdot {\left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t\_m}\right)\right) \cdot \frac{{t\_m}^{1.5}}{\ell}\right)}^{2}}\\


\end{array}
\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if k < 6.5e-85

    1. Initial program 56.1%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified56.1%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. associate-*l*50.8%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell \cdot \ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)}} \]
      2. associate-/r*55.4%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell}}{\ell}} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)} \]
      3. associate-+r+55.4%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \color{blue}{\left(\left(1 + 1\right) + {\left(\frac{k}{t}\right)}^{2}\right)}\right)\right)} \]
      4. metadata-eval55.4%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(\color{blue}{2} + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]
      5. associate-*l*55.4%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \color{blue}{\left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}} \]
      6. add-cube-cbrt55.4%

        \[\leadsto \frac{2}{\color{blue}{\left(\sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)} \cdot \sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}\right) \cdot \sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}}} \]
      7. pow355.4%

        \[\leadsto \frac{2}{\color{blue}{{\left(\sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}\right)}^{3}}} \]
    5. Applied egg-rr62.4%

      \[\leadsto \frac{2}{\color{blue}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}}} \]
    6. Step-by-step derivation
      1. pow1/361.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{{\left({\ell}^{-2}\right)}^{0.3333333333333333}}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      2. sqr-pow61.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\color{blue}{\left({\ell}^{\left(\frac{-2}{2}\right)} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      3. metadata-eval61.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left({\ell}^{\color{blue}{-1}} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      4. inv-pow61.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\color{blue}{\frac{1}{\ell}} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      5. metadata-eval61.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\frac{1}{\ell} \cdot {\ell}^{\color{blue}{-1}}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      6. inv-pow61.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\frac{1}{\ell} \cdot \color{blue}{\frac{1}{\ell}}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      7. unpow-prod-down36.8%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left({\left(\frac{1}{\ell}\right)}^{0.3333333333333333} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    7. Applied egg-rr36.8%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left({\left(\frac{1}{\ell}\right)}^{0.3333333333333333} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    8. Step-by-step derivation
      1. unpow1/336.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\color{blue}{\sqrt[3]{\frac{1}{\ell}}} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      2. unpow1/372.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \color{blue}{\sqrt[3]{\frac{1}{\ell}}}\right)\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    9. Simplified72.2%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    10. Taylor expanded in k around 0 67.0%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \color{blue}{\left(\sqrt[3]{{k}^{2}} \cdot \sqrt[3]{2}\right)}\right)}^{3}} \]
    11. Step-by-step derivation
      1. pow1/366.4%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\color{blue}{{\left({k}^{2}\right)}^{0.3333333333333333}} \cdot \sqrt[3]{2}\right)\right)}^{3}} \]
      2. pow-pow26.1%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\color{blue}{{k}^{\left(2 \cdot 0.3333333333333333\right)}} \cdot \sqrt[3]{2}\right)\right)}^{3}} \]
      3. metadata-eval26.1%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left({k}^{\color{blue}{0.6666666666666666}} \cdot \sqrt[3]{2}\right)\right)}^{3}} \]
    12. Applied egg-rr26.1%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\color{blue}{{k}^{0.6666666666666666}} \cdot \sqrt[3]{2}\right)\right)}^{3}} \]

    if 6.5e-85 < k

    1. Initial program 54.9%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified54.9%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Applied egg-rr31.6%

      \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)\right)}^{2}}} \]
    5. Step-by-step derivation
      1. associate-*r*31.5%

        \[\leadsto \frac{2}{{\color{blue}{\left(\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)}}^{2}} \]
      2. unpow-prod-down31.5%

        \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2} \cdot {\left(\sqrt{\sin k \cdot \tan k}\right)}^{2}}} \]
      3. pow231.5%

        \[\leadsto \frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2} \cdot \color{blue}{\left(\sqrt{\sin k \cdot \tan k} \cdot \sqrt{\sin k \cdot \tan k}\right)}} \]
      4. add-sqr-sqrt43.6%

        \[\leadsto \frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2} \cdot \color{blue}{\left(\sin k \cdot \tan k\right)}} \]
    6. Applied egg-rr43.6%

      \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right)\right)}^{2} \cdot \left(\sin k \cdot \tan k\right)}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification31.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;k \leq 6.5 \cdot 10^{-85}:\\ \;\;\;\;\frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\sqrt[3]{2} \cdot {k}^{0.6666666666666666}\right)\right)}^{3}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{\left(\sin k \cdot \tan k\right) \cdot {\left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \frac{{t}^{1.5}}{\ell}\right)}^{2}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 5: 77.7% accurate, 0.8× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ \begin{array}{l} t_2 := {\left(\frac{k}{t\_m}\right)}^{2}\\ t\_s \cdot \begin{array}{l} \mathbf{if}\;t\_m \leq 1.65 \cdot 10^{-137}:\\ \;\;\;\;\frac{2}{{\left(\frac{k \cdot \sin k}{\ell} \cdot \sqrt{\frac{t\_m}{\cos k}}\right)}^{2}}\\ \mathbf{elif}\;t\_m \leq 3.4 \cdot 10^{-94}:\\ \;\;\;\;\frac{2}{\left(\sin k \cdot \left(\frac{{t\_m}^{2}}{\ell} \cdot \frac{t\_m}{\ell}\right)\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + t\_2\right)\right)\right)}\\ \mathbf{elif}\;t\_m \leq 9.8 \cdot 10^{+89}:\\ \;\;\;\;\frac{2}{\frac{{t\_m}^{3}}{\ell} \cdot \left(\sin k \cdot \frac{\tan k \cdot \left(2 + t\_2\right)}{\ell}\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{2 \cdot {\left(t\_m \cdot \left({\left(\sqrt[3]{k}\right)}^{2} \cdot \sqrt[3]{{\ell}^{-2}}\right)\right)}^{3}}\\ \end{array} \end{array} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (let* ((t_2 (pow (/ k t_m) 2.0)))
   (*
    t_s
    (if (<= t_m 1.65e-137)
      (/ 2.0 (pow (* (/ (* k (sin k)) l) (sqrt (/ t_m (cos k)))) 2.0))
      (if (<= t_m 3.4e-94)
        (/
         2.0
         (*
          (* (sin k) (* (/ (pow t_m 2.0) l) (/ t_m l)))
          (* (tan k) (+ 1.0 (+ 1.0 t_2)))))
        (if (<= t_m 9.8e+89)
          (/
           2.0
           (* (/ (pow t_m 3.0) l) (* (sin k) (/ (* (tan k) (+ 2.0 t_2)) l))))
          (/
           2.0
           (*
            2.0
            (pow
             (* t_m (* (pow (cbrt k) 2.0) (cbrt (pow l -2.0))))
             3.0)))))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	double t_2 = pow((k / t_m), 2.0);
	double tmp;
	if (t_m <= 1.65e-137) {
		tmp = 2.0 / pow((((k * sin(k)) / l) * sqrt((t_m / cos(k)))), 2.0);
	} else if (t_m <= 3.4e-94) {
		tmp = 2.0 / ((sin(k) * ((pow(t_m, 2.0) / l) * (t_m / l))) * (tan(k) * (1.0 + (1.0 + t_2))));
	} else if (t_m <= 9.8e+89) {
		tmp = 2.0 / ((pow(t_m, 3.0) / l) * (sin(k) * ((tan(k) * (2.0 + t_2)) / l)));
	} else {
		tmp = 2.0 / (2.0 * pow((t_m * (pow(cbrt(k), 2.0) * cbrt(pow(l, -2.0)))), 3.0));
	}
	return t_s * tmp;
}
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	double t_2 = Math.pow((k / t_m), 2.0);
	double tmp;
	if (t_m <= 1.65e-137) {
		tmp = 2.0 / Math.pow((((k * Math.sin(k)) / l) * Math.sqrt((t_m / Math.cos(k)))), 2.0);
	} else if (t_m <= 3.4e-94) {
		tmp = 2.0 / ((Math.sin(k) * ((Math.pow(t_m, 2.0) / l) * (t_m / l))) * (Math.tan(k) * (1.0 + (1.0 + t_2))));
	} else if (t_m <= 9.8e+89) {
		tmp = 2.0 / ((Math.pow(t_m, 3.0) / l) * (Math.sin(k) * ((Math.tan(k) * (2.0 + t_2)) / l)));
	} else {
		tmp = 2.0 / (2.0 * Math.pow((t_m * (Math.pow(Math.cbrt(k), 2.0) * Math.cbrt(Math.pow(l, -2.0)))), 3.0));
	}
	return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	t_2 = Float64(k / t_m) ^ 2.0
	tmp = 0.0
	if (t_m <= 1.65e-137)
		tmp = Float64(2.0 / (Float64(Float64(Float64(k * sin(k)) / l) * sqrt(Float64(t_m / cos(k)))) ^ 2.0));
	elseif (t_m <= 3.4e-94)
		tmp = Float64(2.0 / Float64(Float64(sin(k) * Float64(Float64((t_m ^ 2.0) / l) * Float64(t_m / l))) * Float64(tan(k) * Float64(1.0 + Float64(1.0 + t_2)))));
	elseif (t_m <= 9.8e+89)
		tmp = Float64(2.0 / Float64(Float64((t_m ^ 3.0) / l) * Float64(sin(k) * Float64(Float64(tan(k) * Float64(2.0 + t_2)) / l))));
	else
		tmp = Float64(2.0 / Float64(2.0 * (Float64(t_m * Float64((cbrt(k) ^ 2.0) * cbrt((l ^ -2.0)))) ^ 3.0)));
	end
	return Float64(t_s * tmp)
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := Block[{t$95$2 = N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]}, N[(t$95$s * If[LessEqual[t$95$m, 1.65e-137], N[(2.0 / N[Power[N[(N[(N[(k * N[Sin[k], $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision] * N[Sqrt[N[(t$95$m / N[Cos[k], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 3.4e-94], N[(2.0 / N[(N[(N[Sin[k], $MachinePrecision] * N[(N[(N[Power[t$95$m, 2.0], $MachinePrecision] / l), $MachinePrecision] * N[(t$95$m / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[Tan[k], $MachinePrecision] * N[(1.0 + N[(1.0 + t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 9.8e+89], N[(2.0 / N[(N[(N[Power[t$95$m, 3.0], $MachinePrecision] / l), $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[(N[(N[Tan[k], $MachinePrecision] * N[(2.0 + t$95$2), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(2.0 * N[Power[N[(t$95$m * N[(N[Power[N[Power[k, 1/3], $MachinePrecision], 2.0], $MachinePrecision] * N[Power[N[Power[l, -2.0], $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]), $MachinePrecision]]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
\begin{array}{l}
t_2 := {\left(\frac{k}{t\_m}\right)}^{2}\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 1.65 \cdot 10^{-137}:\\
\;\;\;\;\frac{2}{{\left(\frac{k \cdot \sin k}{\ell} \cdot \sqrt{\frac{t\_m}{\cos k}}\right)}^{2}}\\

\mathbf{elif}\;t\_m \leq 3.4 \cdot 10^{-94}:\\
\;\;\;\;\frac{2}{\left(\sin k \cdot \left(\frac{{t\_m}^{2}}{\ell} \cdot \frac{t\_m}{\ell}\right)\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + t\_2\right)\right)\right)}\\

\mathbf{elif}\;t\_m \leq 9.8 \cdot 10^{+89}:\\
\;\;\;\;\frac{2}{\frac{{t\_m}^{3}}{\ell} \cdot \left(\sin k \cdot \frac{\tan k \cdot \left(2 + t\_2\right)}{\ell}\right)}\\

\mathbf{else}:\\
\;\;\;\;\frac{2}{2 \cdot {\left(t\_m \cdot \left({\left(\sqrt[3]{k}\right)}^{2} \cdot \sqrt[3]{{\ell}^{-2}}\right)\right)}^{3}}\\


\end{array}
\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < 1.6500000000000001e-137

    1. Initial program 48.7%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified48.7%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Applied egg-rr10.7%

      \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)\right)}^{2}}} \]
    5. Taylor expanded in t around 0 29.2%

      \[\leadsto \frac{2}{{\color{blue}{\left(\frac{k \cdot \sin k}{\ell} \cdot \sqrt{\frac{t}{\cos k}}\right)}}^{2}} \]

    if 1.6500000000000001e-137 < t < 3.3999999999999998e-94

    1. Initial program 38.9%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified38.9%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. unpow338.9%

        \[\leadsto \frac{2}{\left(\frac{\color{blue}{\left(t \cdot t\right) \cdot t}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]
      2. times-frac74.8%

        \[\leadsto \frac{2}{\left(\color{blue}{\left(\frac{t \cdot t}{\ell} \cdot \frac{t}{\ell}\right)} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]
      3. pow274.8%

        \[\leadsto \frac{2}{\left(\left(\frac{\color{blue}{{t}^{2}}}{\ell} \cdot \frac{t}{\ell}\right) \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]
    5. Applied egg-rr74.8%

      \[\leadsto \frac{2}{\left(\color{blue}{\left(\frac{{t}^{2}}{\ell} \cdot \frac{t}{\ell}\right)} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]

    if 3.3999999999999998e-94 < t < 9.79999999999999992e89

    1. Initial program 77.3%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified77.3%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. associate-*l*75.0%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell \cdot \ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)}} \]
      2. associate-/r*77.2%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell}}{\ell}} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)} \]
      3. associate-+r+77.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \color{blue}{\left(\left(1 + 1\right) + {\left(\frac{k}{t}\right)}^{2}\right)}\right)\right)} \]
      4. metadata-eval77.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(\color{blue}{2} + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]
      5. associate-*l*77.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \color{blue}{\left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}} \]
      6. associate-*l/79.8%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}{\ell}}} \]
    5. Applied egg-rr79.8%

      \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}{\ell}}} \]
    6. Step-by-step derivation
      1. associate-/l*79.8%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell} \cdot \frac{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}{\ell}}} \]
      2. associate-*l*79.8%

        \[\leadsto \frac{2}{\frac{{t}^{3}}{\ell} \cdot \frac{\color{blue}{\sin k \cdot \left(\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}}{\ell}} \]
    7. Simplified79.8%

      \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell} \cdot \frac{\sin k \cdot \left(\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}{\ell}}} \]
    8. Step-by-step derivation
      1. associate-/l*86.6%

        \[\leadsto \frac{2}{\frac{{t}^{3}}{\ell} \cdot \color{blue}{\left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}{\ell}\right)}} \]
    9. Applied egg-rr86.6%

      \[\leadsto \frac{2}{\frac{{t}^{3}}{\ell} \cdot \color{blue}{\left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}{\ell}\right)}} \]

    if 9.79999999999999992e89 < t

    1. Initial program 66.4%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified66.4%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. associate-*l*50.3%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell \cdot \ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)}} \]
      2. associate-/r*53.2%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell}}{\ell}} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)} \]
      3. associate-+r+53.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \color{blue}{\left(\left(1 + 1\right) + {\left(\frac{k}{t}\right)}^{2}\right)}\right)\right)} \]
      4. metadata-eval53.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(\color{blue}{2} + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]
      5. associate-*l*53.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \color{blue}{\left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}} \]
      6. add-cube-cbrt53.2%

        \[\leadsto \frac{2}{\color{blue}{\left(\sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)} \cdot \sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}\right) \cdot \sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}}} \]
      7. pow353.2%

        \[\leadsto \frac{2}{\color{blue}{{\left(\sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}\right)}^{3}}} \]
    5. Applied egg-rr59.7%

      \[\leadsto \frac{2}{\color{blue}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}}} \]
    6. Step-by-step derivation
      1. pow1/359.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{{\left({\ell}^{-2}\right)}^{0.3333333333333333}}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      2. sqr-pow59.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\color{blue}{\left({\ell}^{\left(\frac{-2}{2}\right)} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      3. metadata-eval59.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left({\ell}^{\color{blue}{-1}} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      4. inv-pow59.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\color{blue}{\frac{1}{\ell}} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      5. metadata-eval59.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\frac{1}{\ell} \cdot {\ell}^{\color{blue}{-1}}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      6. inv-pow59.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\frac{1}{\ell} \cdot \color{blue}{\frac{1}{\ell}}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      7. unpow-prod-down39.1%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left({\left(\frac{1}{\ell}\right)}^{0.3333333333333333} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    7. Applied egg-rr39.1%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left({\left(\frac{1}{\ell}\right)}^{0.3333333333333333} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    8. Step-by-step derivation
      1. unpow1/339.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\color{blue}{\sqrt[3]{\frac{1}{\ell}}} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      2. unpow1/369.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \color{blue}{\sqrt[3]{\frac{1}{\ell}}}\right)\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    9. Simplified69.6%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    10. Taylor expanded in k around 0 65.0%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \color{blue}{\left(\sqrt[3]{{k}^{2}} \cdot \sqrt[3]{2}\right)}\right)}^{3}} \]
    11. Step-by-step derivation
      1. associate-*r*65.0%

        \[\leadsto \frac{2}{{\color{blue}{\left(\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \sqrt[3]{{k}^{2}}\right) \cdot \sqrt[3]{2}\right)}}^{3}} \]
      2. unpow-prod-down65.0%

        \[\leadsto \frac{2}{\color{blue}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \sqrt[3]{{k}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}}} \]
      3. cbrt-unprod59.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\sqrt[3]{\frac{1}{\ell} \cdot \frac{1}{\ell}}}\right) \cdot \sqrt[3]{{k}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      4. inv-pow59.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{\color{blue}{{\ell}^{-1}} \cdot \frac{1}{\ell}}\right) \cdot \sqrt[3]{{k}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      5. inv-pow59.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-1} \cdot \color{blue}{{\ell}^{-1}}}\right) \cdot \sqrt[3]{{k}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      6. pow-prod-up59.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{\color{blue}{{\ell}^{\left(-1 + -1\right)}}}\right) \cdot \sqrt[3]{{k}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      7. metadata-eval59.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{\color{blue}{-2}}}\right) \cdot \sqrt[3]{{k}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      8. unpow259.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot \sqrt[3]{\color{blue}{k \cdot k}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      9. cbrt-prod84.8%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot \color{blue}{\left(\sqrt[3]{k} \cdot \sqrt[3]{k}\right)}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      10. pow284.8%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot \color{blue}{{\left(\sqrt[3]{k}\right)}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
    12. Applied egg-rr84.8%

      \[\leadsto \frac{2}{\color{blue}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot {\left(\sqrt[3]{k}\right)}^{2}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}}} \]
    13. Step-by-step derivation
      1. rem-cube-cbrt84.8%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot {\left(\sqrt[3]{k}\right)}^{2}\right)}^{3} \cdot \color{blue}{2}} \]
      2. *-commutative84.8%

        \[\leadsto \frac{2}{\color{blue}{2 \cdot {\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot {\left(\sqrt[3]{k}\right)}^{2}\right)}^{3}}} \]
      3. associate-*l*84.9%

        \[\leadsto \frac{2}{2 \cdot {\color{blue}{\left(t \cdot \left(\sqrt[3]{{\ell}^{-2}} \cdot {\left(\sqrt[3]{k}\right)}^{2}\right)\right)}}^{3}} \]
    14. Simplified84.9%

      \[\leadsto \frac{2}{\color{blue}{2 \cdot {\left(t \cdot \left(\sqrt[3]{{\ell}^{-2}} \cdot {\left(\sqrt[3]{k}\right)}^{2}\right)\right)}^{3}}} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification48.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq 1.65 \cdot 10^{-137}:\\ \;\;\;\;\frac{2}{{\left(\frac{k \cdot \sin k}{\ell} \cdot \sqrt{\frac{t}{\cos k}}\right)}^{2}}\\ \mathbf{elif}\;t \leq 3.4 \cdot 10^{-94}:\\ \;\;\;\;\frac{2}{\left(\sin k \cdot \left(\frac{{t}^{2}}{\ell} \cdot \frac{t}{\ell}\right)\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}\\ \mathbf{elif}\;t \leq 9.8 \cdot 10^{+89}:\\ \;\;\;\;\frac{2}{\frac{{t}^{3}}{\ell} \cdot \left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}{\ell}\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{2 \cdot {\left(t \cdot \left({\left(\sqrt[3]{k}\right)}^{2} \cdot \sqrt[3]{{\ell}^{-2}}\right)\right)}^{3}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 6: 77.3% accurate, 0.8× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ t\_s \cdot \begin{array}{l} \mathbf{if}\;t\_m \leq 5.7 \cdot 10^{-73}:\\ \;\;\;\;\frac{2}{\frac{\left(t\_m \cdot {k}^{2}\right) \cdot {\sin k}^{2}}{{\ell}^{2} \cdot \cos k}}\\ \mathbf{elif}\;t\_m \leq 9.5 \cdot 10^{+89}:\\ \;\;\;\;\frac{2}{\frac{{t\_m}^{3}}{\ell} \cdot \left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t\_m}\right)}^{2}\right)}{\ell}\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{2 \cdot {\left(t\_m \cdot \left({\left(\sqrt[3]{k}\right)}^{2} \cdot \sqrt[3]{{\ell}^{-2}}\right)\right)}^{3}}\\ \end{array} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (*
  t_s
  (if (<= t_m 5.7e-73)
    (/
     2.0
     (/ (* (* t_m (pow k 2.0)) (pow (sin k) 2.0)) (* (pow l 2.0) (cos k))))
    (if (<= t_m 9.5e+89)
      (/
       2.0
       (*
        (/ (pow t_m 3.0) l)
        (* (sin k) (/ (* (tan k) (+ 2.0 (pow (/ k t_m) 2.0))) l))))
      (/
       2.0
       (*
        2.0
        (pow (* t_m (* (pow (cbrt k) 2.0) (cbrt (pow l -2.0)))) 3.0)))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (t_m <= 5.7e-73) {
		tmp = 2.0 / (((t_m * pow(k, 2.0)) * pow(sin(k), 2.0)) / (pow(l, 2.0) * cos(k)));
	} else if (t_m <= 9.5e+89) {
		tmp = 2.0 / ((pow(t_m, 3.0) / l) * (sin(k) * ((tan(k) * (2.0 + pow((k / t_m), 2.0))) / l)));
	} else {
		tmp = 2.0 / (2.0 * pow((t_m * (pow(cbrt(k), 2.0) * cbrt(pow(l, -2.0)))), 3.0));
	}
	return t_s * tmp;
}
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (t_m <= 5.7e-73) {
		tmp = 2.0 / (((t_m * Math.pow(k, 2.0)) * Math.pow(Math.sin(k), 2.0)) / (Math.pow(l, 2.0) * Math.cos(k)));
	} else if (t_m <= 9.5e+89) {
		tmp = 2.0 / ((Math.pow(t_m, 3.0) / l) * (Math.sin(k) * ((Math.tan(k) * (2.0 + Math.pow((k / t_m), 2.0))) / l)));
	} else {
		tmp = 2.0 / (2.0 * Math.pow((t_m * (Math.pow(Math.cbrt(k), 2.0) * Math.cbrt(Math.pow(l, -2.0)))), 3.0));
	}
	return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	tmp = 0.0
	if (t_m <= 5.7e-73)
		tmp = Float64(2.0 / Float64(Float64(Float64(t_m * (k ^ 2.0)) * (sin(k) ^ 2.0)) / Float64((l ^ 2.0) * cos(k))));
	elseif (t_m <= 9.5e+89)
		tmp = Float64(2.0 / Float64(Float64((t_m ^ 3.0) / l) * Float64(sin(k) * Float64(Float64(tan(k) * Float64(2.0 + (Float64(k / t_m) ^ 2.0))) / l))));
	else
		tmp = Float64(2.0 / Float64(2.0 * (Float64(t_m * Float64((cbrt(k) ^ 2.0) * cbrt((l ^ -2.0)))) ^ 3.0)));
	end
	return Float64(t_s * tmp)
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[t$95$m, 5.7e-73], N[(2.0 / N[(N[(N[(t$95$m * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[Power[N[Sin[k], $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] / N[(N[Power[l, 2.0], $MachinePrecision] * N[Cos[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 9.5e+89], N[(2.0 / N[(N[(N[Power[t$95$m, 3.0], $MachinePrecision] / l), $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[(N[(N[Tan[k], $MachinePrecision] * N[(2.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(2.0 * N[Power[N[(t$95$m * N[(N[Power[N[Power[k, 1/3], $MachinePrecision], 2.0], $MachinePrecision] * N[Power[N[Power[l, -2.0], $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 5.7 \cdot 10^{-73}:\\
\;\;\;\;\frac{2}{\frac{\left(t\_m \cdot {k}^{2}\right) \cdot {\sin k}^{2}}{{\ell}^{2} \cdot \cos k}}\\

\mathbf{elif}\;t\_m \leq 9.5 \cdot 10^{+89}:\\
\;\;\;\;\frac{2}{\frac{{t\_m}^{3}}{\ell} \cdot \left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t\_m}\right)}^{2}\right)}{\ell}\right)}\\

\mathbf{else}:\\
\;\;\;\;\frac{2}{2 \cdot {\left(t\_m \cdot \left({\left(\sqrt[3]{k}\right)}^{2} \cdot \sqrt[3]{{\ell}^{-2}}\right)\right)}^{3}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < 5.6999999999999998e-73

    1. Initial program 50.0%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified50.0%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in t around 0 69.8%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot \left(t \cdot {\sin k}^{2}\right)}{{\ell}^{2} \cdot \cos k}}} \]
    5. Step-by-step derivation
      1. associate-*r*69.8%

        \[\leadsto \frac{2}{\frac{\color{blue}{\left({k}^{2} \cdot t\right) \cdot {\sin k}^{2}}}{{\ell}^{2} \cdot \cos k}} \]
    6. Simplified69.8%

      \[\leadsto \frac{2}{\color{blue}{\frac{\left({k}^{2} \cdot t\right) \cdot {\sin k}^{2}}{{\ell}^{2} \cdot \cos k}}} \]

    if 5.6999999999999998e-73 < t < 9.5000000000000003e89

    1. Initial program 74.9%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified75.0%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. associate-*l*72.1%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell \cdot \ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)}} \]
      2. associate-/r*74.8%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell}}{\ell}} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)} \]
      3. associate-+r+74.8%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \color{blue}{\left(\left(1 + 1\right) + {\left(\frac{k}{t}\right)}^{2}\right)}\right)\right)} \]
      4. metadata-eval74.8%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(\color{blue}{2} + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]
      5. associate-*l*74.8%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \color{blue}{\left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}} \]
      6. associate-*l/78.0%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}{\ell}}} \]
    5. Applied egg-rr78.0%

      \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}{\ell}}} \]
    6. Step-by-step derivation
      1. associate-/l*78.0%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell} \cdot \frac{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}{\ell}}} \]
      2. associate-*l*78.0%

        \[\leadsto \frac{2}{\frac{{t}^{3}}{\ell} \cdot \frac{\color{blue}{\sin k \cdot \left(\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}}{\ell}} \]
    7. Simplified78.0%

      \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell} \cdot \frac{\sin k \cdot \left(\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}{\ell}}} \]
    8. Step-by-step derivation
      1. associate-/l*86.4%

        \[\leadsto \frac{2}{\frac{{t}^{3}}{\ell} \cdot \color{blue}{\left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}{\ell}\right)}} \]
    9. Applied egg-rr86.4%

      \[\leadsto \frac{2}{\frac{{t}^{3}}{\ell} \cdot \color{blue}{\left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}{\ell}\right)}} \]

    if 9.5000000000000003e89 < t

    1. Initial program 66.4%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified66.4%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. associate-*l*50.3%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell \cdot \ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)}} \]
      2. associate-/r*53.2%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell}}{\ell}} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)} \]
      3. associate-+r+53.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \color{blue}{\left(\left(1 + 1\right) + {\left(\frac{k}{t}\right)}^{2}\right)}\right)\right)} \]
      4. metadata-eval53.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(\color{blue}{2} + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]
      5. associate-*l*53.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \color{blue}{\left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}} \]
      6. add-cube-cbrt53.2%

        \[\leadsto \frac{2}{\color{blue}{\left(\sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)} \cdot \sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}\right) \cdot \sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}}} \]
      7. pow353.2%

        \[\leadsto \frac{2}{\color{blue}{{\left(\sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}\right)}^{3}}} \]
    5. Applied egg-rr59.7%

      \[\leadsto \frac{2}{\color{blue}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}}} \]
    6. Step-by-step derivation
      1. pow1/359.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{{\left({\ell}^{-2}\right)}^{0.3333333333333333}}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      2. sqr-pow59.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\color{blue}{\left({\ell}^{\left(\frac{-2}{2}\right)} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      3. metadata-eval59.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left({\ell}^{\color{blue}{-1}} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      4. inv-pow59.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\color{blue}{\frac{1}{\ell}} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      5. metadata-eval59.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\frac{1}{\ell} \cdot {\ell}^{\color{blue}{-1}}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      6. inv-pow59.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\frac{1}{\ell} \cdot \color{blue}{\frac{1}{\ell}}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      7. unpow-prod-down39.1%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left({\left(\frac{1}{\ell}\right)}^{0.3333333333333333} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    7. Applied egg-rr39.1%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left({\left(\frac{1}{\ell}\right)}^{0.3333333333333333} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    8. Step-by-step derivation
      1. unpow1/339.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\color{blue}{\sqrt[3]{\frac{1}{\ell}}} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      2. unpow1/369.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \color{blue}{\sqrt[3]{\frac{1}{\ell}}}\right)\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    9. Simplified69.6%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    10. Taylor expanded in k around 0 65.0%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \color{blue}{\left(\sqrt[3]{{k}^{2}} \cdot \sqrt[3]{2}\right)}\right)}^{3}} \]
    11. Step-by-step derivation
      1. associate-*r*65.0%

        \[\leadsto \frac{2}{{\color{blue}{\left(\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \sqrt[3]{{k}^{2}}\right) \cdot \sqrt[3]{2}\right)}}^{3}} \]
      2. unpow-prod-down65.0%

        \[\leadsto \frac{2}{\color{blue}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \sqrt[3]{{k}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}}} \]
      3. cbrt-unprod59.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\sqrt[3]{\frac{1}{\ell} \cdot \frac{1}{\ell}}}\right) \cdot \sqrt[3]{{k}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      4. inv-pow59.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{\color{blue}{{\ell}^{-1}} \cdot \frac{1}{\ell}}\right) \cdot \sqrt[3]{{k}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      5. inv-pow59.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-1} \cdot \color{blue}{{\ell}^{-1}}}\right) \cdot \sqrt[3]{{k}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      6. pow-prod-up59.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{\color{blue}{{\ell}^{\left(-1 + -1\right)}}}\right) \cdot \sqrt[3]{{k}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      7. metadata-eval59.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{\color{blue}{-2}}}\right) \cdot \sqrt[3]{{k}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      8. unpow259.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot \sqrt[3]{\color{blue}{k \cdot k}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      9. cbrt-prod84.8%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot \color{blue}{\left(\sqrt[3]{k} \cdot \sqrt[3]{k}\right)}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      10. pow284.8%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot \color{blue}{{\left(\sqrt[3]{k}\right)}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
    12. Applied egg-rr84.8%

      \[\leadsto \frac{2}{\color{blue}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot {\left(\sqrt[3]{k}\right)}^{2}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}}} \]
    13. Step-by-step derivation
      1. rem-cube-cbrt84.8%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot {\left(\sqrt[3]{k}\right)}^{2}\right)}^{3} \cdot \color{blue}{2}} \]
      2. *-commutative84.8%

        \[\leadsto \frac{2}{\color{blue}{2 \cdot {\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot {\left(\sqrt[3]{k}\right)}^{2}\right)}^{3}}} \]
      3. associate-*l*84.9%

        \[\leadsto \frac{2}{2 \cdot {\color{blue}{\left(t \cdot \left(\sqrt[3]{{\ell}^{-2}} \cdot {\left(\sqrt[3]{k}\right)}^{2}\right)\right)}}^{3}} \]
    14. Simplified84.9%

      \[\leadsto \frac{2}{\color{blue}{2 \cdot {\left(t \cdot \left(\sqrt[3]{{\ell}^{-2}} \cdot {\left(\sqrt[3]{k}\right)}^{2}\right)\right)}^{3}}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification74.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq 5.7 \cdot 10^{-73}:\\ \;\;\;\;\frac{2}{\frac{\left(t \cdot {k}^{2}\right) \cdot {\sin k}^{2}}{{\ell}^{2} \cdot \cos k}}\\ \mathbf{elif}\;t \leq 9.5 \cdot 10^{+89}:\\ \;\;\;\;\frac{2}{\frac{{t}^{3}}{\ell} \cdot \left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}{\ell}\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{2 \cdot {\left(t \cdot \left({\left(\sqrt[3]{k}\right)}^{2} \cdot \sqrt[3]{{\ell}^{-2}}\right)\right)}^{3}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 7: 77.7% accurate, 0.8× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ t\_s \cdot \begin{array}{l} \mathbf{if}\;t\_m \leq 8 \cdot 10^{-73}:\\ \;\;\;\;\frac{2}{\frac{t\_m \cdot {k}^{2}}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}\\ \mathbf{elif}\;t\_m \leq 7 \cdot 10^{+89}:\\ \;\;\;\;\frac{2}{\frac{{t\_m}^{3}}{\ell} \cdot \left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t\_m}\right)}^{2}\right)}{\ell}\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{2 \cdot {\left(t\_m \cdot \left({\left(\sqrt[3]{k}\right)}^{2} \cdot \sqrt[3]{{\ell}^{-2}}\right)\right)}^{3}}\\ \end{array} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (*
  t_s
  (if (<= t_m 8e-73)
    (/
     2.0
     (* (/ (* t_m (pow k 2.0)) (pow l 2.0)) (/ (pow (sin k) 2.0) (cos k))))
    (if (<= t_m 7e+89)
      (/
       2.0
       (*
        (/ (pow t_m 3.0) l)
        (* (sin k) (/ (* (tan k) (+ 2.0 (pow (/ k t_m) 2.0))) l))))
      (/
       2.0
       (*
        2.0
        (pow (* t_m (* (pow (cbrt k) 2.0) (cbrt (pow l -2.0)))) 3.0)))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (t_m <= 8e-73) {
		tmp = 2.0 / (((t_m * pow(k, 2.0)) / pow(l, 2.0)) * (pow(sin(k), 2.0) / cos(k)));
	} else if (t_m <= 7e+89) {
		tmp = 2.0 / ((pow(t_m, 3.0) / l) * (sin(k) * ((tan(k) * (2.0 + pow((k / t_m), 2.0))) / l)));
	} else {
		tmp = 2.0 / (2.0 * pow((t_m * (pow(cbrt(k), 2.0) * cbrt(pow(l, -2.0)))), 3.0));
	}
	return t_s * tmp;
}
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (t_m <= 8e-73) {
		tmp = 2.0 / (((t_m * Math.pow(k, 2.0)) / Math.pow(l, 2.0)) * (Math.pow(Math.sin(k), 2.0) / Math.cos(k)));
	} else if (t_m <= 7e+89) {
		tmp = 2.0 / ((Math.pow(t_m, 3.0) / l) * (Math.sin(k) * ((Math.tan(k) * (2.0 + Math.pow((k / t_m), 2.0))) / l)));
	} else {
		tmp = 2.0 / (2.0 * Math.pow((t_m * (Math.pow(Math.cbrt(k), 2.0) * Math.cbrt(Math.pow(l, -2.0)))), 3.0));
	}
	return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	tmp = 0.0
	if (t_m <= 8e-73)
		tmp = Float64(2.0 / Float64(Float64(Float64(t_m * (k ^ 2.0)) / (l ^ 2.0)) * Float64((sin(k) ^ 2.0) / cos(k))));
	elseif (t_m <= 7e+89)
		tmp = Float64(2.0 / Float64(Float64((t_m ^ 3.0) / l) * Float64(sin(k) * Float64(Float64(tan(k) * Float64(2.0 + (Float64(k / t_m) ^ 2.0))) / l))));
	else
		tmp = Float64(2.0 / Float64(2.0 * (Float64(t_m * Float64((cbrt(k) ^ 2.0) * cbrt((l ^ -2.0)))) ^ 3.0)));
	end
	return Float64(t_s * tmp)
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[t$95$m, 8e-73], N[(2.0 / N[(N[(N[(t$95$m * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] / N[Power[l, 2.0], $MachinePrecision]), $MachinePrecision] * N[(N[Power[N[Sin[k], $MachinePrecision], 2.0], $MachinePrecision] / N[Cos[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 7e+89], N[(2.0 / N[(N[(N[Power[t$95$m, 3.0], $MachinePrecision] / l), $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[(N[(N[Tan[k], $MachinePrecision] * N[(2.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(2.0 * N[Power[N[(t$95$m * N[(N[Power[N[Power[k, 1/3], $MachinePrecision], 2.0], $MachinePrecision] * N[Power[N[Power[l, -2.0], $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 8 \cdot 10^{-73}:\\
\;\;\;\;\frac{2}{\frac{t\_m \cdot {k}^{2}}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}\\

\mathbf{elif}\;t\_m \leq 7 \cdot 10^{+89}:\\
\;\;\;\;\frac{2}{\frac{{t\_m}^{3}}{\ell} \cdot \left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t\_m}\right)}^{2}\right)}{\ell}\right)}\\

\mathbf{else}:\\
\;\;\;\;\frac{2}{2 \cdot {\left(t\_m \cdot \left({\left(\sqrt[3]{k}\right)}^{2} \cdot \sqrt[3]{{\ell}^{-2}}\right)\right)}^{3}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < 7.99999999999999998e-73

    1. Initial program 50.0%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified50.0%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in t around 0 69.8%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot \left(t \cdot {\sin k}^{2}\right)}{{\ell}^{2} \cdot \cos k}}} \]
    5. Step-by-step derivation
      1. associate-*r*69.8%

        \[\leadsto \frac{2}{\frac{\color{blue}{\left({k}^{2} \cdot t\right) \cdot {\sin k}^{2}}}{{\ell}^{2} \cdot \cos k}} \]
      2. times-frac71.4%

        \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]
    6. Simplified71.4%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]

    if 7.99999999999999998e-73 < t < 7.0000000000000001e89

    1. Initial program 74.9%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified75.0%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. associate-*l*72.1%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell \cdot \ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)}} \]
      2. associate-/r*74.8%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell}}{\ell}} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)} \]
      3. associate-+r+74.8%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \color{blue}{\left(\left(1 + 1\right) + {\left(\frac{k}{t}\right)}^{2}\right)}\right)\right)} \]
      4. metadata-eval74.8%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(\color{blue}{2} + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]
      5. associate-*l*74.8%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \color{blue}{\left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}} \]
      6. associate-*l/78.0%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}{\ell}}} \]
    5. Applied egg-rr78.0%

      \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}{\ell}}} \]
    6. Step-by-step derivation
      1. associate-/l*78.0%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell} \cdot \frac{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}{\ell}}} \]
      2. associate-*l*78.0%

        \[\leadsto \frac{2}{\frac{{t}^{3}}{\ell} \cdot \frac{\color{blue}{\sin k \cdot \left(\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}}{\ell}} \]
    7. Simplified78.0%

      \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell} \cdot \frac{\sin k \cdot \left(\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}{\ell}}} \]
    8. Step-by-step derivation
      1. associate-/l*86.4%

        \[\leadsto \frac{2}{\frac{{t}^{3}}{\ell} \cdot \color{blue}{\left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}{\ell}\right)}} \]
    9. Applied egg-rr86.4%

      \[\leadsto \frac{2}{\frac{{t}^{3}}{\ell} \cdot \color{blue}{\left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}{\ell}\right)}} \]

    if 7.0000000000000001e89 < t

    1. Initial program 66.4%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified66.4%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. associate-*l*50.3%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell \cdot \ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)}} \]
      2. associate-/r*53.2%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell}}{\ell}} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)} \]
      3. associate-+r+53.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \color{blue}{\left(\left(1 + 1\right) + {\left(\frac{k}{t}\right)}^{2}\right)}\right)\right)} \]
      4. metadata-eval53.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(\color{blue}{2} + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]
      5. associate-*l*53.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \color{blue}{\left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}} \]
      6. add-cube-cbrt53.2%

        \[\leadsto \frac{2}{\color{blue}{\left(\sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)} \cdot \sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}\right) \cdot \sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}}} \]
      7. pow353.2%

        \[\leadsto \frac{2}{\color{blue}{{\left(\sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}\right)}^{3}}} \]
    5. Applied egg-rr59.7%

      \[\leadsto \frac{2}{\color{blue}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}}} \]
    6. Step-by-step derivation
      1. pow1/359.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{{\left({\ell}^{-2}\right)}^{0.3333333333333333}}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      2. sqr-pow59.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\color{blue}{\left({\ell}^{\left(\frac{-2}{2}\right)} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      3. metadata-eval59.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left({\ell}^{\color{blue}{-1}} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      4. inv-pow59.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\color{blue}{\frac{1}{\ell}} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      5. metadata-eval59.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\frac{1}{\ell} \cdot {\ell}^{\color{blue}{-1}}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      6. inv-pow59.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\frac{1}{\ell} \cdot \color{blue}{\frac{1}{\ell}}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      7. unpow-prod-down39.1%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left({\left(\frac{1}{\ell}\right)}^{0.3333333333333333} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    7. Applied egg-rr39.1%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left({\left(\frac{1}{\ell}\right)}^{0.3333333333333333} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    8. Step-by-step derivation
      1. unpow1/339.2%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\color{blue}{\sqrt[3]{\frac{1}{\ell}}} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      2. unpow1/369.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \color{blue}{\sqrt[3]{\frac{1}{\ell}}}\right)\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    9. Simplified69.6%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    10. Taylor expanded in k around 0 65.0%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \color{blue}{\left(\sqrt[3]{{k}^{2}} \cdot \sqrt[3]{2}\right)}\right)}^{3}} \]
    11. Step-by-step derivation
      1. associate-*r*65.0%

        \[\leadsto \frac{2}{{\color{blue}{\left(\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \sqrt[3]{{k}^{2}}\right) \cdot \sqrt[3]{2}\right)}}^{3}} \]
      2. unpow-prod-down65.0%

        \[\leadsto \frac{2}{\color{blue}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \sqrt[3]{{k}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}}} \]
      3. cbrt-unprod59.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\sqrt[3]{\frac{1}{\ell} \cdot \frac{1}{\ell}}}\right) \cdot \sqrt[3]{{k}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      4. inv-pow59.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{\color{blue}{{\ell}^{-1}} \cdot \frac{1}{\ell}}\right) \cdot \sqrt[3]{{k}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      5. inv-pow59.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-1} \cdot \color{blue}{{\ell}^{-1}}}\right) \cdot \sqrt[3]{{k}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      6. pow-prod-up59.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{\color{blue}{{\ell}^{\left(-1 + -1\right)}}}\right) \cdot \sqrt[3]{{k}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      7. metadata-eval59.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{\color{blue}{-2}}}\right) \cdot \sqrt[3]{{k}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      8. unpow259.6%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot \sqrt[3]{\color{blue}{k \cdot k}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      9. cbrt-prod84.8%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot \color{blue}{\left(\sqrt[3]{k} \cdot \sqrt[3]{k}\right)}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
      10. pow284.8%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot \color{blue}{{\left(\sqrt[3]{k}\right)}^{2}}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}} \]
    12. Applied egg-rr84.8%

      \[\leadsto \frac{2}{\color{blue}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot {\left(\sqrt[3]{k}\right)}^{2}\right)}^{3} \cdot {\left(\sqrt[3]{2}\right)}^{3}}} \]
    13. Step-by-step derivation
      1. rem-cube-cbrt84.8%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot {\left(\sqrt[3]{k}\right)}^{2}\right)}^{3} \cdot \color{blue}{2}} \]
      2. *-commutative84.8%

        \[\leadsto \frac{2}{\color{blue}{2 \cdot {\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot {\left(\sqrt[3]{k}\right)}^{2}\right)}^{3}}} \]
      3. associate-*l*84.9%

        \[\leadsto \frac{2}{2 \cdot {\color{blue}{\left(t \cdot \left(\sqrt[3]{{\ell}^{-2}} \cdot {\left(\sqrt[3]{k}\right)}^{2}\right)\right)}}^{3}} \]
    14. Simplified84.9%

      \[\leadsto \frac{2}{\color{blue}{2 \cdot {\left(t \cdot \left(\sqrt[3]{{\ell}^{-2}} \cdot {\left(\sqrt[3]{k}\right)}^{2}\right)\right)}^{3}}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification75.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq 8 \cdot 10^{-73}:\\ \;\;\;\;\frac{2}{\frac{t \cdot {k}^{2}}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}\\ \mathbf{elif}\;t \leq 7 \cdot 10^{+89}:\\ \;\;\;\;\frac{2}{\frac{{t}^{3}}{\ell} \cdot \left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}{\ell}\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{2 \cdot {\left(t \cdot \left({\left(\sqrt[3]{k}\right)}^{2} \cdot \sqrt[3]{{\ell}^{-2}}\right)\right)}^{3}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 8: 39.3% accurate, 0.8× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ \begin{array}{l} t_2 := \sqrt[3]{\frac{1}{\ell}}\\ t\_s \cdot \begin{array}{l} \mathbf{if}\;k \leq 1.5 \cdot 10^{-17}:\\ \;\;\;\;\frac{2}{{\left(\left(t\_m \cdot \left(t\_2 \cdot t\_2\right)\right) \cdot \left(\sqrt[3]{2} \cdot {k}^{0.6666666666666666}\right)\right)}^{3}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{\frac{\left(t\_m \cdot {k}^{2}\right) \cdot {\sin k}^{2}}{{\ell}^{2} \cdot \cos k}}\\ \end{array} \end{array} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (let* ((t_2 (cbrt (/ 1.0 l))))
   (*
    t_s
    (if (<= k 1.5e-17)
      (/
       2.0
       (pow
        (* (* t_m (* t_2 t_2)) (* (cbrt 2.0) (pow k 0.6666666666666666)))
        3.0))
      (/
       2.0
       (/
        (* (* t_m (pow k 2.0)) (pow (sin k) 2.0))
        (* (pow l 2.0) (cos k))))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	double t_2 = cbrt((1.0 / l));
	double tmp;
	if (k <= 1.5e-17) {
		tmp = 2.0 / pow(((t_m * (t_2 * t_2)) * (cbrt(2.0) * pow(k, 0.6666666666666666))), 3.0);
	} else {
		tmp = 2.0 / (((t_m * pow(k, 2.0)) * pow(sin(k), 2.0)) / (pow(l, 2.0) * cos(k)));
	}
	return t_s * tmp;
}
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	double t_2 = Math.cbrt((1.0 / l));
	double tmp;
	if (k <= 1.5e-17) {
		tmp = 2.0 / Math.pow(((t_m * (t_2 * t_2)) * (Math.cbrt(2.0) * Math.pow(k, 0.6666666666666666))), 3.0);
	} else {
		tmp = 2.0 / (((t_m * Math.pow(k, 2.0)) * Math.pow(Math.sin(k), 2.0)) / (Math.pow(l, 2.0) * Math.cos(k)));
	}
	return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	t_2 = cbrt(Float64(1.0 / l))
	tmp = 0.0
	if (k <= 1.5e-17)
		tmp = Float64(2.0 / (Float64(Float64(t_m * Float64(t_2 * t_2)) * Float64(cbrt(2.0) * (k ^ 0.6666666666666666))) ^ 3.0));
	else
		tmp = Float64(2.0 / Float64(Float64(Float64(t_m * (k ^ 2.0)) * (sin(k) ^ 2.0)) / Float64((l ^ 2.0) * cos(k))));
	end
	return Float64(t_s * tmp)
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := Block[{t$95$2 = N[Power[N[(1.0 / l), $MachinePrecision], 1/3], $MachinePrecision]}, N[(t$95$s * If[LessEqual[k, 1.5e-17], N[(2.0 / N[Power[N[(N[(t$95$m * N[(t$95$2 * t$95$2), $MachinePrecision]), $MachinePrecision] * N[(N[Power[2.0, 1/3], $MachinePrecision] * N[Power[k, 0.6666666666666666], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(N[(t$95$m * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[Power[N[Sin[k], $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] / N[(N[Power[l, 2.0], $MachinePrecision] * N[Cos[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
\begin{array}{l}
t_2 := \sqrt[3]{\frac{1}{\ell}}\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 1.5 \cdot 10^{-17}:\\
\;\;\;\;\frac{2}{{\left(\left(t\_m \cdot \left(t\_2 \cdot t\_2\right)\right) \cdot \left(\sqrt[3]{2} \cdot {k}^{0.6666666666666666}\right)\right)}^{3}}\\

\mathbf{else}:\\
\;\;\;\;\frac{2}{\frac{\left(t\_m \cdot {k}^{2}\right) \cdot {\sin k}^{2}}{{\ell}^{2} \cdot \cos k}}\\


\end{array}
\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if k < 1.50000000000000003e-17

    1. Initial program 57.1%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified57.1%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. associate-*l*52.1%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell \cdot \ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)}} \]
      2. associate-/r*57.0%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell}}{\ell}} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)} \]
      3. associate-+r+57.0%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \color{blue}{\left(\left(1 + 1\right) + {\left(\frac{k}{t}\right)}^{2}\right)}\right)\right)} \]
      4. metadata-eval57.0%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(\color{blue}{2} + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]
      5. associate-*l*57.0%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \color{blue}{\left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}} \]
      6. add-cube-cbrt56.9%

        \[\leadsto \frac{2}{\color{blue}{\left(\sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)} \cdot \sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}\right) \cdot \sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}}} \]
      7. pow356.9%

        \[\leadsto \frac{2}{\color{blue}{{\left(\sqrt[3]{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}\right)}^{3}}} \]
    5. Applied egg-rr64.0%

      \[\leadsto \frac{2}{\color{blue}{{\left(\left(t \cdot \sqrt[3]{{\ell}^{-2}}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}}} \]
    6. Step-by-step derivation
      1. pow1/363.4%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{{\left({\ell}^{-2}\right)}^{0.3333333333333333}}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      2. sqr-pow63.4%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\color{blue}{\left({\ell}^{\left(\frac{-2}{2}\right)} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      3. metadata-eval63.4%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left({\ell}^{\color{blue}{-1}} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      4. inv-pow63.4%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\color{blue}{\frac{1}{\ell}} \cdot {\ell}^{\left(\frac{-2}{2}\right)}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      5. metadata-eval63.4%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\frac{1}{\ell} \cdot {\ell}^{\color{blue}{-1}}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      6. inv-pow63.4%

        \[\leadsto \frac{2}{{\left(\left(t \cdot {\left(\frac{1}{\ell} \cdot \color{blue}{\frac{1}{\ell}}\right)}^{0.3333333333333333}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      7. unpow-prod-down37.3%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left({\left(\frac{1}{\ell}\right)}^{0.3333333333333333} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    7. Applied egg-rr37.3%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left({\left(\frac{1}{\ell}\right)}^{0.3333333333333333} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    8. Step-by-step derivation
      1. unpow1/337.4%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\color{blue}{\sqrt[3]{\frac{1}{\ell}}} \cdot {\left(\frac{1}{\ell}\right)}^{0.3333333333333333}\right)\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
      2. unpow1/373.8%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \color{blue}{\sqrt[3]{\frac{1}{\ell}}}\right)\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    9. Simplified73.8%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \color{blue}{\left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)}\right) \cdot \sqrt[3]{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}\right)}^{3}} \]
    10. Taylor expanded in k around 0 67.4%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \color{blue}{\left(\sqrt[3]{{k}^{2}} \cdot \sqrt[3]{2}\right)}\right)}^{3}} \]
    11. Step-by-step derivation
      1. pow1/366.9%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\color{blue}{{\left({k}^{2}\right)}^{0.3333333333333333}} \cdot \sqrt[3]{2}\right)\right)}^{3}} \]
      2. pow-pow28.8%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\color{blue}{{k}^{\left(2 \cdot 0.3333333333333333\right)}} \cdot \sqrt[3]{2}\right)\right)}^{3}} \]
      3. metadata-eval28.8%

        \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left({k}^{\color{blue}{0.6666666666666666}} \cdot \sqrt[3]{2}\right)\right)}^{3}} \]
    12. Applied egg-rr28.8%

      \[\leadsto \frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\color{blue}{{k}^{0.6666666666666666}} \cdot \sqrt[3]{2}\right)\right)}^{3}} \]

    if 1.50000000000000003e-17 < k

    1. Initial program 51.6%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified51.6%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in t around 0 74.8%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot \left(t \cdot {\sin k}^{2}\right)}{{\ell}^{2} \cdot \cos k}}} \]
    5. Step-by-step derivation
      1. associate-*r*74.8%

        \[\leadsto \frac{2}{\frac{\color{blue}{\left({k}^{2} \cdot t\right) \cdot {\sin k}^{2}}}{{\ell}^{2} \cdot \cos k}} \]
    6. Simplified74.8%

      \[\leadsto \frac{2}{\color{blue}{\frac{\left({k}^{2} \cdot t\right) \cdot {\sin k}^{2}}{{\ell}^{2} \cdot \cos k}}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification40.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;k \leq 1.5 \cdot 10^{-17}:\\ \;\;\;\;\frac{2}{{\left(\left(t \cdot \left(\sqrt[3]{\frac{1}{\ell}} \cdot \sqrt[3]{\frac{1}{\ell}}\right)\right) \cdot \left(\sqrt[3]{2} \cdot {k}^{0.6666666666666666}\right)\right)}^{3}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{\frac{\left(t \cdot {k}^{2}\right) \cdot {\sin k}^{2}}{{\ell}^{2} \cdot \cos k}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 9: 78.1% accurate, 1.0× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ \begin{array}{l} t_2 := {\left(\frac{k}{t\_m}\right)}^{2}\\ t\_s \cdot \begin{array}{l} \mathbf{if}\;t\_m \leq 4.2 \cdot 10^{-138}:\\ \;\;\;\;\frac{2}{{\left(\frac{k \cdot \sin k}{\ell} \cdot \sqrt{\frac{t\_m}{\cos k}}\right)}^{2}}\\ \mathbf{elif}\;t\_m \leq 1.5 \cdot 10^{-92}:\\ \;\;\;\;\frac{2}{\left(\sin k \cdot \left(\frac{{t\_m}^{2}}{\ell} \cdot \frac{t\_m}{\ell}\right)\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + t\_2\right)\right)\right)}\\ \mathbf{elif}\;t\_m \leq 2.4 \cdot 10^{+55}:\\ \;\;\;\;\frac{2}{\frac{{t\_m}^{3}}{\ell} \cdot \left(\sin k \cdot \frac{\tan k \cdot \left(2 + t\_2\right)}{\ell}\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{{\left(\frac{{t\_m}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\ \end{array} \end{array} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (let* ((t_2 (pow (/ k t_m) 2.0)))
   (*
    t_s
    (if (<= t_m 4.2e-138)
      (/ 2.0 (pow (* (/ (* k (sin k)) l) (sqrt (/ t_m (cos k)))) 2.0))
      (if (<= t_m 1.5e-92)
        (/
         2.0
         (*
          (* (sin k) (* (/ (pow t_m 2.0) l) (/ t_m l)))
          (* (tan k) (+ 1.0 (+ 1.0 t_2)))))
        (if (<= t_m 2.4e+55)
          (/
           2.0
           (* (/ (pow t_m 3.0) l) (* (sin k) (/ (* (tan k) (+ 2.0 t_2)) l))))
          (/ 2.0 (pow (* (/ (pow t_m 1.5) l) (* k (sqrt 2.0))) 2.0))))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	double t_2 = pow((k / t_m), 2.0);
	double tmp;
	if (t_m <= 4.2e-138) {
		tmp = 2.0 / pow((((k * sin(k)) / l) * sqrt((t_m / cos(k)))), 2.0);
	} else if (t_m <= 1.5e-92) {
		tmp = 2.0 / ((sin(k) * ((pow(t_m, 2.0) / l) * (t_m / l))) * (tan(k) * (1.0 + (1.0 + t_2))));
	} else if (t_m <= 2.4e+55) {
		tmp = 2.0 / ((pow(t_m, 3.0) / l) * (sin(k) * ((tan(k) * (2.0 + t_2)) / l)));
	} else {
		tmp = 2.0 / pow(((pow(t_m, 1.5) / l) * (k * sqrt(2.0))), 2.0);
	}
	return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
    real(8), intent (in) :: t_s
    real(8), intent (in) :: t_m
    real(8), intent (in) :: l
    real(8), intent (in) :: k
    real(8) :: t_2
    real(8) :: tmp
    t_2 = (k / t_m) ** 2.0d0
    if (t_m <= 4.2d-138) then
        tmp = 2.0d0 / ((((k * sin(k)) / l) * sqrt((t_m / cos(k)))) ** 2.0d0)
    else if (t_m <= 1.5d-92) then
        tmp = 2.0d0 / ((sin(k) * (((t_m ** 2.0d0) / l) * (t_m / l))) * (tan(k) * (1.0d0 + (1.0d0 + t_2))))
    else if (t_m <= 2.4d+55) then
        tmp = 2.0d0 / (((t_m ** 3.0d0) / l) * (sin(k) * ((tan(k) * (2.0d0 + t_2)) / l)))
    else
        tmp = 2.0d0 / ((((t_m ** 1.5d0) / l) * (k * sqrt(2.0d0))) ** 2.0d0)
    end if
    code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	double t_2 = Math.pow((k / t_m), 2.0);
	double tmp;
	if (t_m <= 4.2e-138) {
		tmp = 2.0 / Math.pow((((k * Math.sin(k)) / l) * Math.sqrt((t_m / Math.cos(k)))), 2.0);
	} else if (t_m <= 1.5e-92) {
		tmp = 2.0 / ((Math.sin(k) * ((Math.pow(t_m, 2.0) / l) * (t_m / l))) * (Math.tan(k) * (1.0 + (1.0 + t_2))));
	} else if (t_m <= 2.4e+55) {
		tmp = 2.0 / ((Math.pow(t_m, 3.0) / l) * (Math.sin(k) * ((Math.tan(k) * (2.0 + t_2)) / l)));
	} else {
		tmp = 2.0 / Math.pow(((Math.pow(t_m, 1.5) / l) * (k * Math.sqrt(2.0))), 2.0);
	}
	return t_s * tmp;
}
t\_m = math.fabs(t)
t\_s = math.copysign(1.0, t)
def code(t_s, t_m, l, k):
	t_2 = math.pow((k / t_m), 2.0)
	tmp = 0
	if t_m <= 4.2e-138:
		tmp = 2.0 / math.pow((((k * math.sin(k)) / l) * math.sqrt((t_m / math.cos(k)))), 2.0)
	elif t_m <= 1.5e-92:
		tmp = 2.0 / ((math.sin(k) * ((math.pow(t_m, 2.0) / l) * (t_m / l))) * (math.tan(k) * (1.0 + (1.0 + t_2))))
	elif t_m <= 2.4e+55:
		tmp = 2.0 / ((math.pow(t_m, 3.0) / l) * (math.sin(k) * ((math.tan(k) * (2.0 + t_2)) / l)))
	else:
		tmp = 2.0 / math.pow(((math.pow(t_m, 1.5) / l) * (k * math.sqrt(2.0))), 2.0)
	return t_s * tmp
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	t_2 = Float64(k / t_m) ^ 2.0
	tmp = 0.0
	if (t_m <= 4.2e-138)
		tmp = Float64(2.0 / (Float64(Float64(Float64(k * sin(k)) / l) * sqrt(Float64(t_m / cos(k)))) ^ 2.0));
	elseif (t_m <= 1.5e-92)
		tmp = Float64(2.0 / Float64(Float64(sin(k) * Float64(Float64((t_m ^ 2.0) / l) * Float64(t_m / l))) * Float64(tan(k) * Float64(1.0 + Float64(1.0 + t_2)))));
	elseif (t_m <= 2.4e+55)
		tmp = Float64(2.0 / Float64(Float64((t_m ^ 3.0) / l) * Float64(sin(k) * Float64(Float64(tan(k) * Float64(2.0 + t_2)) / l))));
	else
		tmp = Float64(2.0 / (Float64(Float64((t_m ^ 1.5) / l) * Float64(k * sqrt(2.0))) ^ 2.0));
	end
	return Float64(t_s * tmp)
end
t\_m = abs(t);
t\_s = sign(t) * abs(1.0);
function tmp_2 = code(t_s, t_m, l, k)
	t_2 = (k / t_m) ^ 2.0;
	tmp = 0.0;
	if (t_m <= 4.2e-138)
		tmp = 2.0 / ((((k * sin(k)) / l) * sqrt((t_m / cos(k)))) ^ 2.0);
	elseif (t_m <= 1.5e-92)
		tmp = 2.0 / ((sin(k) * (((t_m ^ 2.0) / l) * (t_m / l))) * (tan(k) * (1.0 + (1.0 + t_2))));
	elseif (t_m <= 2.4e+55)
		tmp = 2.0 / (((t_m ^ 3.0) / l) * (sin(k) * ((tan(k) * (2.0 + t_2)) / l)));
	else
		tmp = 2.0 / ((((t_m ^ 1.5) / l) * (k * sqrt(2.0))) ^ 2.0);
	end
	tmp_2 = t_s * tmp;
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := Block[{t$95$2 = N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]}, N[(t$95$s * If[LessEqual[t$95$m, 4.2e-138], N[(2.0 / N[Power[N[(N[(N[(k * N[Sin[k], $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision] * N[Sqrt[N[(t$95$m / N[Cos[k], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 1.5e-92], N[(2.0 / N[(N[(N[Sin[k], $MachinePrecision] * N[(N[(N[Power[t$95$m, 2.0], $MachinePrecision] / l), $MachinePrecision] * N[(t$95$m / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[Tan[k], $MachinePrecision] * N[(1.0 + N[(1.0 + t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 2.4e+55], N[(2.0 / N[(N[(N[Power[t$95$m, 3.0], $MachinePrecision] / l), $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[(N[(N[Tan[k], $MachinePrecision] * N[(2.0 + t$95$2), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[Power[N[(N[(N[Power[t$95$m, 1.5], $MachinePrecision] / l), $MachinePrecision] * N[(k * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]]]]), $MachinePrecision]]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
\begin{array}{l}
t_2 := {\left(\frac{k}{t\_m}\right)}^{2}\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 4.2 \cdot 10^{-138}:\\
\;\;\;\;\frac{2}{{\left(\frac{k \cdot \sin k}{\ell} \cdot \sqrt{\frac{t\_m}{\cos k}}\right)}^{2}}\\

\mathbf{elif}\;t\_m \leq 1.5 \cdot 10^{-92}:\\
\;\;\;\;\frac{2}{\left(\sin k \cdot \left(\frac{{t\_m}^{2}}{\ell} \cdot \frac{t\_m}{\ell}\right)\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + t\_2\right)\right)\right)}\\

\mathbf{elif}\;t\_m \leq 2.4 \cdot 10^{+55}:\\
\;\;\;\;\frac{2}{\frac{{t\_m}^{3}}{\ell} \cdot \left(\sin k \cdot \frac{\tan k \cdot \left(2 + t\_2\right)}{\ell}\right)}\\

\mathbf{else}:\\
\;\;\;\;\frac{2}{{\left(\frac{{t\_m}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\


\end{array}
\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < 4.19999999999999972e-138

    1. Initial program 48.7%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified48.7%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Applied egg-rr10.7%

      \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)\right)}^{2}}} \]
    5. Taylor expanded in t around 0 29.2%

      \[\leadsto \frac{2}{{\color{blue}{\left(\frac{k \cdot \sin k}{\ell} \cdot \sqrt{\frac{t}{\cos k}}\right)}}^{2}} \]

    if 4.19999999999999972e-138 < t < 1.50000000000000007e-92

    1. Initial program 38.9%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified38.9%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. unpow338.9%

        \[\leadsto \frac{2}{\left(\frac{\color{blue}{\left(t \cdot t\right) \cdot t}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]
      2. times-frac74.8%

        \[\leadsto \frac{2}{\left(\color{blue}{\left(\frac{t \cdot t}{\ell} \cdot \frac{t}{\ell}\right)} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]
      3. pow274.8%

        \[\leadsto \frac{2}{\left(\left(\frac{\color{blue}{{t}^{2}}}{\ell} \cdot \frac{t}{\ell}\right) \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]
    5. Applied egg-rr74.8%

      \[\leadsto \frac{2}{\left(\color{blue}{\left(\frac{{t}^{2}}{\ell} \cdot \frac{t}{\ell}\right)} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]

    if 1.50000000000000007e-92 < t < 2.3999999999999999e55

    1. Initial program 81.2%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified81.2%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. associate-*l*78.7%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell \cdot \ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)}} \]
      2. associate-/r*81.2%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell}}{\ell}} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)} \]
      3. associate-+r+81.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \color{blue}{\left(\left(1 + 1\right) + {\left(\frac{k}{t}\right)}^{2}\right)}\right)\right)} \]
      4. metadata-eval81.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(\color{blue}{2} + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]
      5. associate-*l*81.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \color{blue}{\left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}} \]
      6. associate-*l/84.2%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}{\ell}}} \]
    5. Applied egg-rr84.2%

      \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}{\ell}}} \]
    6. Step-by-step derivation
      1. associate-/l*84.2%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell} \cdot \frac{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}{\ell}}} \]
      2. associate-*l*84.1%

        \[\leadsto \frac{2}{\frac{{t}^{3}}{\ell} \cdot \frac{\color{blue}{\sin k \cdot \left(\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}}{\ell}} \]
    7. Simplified84.1%

      \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell} \cdot \frac{\sin k \cdot \left(\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}{\ell}}} \]
    8. Step-by-step derivation
      1. associate-/l*91.8%

        \[\leadsto \frac{2}{\frac{{t}^{3}}{\ell} \cdot \color{blue}{\left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}{\ell}\right)}} \]
    9. Applied egg-rr91.8%

      \[\leadsto \frac{2}{\frac{{t}^{3}}{\ell} \cdot \color{blue}{\left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}{\ell}\right)}} \]

    if 2.3999999999999999e55 < t

    1. Initial program 64.3%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified64.4%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Applied egg-rr59.0%

      \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)\right)}^{2}}} \]
    5. Taylor expanded in k around 0 78.3%

      \[\leadsto \frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \color{blue}{\left(k \cdot \sqrt{2}\right)}\right)}^{2}} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification47.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq 4.2 \cdot 10^{-138}:\\ \;\;\;\;\frac{2}{{\left(\frac{k \cdot \sin k}{\ell} \cdot \sqrt{\frac{t}{\cos k}}\right)}^{2}}\\ \mathbf{elif}\;t \leq 1.5 \cdot 10^{-92}:\\ \;\;\;\;\frac{2}{\left(\sin k \cdot \left(\frac{{t}^{2}}{\ell} \cdot \frac{t}{\ell}\right)\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}\\ \mathbf{elif}\;t \leq 2.4 \cdot 10^{+55}:\\ \;\;\;\;\frac{2}{\frac{{t}^{3}}{\ell} \cdot \left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}{\ell}\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 10: 77.9% accurate, 1.0× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ t\_s \cdot \begin{array}{l} \mathbf{if}\;t\_m \leq 1.6 \cdot 10^{-92}:\\ \;\;\;\;\frac{2}{{\left(\frac{k \cdot \sin k}{\ell} \cdot \sqrt{\frac{t\_m}{\cos k}}\right)}^{2}}\\ \mathbf{elif}\;t\_m \leq 3.5 \cdot 10^{+57}:\\ \;\;\;\;\frac{2}{\frac{{t\_m}^{3}}{\ell} \cdot \left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t\_m}\right)}^{2}\right)}{\ell}\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{{\left(\frac{{t\_m}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\ \end{array} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (*
  t_s
  (if (<= t_m 1.6e-92)
    (/ 2.0 (pow (* (/ (* k (sin k)) l) (sqrt (/ t_m (cos k)))) 2.0))
    (if (<= t_m 3.5e+57)
      (/
       2.0
       (*
        (/ (pow t_m 3.0) l)
        (* (sin k) (/ (* (tan k) (+ 2.0 (pow (/ k t_m) 2.0))) l))))
      (/ 2.0 (pow (* (/ (pow t_m 1.5) l) (* k (sqrt 2.0))) 2.0))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (t_m <= 1.6e-92) {
		tmp = 2.0 / pow((((k * sin(k)) / l) * sqrt((t_m / cos(k)))), 2.0);
	} else if (t_m <= 3.5e+57) {
		tmp = 2.0 / ((pow(t_m, 3.0) / l) * (sin(k) * ((tan(k) * (2.0 + pow((k / t_m), 2.0))) / l)));
	} else {
		tmp = 2.0 / pow(((pow(t_m, 1.5) / l) * (k * sqrt(2.0))), 2.0);
	}
	return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
    real(8), intent (in) :: t_s
    real(8), intent (in) :: t_m
    real(8), intent (in) :: l
    real(8), intent (in) :: k
    real(8) :: tmp
    if (t_m <= 1.6d-92) then
        tmp = 2.0d0 / ((((k * sin(k)) / l) * sqrt((t_m / cos(k)))) ** 2.0d0)
    else if (t_m <= 3.5d+57) then
        tmp = 2.0d0 / (((t_m ** 3.0d0) / l) * (sin(k) * ((tan(k) * (2.0d0 + ((k / t_m) ** 2.0d0))) / l)))
    else
        tmp = 2.0d0 / ((((t_m ** 1.5d0) / l) * (k * sqrt(2.0d0))) ** 2.0d0)
    end if
    code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (t_m <= 1.6e-92) {
		tmp = 2.0 / Math.pow((((k * Math.sin(k)) / l) * Math.sqrt((t_m / Math.cos(k)))), 2.0);
	} else if (t_m <= 3.5e+57) {
		tmp = 2.0 / ((Math.pow(t_m, 3.0) / l) * (Math.sin(k) * ((Math.tan(k) * (2.0 + Math.pow((k / t_m), 2.0))) / l)));
	} else {
		tmp = 2.0 / Math.pow(((Math.pow(t_m, 1.5) / l) * (k * Math.sqrt(2.0))), 2.0);
	}
	return t_s * tmp;
}
t\_m = math.fabs(t)
t\_s = math.copysign(1.0, t)
def code(t_s, t_m, l, k):
	tmp = 0
	if t_m <= 1.6e-92:
		tmp = 2.0 / math.pow((((k * math.sin(k)) / l) * math.sqrt((t_m / math.cos(k)))), 2.0)
	elif t_m <= 3.5e+57:
		tmp = 2.0 / ((math.pow(t_m, 3.0) / l) * (math.sin(k) * ((math.tan(k) * (2.0 + math.pow((k / t_m), 2.0))) / l)))
	else:
		tmp = 2.0 / math.pow(((math.pow(t_m, 1.5) / l) * (k * math.sqrt(2.0))), 2.0)
	return t_s * tmp
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	tmp = 0.0
	if (t_m <= 1.6e-92)
		tmp = Float64(2.0 / (Float64(Float64(Float64(k * sin(k)) / l) * sqrt(Float64(t_m / cos(k)))) ^ 2.0));
	elseif (t_m <= 3.5e+57)
		tmp = Float64(2.0 / Float64(Float64((t_m ^ 3.0) / l) * Float64(sin(k) * Float64(Float64(tan(k) * Float64(2.0 + (Float64(k / t_m) ^ 2.0))) / l))));
	else
		tmp = Float64(2.0 / (Float64(Float64((t_m ^ 1.5) / l) * Float64(k * sqrt(2.0))) ^ 2.0));
	end
	return Float64(t_s * tmp)
end
t\_m = abs(t);
t\_s = sign(t) * abs(1.0);
function tmp_2 = code(t_s, t_m, l, k)
	tmp = 0.0;
	if (t_m <= 1.6e-92)
		tmp = 2.0 / ((((k * sin(k)) / l) * sqrt((t_m / cos(k)))) ^ 2.0);
	elseif (t_m <= 3.5e+57)
		tmp = 2.0 / (((t_m ^ 3.0) / l) * (sin(k) * ((tan(k) * (2.0 + ((k / t_m) ^ 2.0))) / l)));
	else
		tmp = 2.0 / ((((t_m ^ 1.5) / l) * (k * sqrt(2.0))) ^ 2.0);
	end
	tmp_2 = t_s * tmp;
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[t$95$m, 1.6e-92], N[(2.0 / N[Power[N[(N[(N[(k * N[Sin[k], $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision] * N[Sqrt[N[(t$95$m / N[Cos[k], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 3.5e+57], N[(2.0 / N[(N[(N[Power[t$95$m, 3.0], $MachinePrecision] / l), $MachinePrecision] * N[(N[Sin[k], $MachinePrecision] * N[(N[(N[Tan[k], $MachinePrecision] * N[(2.0 + N[Power[N[(k / t$95$m), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[Power[N[(N[(N[Power[t$95$m, 1.5], $MachinePrecision] / l), $MachinePrecision] * N[(k * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 1.6 \cdot 10^{-92}:\\
\;\;\;\;\frac{2}{{\left(\frac{k \cdot \sin k}{\ell} \cdot \sqrt{\frac{t\_m}{\cos k}}\right)}^{2}}\\

\mathbf{elif}\;t\_m \leq 3.5 \cdot 10^{+57}:\\
\;\;\;\;\frac{2}{\frac{{t\_m}^{3}}{\ell} \cdot \left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t\_m}\right)}^{2}\right)}{\ell}\right)}\\

\mathbf{else}:\\
\;\;\;\;\frac{2}{{\left(\frac{{t\_m}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < 1.5999999999999998e-92

    1. Initial program 48.3%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified48.3%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Applied egg-rr12.5%

      \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)\right)}^{2}}} \]
    5. Taylor expanded in t around 0 30.7%

      \[\leadsto \frac{2}{{\color{blue}{\left(\frac{k \cdot \sin k}{\ell} \cdot \sqrt{\frac{t}{\cos k}}\right)}}^{2}} \]

    if 1.5999999999999998e-92 < t < 3.4999999999999997e57

    1. Initial program 81.2%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified81.2%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. associate-*l*78.7%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell \cdot \ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)}} \]
      2. associate-/r*81.2%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell}}{\ell}} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)\right)} \]
      3. associate-+r+81.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \color{blue}{\left(\left(1 + 1\right) + {\left(\frac{k}{t}\right)}^{2}\right)}\right)\right)} \]
      4. metadata-eval81.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\sin k \cdot \left(\tan k \cdot \left(\color{blue}{2} + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)} \]
      5. associate-*l*81.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \color{blue}{\left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}} \]
      6. associate-*l/84.2%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}{\ell}}} \]
    5. Applied egg-rr84.2%

      \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}{\ell}}} \]
    6. Step-by-step derivation
      1. associate-/l*84.2%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell} \cdot \frac{\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}{\ell}}} \]
      2. associate-*l*84.1%

        \[\leadsto \frac{2}{\frac{{t}^{3}}{\ell} \cdot \frac{\color{blue}{\sin k \cdot \left(\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}}{\ell}} \]
    7. Simplified84.1%

      \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell} \cdot \frac{\sin k \cdot \left(\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}{\ell}}} \]
    8. Step-by-step derivation
      1. associate-/l*91.8%

        \[\leadsto \frac{2}{\frac{{t}^{3}}{\ell} \cdot \color{blue}{\left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}{\ell}\right)}} \]
    9. Applied egg-rr91.8%

      \[\leadsto \frac{2}{\frac{{t}^{3}}{\ell} \cdot \color{blue}{\left(\sin k \cdot \frac{\tan k \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)}{\ell}\right)}} \]

    if 3.4999999999999997e57 < t

    1. Initial program 64.3%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified64.4%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Applied egg-rr59.0%

      \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)\right)}^{2}}} \]
    5. Taylor expanded in k around 0 78.3%

      \[\leadsto \frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \color{blue}{\left(k \cdot \sqrt{2}\right)}\right)}^{2}} \]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 11: 69.9% accurate, 1.0× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ t\_s \cdot \begin{array}{l} \mathbf{if}\;k \leq 1.15 \cdot 10^{-19}:\\ \;\;\;\;\frac{2}{{\left(\frac{{t\_m}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{\frac{t\_m \cdot {k}^{2}}{{\ell}^{2}} \cdot \frac{{k}^{2}}{\cos k}}\\ \end{array} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (*
  t_s
  (if (<= k 1.15e-19)
    (/ 2.0 (pow (* (/ (pow t_m 1.5) l) (* k (sqrt 2.0))) 2.0))
    (/ 2.0 (* (/ (* t_m (pow k 2.0)) (pow l 2.0)) (/ (pow k 2.0) (cos k)))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (k <= 1.15e-19) {
		tmp = 2.0 / pow(((pow(t_m, 1.5) / l) * (k * sqrt(2.0))), 2.0);
	} else {
		tmp = 2.0 / (((t_m * pow(k, 2.0)) / pow(l, 2.0)) * (pow(k, 2.0) / cos(k)));
	}
	return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
    real(8), intent (in) :: t_s
    real(8), intent (in) :: t_m
    real(8), intent (in) :: l
    real(8), intent (in) :: k
    real(8) :: tmp
    if (k <= 1.15d-19) then
        tmp = 2.0d0 / ((((t_m ** 1.5d0) / l) * (k * sqrt(2.0d0))) ** 2.0d0)
    else
        tmp = 2.0d0 / (((t_m * (k ** 2.0d0)) / (l ** 2.0d0)) * ((k ** 2.0d0) / cos(k)))
    end if
    code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (k <= 1.15e-19) {
		tmp = 2.0 / Math.pow(((Math.pow(t_m, 1.5) / l) * (k * Math.sqrt(2.0))), 2.0);
	} else {
		tmp = 2.0 / (((t_m * Math.pow(k, 2.0)) / Math.pow(l, 2.0)) * (Math.pow(k, 2.0) / Math.cos(k)));
	}
	return t_s * tmp;
}
t\_m = math.fabs(t)
t\_s = math.copysign(1.0, t)
def code(t_s, t_m, l, k):
	tmp = 0
	if k <= 1.15e-19:
		tmp = 2.0 / math.pow(((math.pow(t_m, 1.5) / l) * (k * math.sqrt(2.0))), 2.0)
	else:
		tmp = 2.0 / (((t_m * math.pow(k, 2.0)) / math.pow(l, 2.0)) * (math.pow(k, 2.0) / math.cos(k)))
	return t_s * tmp
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	tmp = 0.0
	if (k <= 1.15e-19)
		tmp = Float64(2.0 / (Float64(Float64((t_m ^ 1.5) / l) * Float64(k * sqrt(2.0))) ^ 2.0));
	else
		tmp = Float64(2.0 / Float64(Float64(Float64(t_m * (k ^ 2.0)) / (l ^ 2.0)) * Float64((k ^ 2.0) / cos(k))));
	end
	return Float64(t_s * tmp)
end
t\_m = abs(t);
t\_s = sign(t) * abs(1.0);
function tmp_2 = code(t_s, t_m, l, k)
	tmp = 0.0;
	if (k <= 1.15e-19)
		tmp = 2.0 / ((((t_m ^ 1.5) / l) * (k * sqrt(2.0))) ^ 2.0);
	else
		tmp = 2.0 / (((t_m * (k ^ 2.0)) / (l ^ 2.0)) * ((k ^ 2.0) / cos(k)));
	end
	tmp_2 = t_s * tmp;
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[k, 1.15e-19], N[(2.0 / N[Power[N[(N[(N[Power[t$95$m, 1.5], $MachinePrecision] / l), $MachinePrecision] * N[(k * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(N[(t$95$m * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] / N[Power[l, 2.0], $MachinePrecision]), $MachinePrecision] * N[(N[Power[k, 2.0], $MachinePrecision] / N[Cos[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 1.15 \cdot 10^{-19}:\\
\;\;\;\;\frac{2}{{\left(\frac{{t\_m}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\

\mathbf{else}:\\
\;\;\;\;\frac{2}{\frac{t\_m \cdot {k}^{2}}{{\ell}^{2}} \cdot \frac{{k}^{2}}{\cos k}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if k < 1.1499999999999999e-19

    1. Initial program 57.1%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified57.1%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Applied egg-rr29.0%

      \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)\right)}^{2}}} \]
    5. Taylor expanded in k around 0 33.0%

      \[\leadsto \frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \color{blue}{\left(k \cdot \sqrt{2}\right)}\right)}^{2}} \]

    if 1.1499999999999999e-19 < k

    1. Initial program 51.6%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified51.6%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in t around 0 74.8%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot \left(t \cdot {\sin k}^{2}\right)}{{\ell}^{2} \cdot \cos k}}} \]
    5. Step-by-step derivation
      1. associate-*r*74.8%

        \[\leadsto \frac{2}{\frac{\color{blue}{\left({k}^{2} \cdot t\right) \cdot {\sin k}^{2}}}{{\ell}^{2} \cdot \cos k}} \]
      2. times-frac74.8%

        \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]
    6. Simplified74.8%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]
    7. Taylor expanded in k around 0 64.5%

      \[\leadsto \frac{2}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\color{blue}{k}}^{2}}{\cos k}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification40.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;k \leq 1.15 \cdot 10^{-19}:\\ \;\;\;\;\frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{\frac{t \cdot {k}^{2}}{{\ell}^{2}} \cdot \frac{{k}^{2}}{\cos k}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 12: 75.1% accurate, 1.0× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ t\_s \cdot \begin{array}{l} \mathbf{if}\;t\_m \leq 1.8 \cdot 10^{-137}:\\ \;\;\;\;\frac{2}{{\left(\frac{k \cdot \sin k}{\ell} \cdot \sqrt{\frac{t\_m}{\cos k}}\right)}^{2}}\\ \mathbf{elif}\;t\_m \leq 1.25 \cdot 10^{-75}:\\ \;\;\;\;\frac{2}{\frac{t\_m \cdot \frac{{t\_m}^{2}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \frac{k}{t\_m \cdot \frac{t\_m}{k}}\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{{\left(\frac{{t\_m}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\ \end{array} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (*
  t_s
  (if (<= t_m 1.8e-137)
    (/ 2.0 (pow (* (/ (* k (sin k)) l) (sqrt (/ t_m (cos k)))) 2.0))
    (if (<= t_m 1.25e-75)
      (/
       2.0
       (*
        (/ (* t_m (/ (pow t_m 2.0) l)) l)
        (* (* (sin k) (tan k)) (+ 2.0 (/ k (* t_m (/ t_m k)))))))
      (/ 2.0 (pow (* (/ (pow t_m 1.5) l) (* k (sqrt 2.0))) 2.0))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (t_m <= 1.8e-137) {
		tmp = 2.0 / pow((((k * sin(k)) / l) * sqrt((t_m / cos(k)))), 2.0);
	} else if (t_m <= 1.25e-75) {
		tmp = 2.0 / (((t_m * (pow(t_m, 2.0) / l)) / l) * ((sin(k) * tan(k)) * (2.0 + (k / (t_m * (t_m / k))))));
	} else {
		tmp = 2.0 / pow(((pow(t_m, 1.5) / l) * (k * sqrt(2.0))), 2.0);
	}
	return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
    real(8), intent (in) :: t_s
    real(8), intent (in) :: t_m
    real(8), intent (in) :: l
    real(8), intent (in) :: k
    real(8) :: tmp
    if (t_m <= 1.8d-137) then
        tmp = 2.0d0 / ((((k * sin(k)) / l) * sqrt((t_m / cos(k)))) ** 2.0d0)
    else if (t_m <= 1.25d-75) then
        tmp = 2.0d0 / (((t_m * ((t_m ** 2.0d0) / l)) / l) * ((sin(k) * tan(k)) * (2.0d0 + (k / (t_m * (t_m / k))))))
    else
        tmp = 2.0d0 / ((((t_m ** 1.5d0) / l) * (k * sqrt(2.0d0))) ** 2.0d0)
    end if
    code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (t_m <= 1.8e-137) {
		tmp = 2.0 / Math.pow((((k * Math.sin(k)) / l) * Math.sqrt((t_m / Math.cos(k)))), 2.0);
	} else if (t_m <= 1.25e-75) {
		tmp = 2.0 / (((t_m * (Math.pow(t_m, 2.0) / l)) / l) * ((Math.sin(k) * Math.tan(k)) * (2.0 + (k / (t_m * (t_m / k))))));
	} else {
		tmp = 2.0 / Math.pow(((Math.pow(t_m, 1.5) / l) * (k * Math.sqrt(2.0))), 2.0);
	}
	return t_s * tmp;
}
t\_m = math.fabs(t)
t\_s = math.copysign(1.0, t)
def code(t_s, t_m, l, k):
	tmp = 0
	if t_m <= 1.8e-137:
		tmp = 2.0 / math.pow((((k * math.sin(k)) / l) * math.sqrt((t_m / math.cos(k)))), 2.0)
	elif t_m <= 1.25e-75:
		tmp = 2.0 / (((t_m * (math.pow(t_m, 2.0) / l)) / l) * ((math.sin(k) * math.tan(k)) * (2.0 + (k / (t_m * (t_m / k))))))
	else:
		tmp = 2.0 / math.pow(((math.pow(t_m, 1.5) / l) * (k * math.sqrt(2.0))), 2.0)
	return t_s * tmp
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	tmp = 0.0
	if (t_m <= 1.8e-137)
		tmp = Float64(2.0 / (Float64(Float64(Float64(k * sin(k)) / l) * sqrt(Float64(t_m / cos(k)))) ^ 2.0));
	elseif (t_m <= 1.25e-75)
		tmp = Float64(2.0 / Float64(Float64(Float64(t_m * Float64((t_m ^ 2.0) / l)) / l) * Float64(Float64(sin(k) * tan(k)) * Float64(2.0 + Float64(k / Float64(t_m * Float64(t_m / k)))))));
	else
		tmp = Float64(2.0 / (Float64(Float64((t_m ^ 1.5) / l) * Float64(k * sqrt(2.0))) ^ 2.0));
	end
	return Float64(t_s * tmp)
end
t\_m = abs(t);
t\_s = sign(t) * abs(1.0);
function tmp_2 = code(t_s, t_m, l, k)
	tmp = 0.0;
	if (t_m <= 1.8e-137)
		tmp = 2.0 / ((((k * sin(k)) / l) * sqrt((t_m / cos(k)))) ^ 2.0);
	elseif (t_m <= 1.25e-75)
		tmp = 2.0 / (((t_m * ((t_m ^ 2.0) / l)) / l) * ((sin(k) * tan(k)) * (2.0 + (k / (t_m * (t_m / k))))));
	else
		tmp = 2.0 / ((((t_m ^ 1.5) / l) * (k * sqrt(2.0))) ^ 2.0);
	end
	tmp_2 = t_s * tmp;
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[t$95$m, 1.8e-137], N[(2.0 / N[Power[N[(N[(N[(k * N[Sin[k], $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision] * N[Sqrt[N[(t$95$m / N[Cos[k], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 1.25e-75], N[(2.0 / N[(N[(N[(t$95$m * N[(N[Power[t$95$m, 2.0], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision] * N[(N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision] * N[(2.0 + N[(k / N[(t$95$m * N[(t$95$m / k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[Power[N[(N[(N[Power[t$95$m, 1.5], $MachinePrecision] / l), $MachinePrecision] * N[(k * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 1.8 \cdot 10^{-137}:\\
\;\;\;\;\frac{2}{{\left(\frac{k \cdot \sin k}{\ell} \cdot \sqrt{\frac{t\_m}{\cos k}}\right)}^{2}}\\

\mathbf{elif}\;t\_m \leq 1.25 \cdot 10^{-75}:\\
\;\;\;\;\frac{2}{\frac{t\_m \cdot \frac{{t\_m}^{2}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \frac{k}{t\_m \cdot \frac{t\_m}{k}}\right)\right)}\\

\mathbf{else}:\\
\;\;\;\;\frac{2}{{\left(\frac{{t\_m}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < 1.80000000000000003e-137

    1. Initial program 48.7%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified48.7%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Applied egg-rr10.7%

      \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)\right)}^{2}}} \]
    5. Taylor expanded in t around 0 29.2%

      \[\leadsto \frac{2}{{\color{blue}{\left(\frac{k \cdot \sin k}{\ell} \cdot \sqrt{\frac{t}{\cos k}}\right)}}^{2}} \]

    if 1.80000000000000003e-137 < t < 1.24999999999999995e-75

    1. Initial program 67.4%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified73.3%

      \[\leadsto \color{blue}{\frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. unpow273.3%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \color{blue}{\frac{k}{t} \cdot \frac{k}{t}}\right)\right)} \]
      2. clear-num73.3%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \color{blue}{\frac{1}{\frac{t}{k}}} \cdot \frac{k}{t}\right)\right)} \]
      3. frac-times73.3%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \color{blue}{\frac{1 \cdot k}{\frac{t}{k} \cdot t}}\right)\right)} \]
      4. *-un-lft-identity73.3%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \frac{\color{blue}{k}}{\frac{t}{k} \cdot t}\right)\right)} \]
    5. Applied egg-rr73.3%

      \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \color{blue}{\frac{k}{\frac{t}{k} \cdot t}}\right)\right)} \]
    6. Step-by-step derivation
      1. cube-mult73.3%

        \[\leadsto \frac{2}{\frac{\frac{\color{blue}{t \cdot \left(t \cdot t\right)}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \frac{k}{\frac{t}{k} \cdot t}\right)\right)} \]
      2. *-un-lft-identity73.3%

        \[\leadsto \frac{2}{\frac{\frac{t \cdot \left(t \cdot t\right)}{\color{blue}{1 \cdot \ell}}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \frac{k}{\frac{t}{k} \cdot t}\right)\right)} \]
      3. times-frac86.5%

        \[\leadsto \frac{2}{\frac{\color{blue}{\frac{t}{1} \cdot \frac{t \cdot t}{\ell}}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \frac{k}{\frac{t}{k} \cdot t}\right)\right)} \]
      4. pow286.5%

        \[\leadsto \frac{2}{\frac{\frac{t}{1} \cdot \frac{\color{blue}{{t}^{2}}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \frac{k}{\frac{t}{k} \cdot t}\right)\right)} \]
    7. Applied egg-rr86.5%

      \[\leadsto \frac{2}{\frac{\color{blue}{\frac{t}{1} \cdot \frac{{t}^{2}}{\ell}}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \frac{k}{\frac{t}{k} \cdot t}\right)\right)} \]

    if 1.24999999999999995e-75 < t

    1. Initial program 69.5%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified69.5%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Applied egg-rr60.8%

      \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)\right)}^{2}}} \]
    5. Taylor expanded in k around 0 77.9%

      \[\leadsto \frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \color{blue}{\left(k \cdot \sqrt{2}\right)}\right)}^{2}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification46.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq 1.8 \cdot 10^{-137}:\\ \;\;\;\;\frac{2}{{\left(\frac{k \cdot \sin k}{\ell} \cdot \sqrt{\frac{t}{\cos k}}\right)}^{2}}\\ \mathbf{elif}\;t \leq 1.25 \cdot 10^{-75}:\\ \;\;\;\;\frac{2}{\frac{t \cdot \frac{{t}^{2}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \frac{k}{t \cdot \frac{t}{k}}\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 13: 74.8% accurate, 1.0× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ t\_s \cdot \begin{array}{l} \mathbf{if}\;t\_m \leq 1.6 \cdot 10^{-89}:\\ \;\;\;\;\frac{2}{{\left(\sqrt{\frac{t\_m}{\cos k}} \cdot \left(k \cdot \frac{\sin k}{\ell}\right)\right)}^{2}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{{\left(\frac{{t\_m}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\ \end{array} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (*
  t_s
  (if (<= t_m 1.6e-89)
    (/ 2.0 (pow (* (sqrt (/ t_m (cos k))) (* k (/ (sin k) l))) 2.0))
    (/ 2.0 (pow (* (/ (pow t_m 1.5) l) (* k (sqrt 2.0))) 2.0)))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (t_m <= 1.6e-89) {
		tmp = 2.0 / pow((sqrt((t_m / cos(k))) * (k * (sin(k) / l))), 2.0);
	} else {
		tmp = 2.0 / pow(((pow(t_m, 1.5) / l) * (k * sqrt(2.0))), 2.0);
	}
	return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
    real(8), intent (in) :: t_s
    real(8), intent (in) :: t_m
    real(8), intent (in) :: l
    real(8), intent (in) :: k
    real(8) :: tmp
    if (t_m <= 1.6d-89) then
        tmp = 2.0d0 / ((sqrt((t_m / cos(k))) * (k * (sin(k) / l))) ** 2.0d0)
    else
        tmp = 2.0d0 / ((((t_m ** 1.5d0) / l) * (k * sqrt(2.0d0))) ** 2.0d0)
    end if
    code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (t_m <= 1.6e-89) {
		tmp = 2.0 / Math.pow((Math.sqrt((t_m / Math.cos(k))) * (k * (Math.sin(k) / l))), 2.0);
	} else {
		tmp = 2.0 / Math.pow(((Math.pow(t_m, 1.5) / l) * (k * Math.sqrt(2.0))), 2.0);
	}
	return t_s * tmp;
}
t\_m = math.fabs(t)
t\_s = math.copysign(1.0, t)
def code(t_s, t_m, l, k):
	tmp = 0
	if t_m <= 1.6e-89:
		tmp = 2.0 / math.pow((math.sqrt((t_m / math.cos(k))) * (k * (math.sin(k) / l))), 2.0)
	else:
		tmp = 2.0 / math.pow(((math.pow(t_m, 1.5) / l) * (k * math.sqrt(2.0))), 2.0)
	return t_s * tmp
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	tmp = 0.0
	if (t_m <= 1.6e-89)
		tmp = Float64(2.0 / (Float64(sqrt(Float64(t_m / cos(k))) * Float64(k * Float64(sin(k) / l))) ^ 2.0));
	else
		tmp = Float64(2.0 / (Float64(Float64((t_m ^ 1.5) / l) * Float64(k * sqrt(2.0))) ^ 2.0));
	end
	return Float64(t_s * tmp)
end
t\_m = abs(t);
t\_s = sign(t) * abs(1.0);
function tmp_2 = code(t_s, t_m, l, k)
	tmp = 0.0;
	if (t_m <= 1.6e-89)
		tmp = 2.0 / ((sqrt((t_m / cos(k))) * (k * (sin(k) / l))) ^ 2.0);
	else
		tmp = 2.0 / ((((t_m ^ 1.5) / l) * (k * sqrt(2.0))) ^ 2.0);
	end
	tmp_2 = t_s * tmp;
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[t$95$m, 1.6e-89], N[(2.0 / N[Power[N[(N[Sqrt[N[(t$95$m / N[Cos[k], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[(k * N[(N[Sin[k], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], N[(2.0 / N[Power[N[(N[(N[Power[t$95$m, 1.5], $MachinePrecision] / l), $MachinePrecision] * N[(k * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 1.6 \cdot 10^{-89}:\\
\;\;\;\;\frac{2}{{\left(\sqrt{\frac{t\_m}{\cos k}} \cdot \left(k \cdot \frac{\sin k}{\ell}\right)\right)}^{2}}\\

\mathbf{else}:\\
\;\;\;\;\frac{2}{{\left(\frac{{t\_m}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < 1.59999999999999999e-89

    1. Initial program 48.8%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified48.8%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Applied egg-rr13.5%

      \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)\right)}^{2}}} \]
    5. Taylor expanded in t around 0 31.4%

      \[\leadsto \frac{2}{{\color{blue}{\left(\frac{k \cdot \sin k}{\ell} \cdot \sqrt{\frac{t}{\cos k}}\right)}}^{2}} \]
    6. Step-by-step derivation
      1. associate-/l*31.4%

        \[\leadsto \frac{2}{{\left(\color{blue}{\left(k \cdot \frac{\sin k}{\ell}\right)} \cdot \sqrt{\frac{t}{\cos k}}\right)}^{2}} \]
    7. Simplified31.4%

      \[\leadsto \frac{2}{{\color{blue}{\left(\left(k \cdot \frac{\sin k}{\ell}\right) \cdot \sqrt{\frac{t}{\cos k}}\right)}}^{2}} \]

    if 1.59999999999999999e-89 < t

    1. Initial program 71.4%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified71.4%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Applied egg-rr62.1%

      \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)\right)}^{2}}} \]
    5. Taylor expanded in k around 0 78.2%

      \[\leadsto \frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \color{blue}{\left(k \cdot \sqrt{2}\right)}\right)}^{2}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification45.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq 1.6 \cdot 10^{-89}:\\ \;\;\;\;\frac{2}{{\left(\sqrt{\frac{t}{\cos k}} \cdot \left(k \cdot \frac{\sin k}{\ell}\right)\right)}^{2}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 14: 70.4% accurate, 1.3× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ t\_s \cdot \begin{array}{l} \mathbf{if}\;k \leq 3.2 \cdot 10^{-18}:\\ \;\;\;\;\frac{2}{{\left(\frac{{t\_m}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\ \mathbf{elif}\;k \leq 3 \cdot 10^{+123}:\\ \;\;\;\;\frac{2}{\frac{t\_m \cdot \frac{{t\_m}^{2}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \frac{k}{t\_m \cdot \frac{t\_m}{k}}\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{{\ell}^{-2} \cdot \left(t\_m \cdot {k}^{4}\right)}\\ \end{array} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (*
  t_s
  (if (<= k 3.2e-18)
    (/ 2.0 (pow (* (/ (pow t_m 1.5) l) (* k (sqrt 2.0))) 2.0))
    (if (<= k 3e+123)
      (/
       2.0
       (*
        (/ (* t_m (/ (pow t_m 2.0) l)) l)
        (* (* (sin k) (tan k)) (+ 2.0 (/ k (* t_m (/ t_m k)))))))
      (/ 2.0 (* (pow l -2.0) (* t_m (pow k 4.0))))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (k <= 3.2e-18) {
		tmp = 2.0 / pow(((pow(t_m, 1.5) / l) * (k * sqrt(2.0))), 2.0);
	} else if (k <= 3e+123) {
		tmp = 2.0 / (((t_m * (pow(t_m, 2.0) / l)) / l) * ((sin(k) * tan(k)) * (2.0 + (k / (t_m * (t_m / k))))));
	} else {
		tmp = 2.0 / (pow(l, -2.0) * (t_m * pow(k, 4.0)));
	}
	return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
    real(8), intent (in) :: t_s
    real(8), intent (in) :: t_m
    real(8), intent (in) :: l
    real(8), intent (in) :: k
    real(8) :: tmp
    if (k <= 3.2d-18) then
        tmp = 2.0d0 / ((((t_m ** 1.5d0) / l) * (k * sqrt(2.0d0))) ** 2.0d0)
    else if (k <= 3d+123) then
        tmp = 2.0d0 / (((t_m * ((t_m ** 2.0d0) / l)) / l) * ((sin(k) * tan(k)) * (2.0d0 + (k / (t_m * (t_m / k))))))
    else
        tmp = 2.0d0 / ((l ** (-2.0d0)) * (t_m * (k ** 4.0d0)))
    end if
    code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (k <= 3.2e-18) {
		tmp = 2.0 / Math.pow(((Math.pow(t_m, 1.5) / l) * (k * Math.sqrt(2.0))), 2.0);
	} else if (k <= 3e+123) {
		tmp = 2.0 / (((t_m * (Math.pow(t_m, 2.0) / l)) / l) * ((Math.sin(k) * Math.tan(k)) * (2.0 + (k / (t_m * (t_m / k))))));
	} else {
		tmp = 2.0 / (Math.pow(l, -2.0) * (t_m * Math.pow(k, 4.0)));
	}
	return t_s * tmp;
}
t\_m = math.fabs(t)
t\_s = math.copysign(1.0, t)
def code(t_s, t_m, l, k):
	tmp = 0
	if k <= 3.2e-18:
		tmp = 2.0 / math.pow(((math.pow(t_m, 1.5) / l) * (k * math.sqrt(2.0))), 2.0)
	elif k <= 3e+123:
		tmp = 2.0 / (((t_m * (math.pow(t_m, 2.0) / l)) / l) * ((math.sin(k) * math.tan(k)) * (2.0 + (k / (t_m * (t_m / k))))))
	else:
		tmp = 2.0 / (math.pow(l, -2.0) * (t_m * math.pow(k, 4.0)))
	return t_s * tmp
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	tmp = 0.0
	if (k <= 3.2e-18)
		tmp = Float64(2.0 / (Float64(Float64((t_m ^ 1.5) / l) * Float64(k * sqrt(2.0))) ^ 2.0));
	elseif (k <= 3e+123)
		tmp = Float64(2.0 / Float64(Float64(Float64(t_m * Float64((t_m ^ 2.0) / l)) / l) * Float64(Float64(sin(k) * tan(k)) * Float64(2.0 + Float64(k / Float64(t_m * Float64(t_m / k)))))));
	else
		tmp = Float64(2.0 / Float64((l ^ -2.0) * Float64(t_m * (k ^ 4.0))));
	end
	return Float64(t_s * tmp)
end
t\_m = abs(t);
t\_s = sign(t) * abs(1.0);
function tmp_2 = code(t_s, t_m, l, k)
	tmp = 0.0;
	if (k <= 3.2e-18)
		tmp = 2.0 / ((((t_m ^ 1.5) / l) * (k * sqrt(2.0))) ^ 2.0);
	elseif (k <= 3e+123)
		tmp = 2.0 / (((t_m * ((t_m ^ 2.0) / l)) / l) * ((sin(k) * tan(k)) * (2.0 + (k / (t_m * (t_m / k))))));
	else
		tmp = 2.0 / ((l ^ -2.0) * (t_m * (k ^ 4.0)));
	end
	tmp_2 = t_s * tmp;
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[k, 3.2e-18], N[(2.0 / N[Power[N[(N[(N[Power[t$95$m, 1.5], $MachinePrecision] / l), $MachinePrecision] * N[(k * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 3e+123], N[(2.0 / N[(N[(N[(t$95$m * N[(N[Power[t$95$m, 2.0], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision] * N[(N[(N[Sin[k], $MachinePrecision] * N[Tan[k], $MachinePrecision]), $MachinePrecision] * N[(2.0 + N[(k / N[(t$95$m * N[(t$95$m / k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[Power[l, -2.0], $MachinePrecision] * N[(t$95$m * N[Power[k, 4.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 3.2 \cdot 10^{-18}:\\
\;\;\;\;\frac{2}{{\left(\frac{{t\_m}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\

\mathbf{elif}\;k \leq 3 \cdot 10^{+123}:\\
\;\;\;\;\frac{2}{\frac{t\_m \cdot \frac{{t\_m}^{2}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \frac{k}{t\_m \cdot \frac{t\_m}{k}}\right)\right)}\\

\mathbf{else}:\\
\;\;\;\;\frac{2}{{\ell}^{-2} \cdot \left(t\_m \cdot {k}^{4}\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if k < 3.1999999999999999e-18

    1. Initial program 57.1%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified57.1%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Applied egg-rr29.0%

      \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)\right)}^{2}}} \]
    5. Taylor expanded in k around 0 33.0%

      \[\leadsto \frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \color{blue}{\left(k \cdot \sqrt{2}\right)}\right)}^{2}} \]

    if 3.1999999999999999e-18 < k < 3.00000000000000008e123

    1. Initial program 51.7%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified58.2%

      \[\leadsto \color{blue}{\frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. unpow258.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \color{blue}{\frac{k}{t} \cdot \frac{k}{t}}\right)\right)} \]
      2. clear-num58.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \color{blue}{\frac{1}{\frac{t}{k}}} \cdot \frac{k}{t}\right)\right)} \]
      3. frac-times58.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \color{blue}{\frac{1 \cdot k}{\frac{t}{k} \cdot t}}\right)\right)} \]
      4. *-un-lft-identity58.2%

        \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \frac{\color{blue}{k}}{\frac{t}{k} \cdot t}\right)\right)} \]
    5. Applied egg-rr58.2%

      \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \color{blue}{\frac{k}{\frac{t}{k} \cdot t}}\right)\right)} \]
    6. Step-by-step derivation
      1. cube-mult58.2%

        \[\leadsto \frac{2}{\frac{\frac{\color{blue}{t \cdot \left(t \cdot t\right)}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \frac{k}{\frac{t}{k} \cdot t}\right)\right)} \]
      2. *-un-lft-identity58.2%

        \[\leadsto \frac{2}{\frac{\frac{t \cdot \left(t \cdot t\right)}{\color{blue}{1 \cdot \ell}}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \frac{k}{\frac{t}{k} \cdot t}\right)\right)} \]
      3. times-frac58.2%

        \[\leadsto \frac{2}{\frac{\color{blue}{\frac{t}{1} \cdot \frac{t \cdot t}{\ell}}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \frac{k}{\frac{t}{k} \cdot t}\right)\right)} \]
      4. pow258.2%

        \[\leadsto \frac{2}{\frac{\frac{t}{1} \cdot \frac{\color{blue}{{t}^{2}}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \frac{k}{\frac{t}{k} \cdot t}\right)\right)} \]
    7. Applied egg-rr58.2%

      \[\leadsto \frac{2}{\frac{\color{blue}{\frac{t}{1} \cdot \frac{{t}^{2}}{\ell}}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \frac{k}{\frac{t}{k} \cdot t}\right)\right)} \]

    if 3.00000000000000008e123 < k

    1. Initial program 51.5%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified51.5%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in t around 0 76.1%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot \left(t \cdot {\sin k}^{2}\right)}{{\ell}^{2} \cdot \cos k}}} \]
    5. Step-by-step derivation
      1. associate-*r*76.1%

        \[\leadsto \frac{2}{\frac{\color{blue}{\left({k}^{2} \cdot t\right) \cdot {\sin k}^{2}}}{{\ell}^{2} \cdot \cos k}} \]
      2. times-frac76.0%

        \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]
    6. Simplified76.0%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]
    7. Taylor expanded in k around 0 67.3%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{4} \cdot t}{{\ell}^{2}}}} \]
    8. Step-by-step derivation
      1. associate-/l*67.1%

        \[\leadsto \frac{2}{\color{blue}{{k}^{4} \cdot \frac{t}{{\ell}^{2}}}} \]
    9. Simplified67.1%

      \[\leadsto \frac{2}{\color{blue}{{k}^{4} \cdot \frac{t}{{\ell}^{2}}}} \]
    10. Step-by-step derivation
      1. pow167.1%

        \[\leadsto \frac{2}{\color{blue}{{\left({k}^{4} \cdot \frac{t}{{\ell}^{2}}\right)}^{1}}} \]
      2. div-inv67.1%

        \[\leadsto \frac{2}{{\left({k}^{4} \cdot \color{blue}{\left(t \cdot \frac{1}{{\ell}^{2}}\right)}\right)}^{1}} \]
      3. pow-flip67.1%

        \[\leadsto \frac{2}{{\left({k}^{4} \cdot \left(t \cdot \color{blue}{{\ell}^{\left(-2\right)}}\right)\right)}^{1}} \]
      4. metadata-eval67.1%

        \[\leadsto \frac{2}{{\left({k}^{4} \cdot \left(t \cdot {\ell}^{\color{blue}{-2}}\right)\right)}^{1}} \]
    11. Applied egg-rr67.1%

      \[\leadsto \frac{2}{\color{blue}{{\left({k}^{4} \cdot \left(t \cdot {\ell}^{-2}\right)\right)}^{1}}} \]
    12. Step-by-step derivation
      1. unpow167.1%

        \[\leadsto \frac{2}{\color{blue}{{k}^{4} \cdot \left(t \cdot {\ell}^{-2}\right)}} \]
      2. associate-*r*67.3%

        \[\leadsto \frac{2}{\color{blue}{\left({k}^{4} \cdot t\right) \cdot {\ell}^{-2}}} \]
      3. *-commutative67.3%

        \[\leadsto \frac{2}{\color{blue}{\left(t \cdot {k}^{4}\right)} \cdot {\ell}^{-2}} \]
    13. Simplified67.3%

      \[\leadsto \frac{2}{\color{blue}{\left(t \cdot {k}^{4}\right) \cdot {\ell}^{-2}}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification40.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;k \leq 3.2 \cdot 10^{-18}:\\ \;\;\;\;\frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\ \mathbf{elif}\;k \leq 3 \cdot 10^{+123}:\\ \;\;\;\;\frac{2}{\frac{t \cdot \frac{{t}^{2}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + \frac{k}{t \cdot \frac{t}{k}}\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{{\ell}^{-2} \cdot \left(t \cdot {k}^{4}\right)}\\ \end{array} \]
  5. Add Preprocessing

Alternative 15: 68.6% accurate, 1.3× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ t\_s \cdot \begin{array}{l} \mathbf{if}\;k \leq 3.7 \cdot 10^{-17}:\\ \;\;\;\;\frac{2}{{\left(\frac{{t\_m}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{{\ell}^{-2} \cdot \left(t\_m \cdot {k}^{4}\right)}\\ \end{array} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (*
  t_s
  (if (<= k 3.7e-17)
    (/ 2.0 (pow (* (/ (pow t_m 1.5) l) (* k (sqrt 2.0))) 2.0))
    (/ 2.0 (* (pow l -2.0) (* t_m (pow k 4.0)))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (k <= 3.7e-17) {
		tmp = 2.0 / pow(((pow(t_m, 1.5) / l) * (k * sqrt(2.0))), 2.0);
	} else {
		tmp = 2.0 / (pow(l, -2.0) * (t_m * pow(k, 4.0)));
	}
	return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
    real(8), intent (in) :: t_s
    real(8), intent (in) :: t_m
    real(8), intent (in) :: l
    real(8), intent (in) :: k
    real(8) :: tmp
    if (k <= 3.7d-17) then
        tmp = 2.0d0 / ((((t_m ** 1.5d0) / l) * (k * sqrt(2.0d0))) ** 2.0d0)
    else
        tmp = 2.0d0 / ((l ** (-2.0d0)) * (t_m * (k ** 4.0d0)))
    end if
    code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (k <= 3.7e-17) {
		tmp = 2.0 / Math.pow(((Math.pow(t_m, 1.5) / l) * (k * Math.sqrt(2.0))), 2.0);
	} else {
		tmp = 2.0 / (Math.pow(l, -2.0) * (t_m * Math.pow(k, 4.0)));
	}
	return t_s * tmp;
}
t\_m = math.fabs(t)
t\_s = math.copysign(1.0, t)
def code(t_s, t_m, l, k):
	tmp = 0
	if k <= 3.7e-17:
		tmp = 2.0 / math.pow(((math.pow(t_m, 1.5) / l) * (k * math.sqrt(2.0))), 2.0)
	else:
		tmp = 2.0 / (math.pow(l, -2.0) * (t_m * math.pow(k, 4.0)))
	return t_s * tmp
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	tmp = 0.0
	if (k <= 3.7e-17)
		tmp = Float64(2.0 / (Float64(Float64((t_m ^ 1.5) / l) * Float64(k * sqrt(2.0))) ^ 2.0));
	else
		tmp = Float64(2.0 / Float64((l ^ -2.0) * Float64(t_m * (k ^ 4.0))));
	end
	return Float64(t_s * tmp)
end
t\_m = abs(t);
t\_s = sign(t) * abs(1.0);
function tmp_2 = code(t_s, t_m, l, k)
	tmp = 0.0;
	if (k <= 3.7e-17)
		tmp = 2.0 / ((((t_m ^ 1.5) / l) * (k * sqrt(2.0))) ^ 2.0);
	else
		tmp = 2.0 / ((l ^ -2.0) * (t_m * (k ^ 4.0)));
	end
	tmp_2 = t_s * tmp;
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[k, 3.7e-17], N[(2.0 / N[Power[N[(N[(N[Power[t$95$m, 1.5], $MachinePrecision] / l), $MachinePrecision] * N[(k * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[Power[l, -2.0], $MachinePrecision] * N[(t$95$m * N[Power[k, 4.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 3.7 \cdot 10^{-17}:\\
\;\;\;\;\frac{2}{{\left(\frac{{t\_m}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\

\mathbf{else}:\\
\;\;\;\;\frac{2}{{\ell}^{-2} \cdot \left(t\_m \cdot {k}^{4}\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if k < 3.6999999999999997e-17

    1. Initial program 57.1%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified57.1%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Applied egg-rr29.0%

      \[\leadsto \frac{2}{\color{blue}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(\mathsf{hypot}\left(1, \mathsf{hypot}\left(1, \frac{k}{t}\right)\right) \cdot \sqrt{\sin k \cdot \tan k}\right)\right)}^{2}}} \]
    5. Taylor expanded in k around 0 33.0%

      \[\leadsto \frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \color{blue}{\left(k \cdot \sqrt{2}\right)}\right)}^{2}} \]

    if 3.6999999999999997e-17 < k

    1. Initial program 51.6%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified51.6%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in t around 0 74.8%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot \left(t \cdot {\sin k}^{2}\right)}{{\ell}^{2} \cdot \cos k}}} \]
    5. Step-by-step derivation
      1. associate-*r*74.8%

        \[\leadsto \frac{2}{\frac{\color{blue}{\left({k}^{2} \cdot t\right) \cdot {\sin k}^{2}}}{{\ell}^{2} \cdot \cos k}} \]
      2. times-frac74.8%

        \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]
    6. Simplified74.8%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]
    7. Taylor expanded in k around 0 57.9%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{4} \cdot t}{{\ell}^{2}}}} \]
    8. Step-by-step derivation
      1. associate-/l*57.8%

        \[\leadsto \frac{2}{\color{blue}{{k}^{4} \cdot \frac{t}{{\ell}^{2}}}} \]
    9. Simplified57.8%

      \[\leadsto \frac{2}{\color{blue}{{k}^{4} \cdot \frac{t}{{\ell}^{2}}}} \]
    10. Step-by-step derivation
      1. pow157.8%

        \[\leadsto \frac{2}{\color{blue}{{\left({k}^{4} \cdot \frac{t}{{\ell}^{2}}\right)}^{1}}} \]
      2. div-inv57.8%

        \[\leadsto \frac{2}{{\left({k}^{4} \cdot \color{blue}{\left(t \cdot \frac{1}{{\ell}^{2}}\right)}\right)}^{1}} \]
      3. pow-flip57.8%

        \[\leadsto \frac{2}{{\left({k}^{4} \cdot \left(t \cdot \color{blue}{{\ell}^{\left(-2\right)}}\right)\right)}^{1}} \]
      4. metadata-eval57.8%

        \[\leadsto \frac{2}{{\left({k}^{4} \cdot \left(t \cdot {\ell}^{\color{blue}{-2}}\right)\right)}^{1}} \]
    11. Applied egg-rr57.8%

      \[\leadsto \frac{2}{\color{blue}{{\left({k}^{4} \cdot \left(t \cdot {\ell}^{-2}\right)\right)}^{1}}} \]
    12. Step-by-step derivation
      1. unpow157.8%

        \[\leadsto \frac{2}{\color{blue}{{k}^{4} \cdot \left(t \cdot {\ell}^{-2}\right)}} \]
      2. associate-*r*57.9%

        \[\leadsto \frac{2}{\color{blue}{\left({k}^{4} \cdot t\right) \cdot {\ell}^{-2}}} \]
      3. *-commutative57.9%

        \[\leadsto \frac{2}{\color{blue}{\left(t \cdot {k}^{4}\right)} \cdot {\ell}^{-2}} \]
    13. Simplified57.9%

      \[\leadsto \frac{2}{\color{blue}{\left(t \cdot {k}^{4}\right) \cdot {\ell}^{-2}}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification39.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;k \leq 3.7 \cdot 10^{-17}:\\ \;\;\;\;\frac{2}{{\left(\frac{{t}^{1.5}}{\ell} \cdot \left(k \cdot \sqrt{2}\right)\right)}^{2}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{{\ell}^{-2} \cdot \left(t \cdot {k}^{4}\right)}\\ \end{array} \]
  5. Add Preprocessing

Alternative 16: 60.9% accurate, 1.9× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ t\_s \cdot \begin{array}{l} \mathbf{if}\;t\_m \leq 5 \cdot 10^{-76}:\\ \;\;\;\;\frac{2 \cdot {\ell}^{2}}{t\_m \cdot {k}^{4}}\\ \mathbf{elif}\;t\_m \leq 1.65 \cdot 10^{+101}:\\ \;\;\;\;\frac{2}{\frac{{t\_m}^{3} \cdot \left(2 \cdot \frac{{k}^{2}}{\ell}\right)}{\ell}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{\left(\sin k \cdot \frac{{t\_m}^{3}}{\ell \cdot \ell}\right) \cdot \left(2 \cdot k\right)}\\ \end{array} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (*
  t_s
  (if (<= t_m 5e-76)
    (/ (* 2.0 (pow l 2.0)) (* t_m (pow k 4.0)))
    (if (<= t_m 1.65e+101)
      (/ 2.0 (/ (* (pow t_m 3.0) (* 2.0 (/ (pow k 2.0) l))) l))
      (/ 2.0 (* (* (sin k) (/ (pow t_m 3.0) (* l l))) (* 2.0 k)))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (t_m <= 5e-76) {
		tmp = (2.0 * pow(l, 2.0)) / (t_m * pow(k, 4.0));
	} else if (t_m <= 1.65e+101) {
		tmp = 2.0 / ((pow(t_m, 3.0) * (2.0 * (pow(k, 2.0) / l))) / l);
	} else {
		tmp = 2.0 / ((sin(k) * (pow(t_m, 3.0) / (l * l))) * (2.0 * k));
	}
	return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
    real(8), intent (in) :: t_s
    real(8), intent (in) :: t_m
    real(8), intent (in) :: l
    real(8), intent (in) :: k
    real(8) :: tmp
    if (t_m <= 5d-76) then
        tmp = (2.0d0 * (l ** 2.0d0)) / (t_m * (k ** 4.0d0))
    else if (t_m <= 1.65d+101) then
        tmp = 2.0d0 / (((t_m ** 3.0d0) * (2.0d0 * ((k ** 2.0d0) / l))) / l)
    else
        tmp = 2.0d0 / ((sin(k) * ((t_m ** 3.0d0) / (l * l))) * (2.0d0 * k))
    end if
    code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (t_m <= 5e-76) {
		tmp = (2.0 * Math.pow(l, 2.0)) / (t_m * Math.pow(k, 4.0));
	} else if (t_m <= 1.65e+101) {
		tmp = 2.0 / ((Math.pow(t_m, 3.0) * (2.0 * (Math.pow(k, 2.0) / l))) / l);
	} else {
		tmp = 2.0 / ((Math.sin(k) * (Math.pow(t_m, 3.0) / (l * l))) * (2.0 * k));
	}
	return t_s * tmp;
}
t\_m = math.fabs(t)
t\_s = math.copysign(1.0, t)
def code(t_s, t_m, l, k):
	tmp = 0
	if t_m <= 5e-76:
		tmp = (2.0 * math.pow(l, 2.0)) / (t_m * math.pow(k, 4.0))
	elif t_m <= 1.65e+101:
		tmp = 2.0 / ((math.pow(t_m, 3.0) * (2.0 * (math.pow(k, 2.0) / l))) / l)
	else:
		tmp = 2.0 / ((math.sin(k) * (math.pow(t_m, 3.0) / (l * l))) * (2.0 * k))
	return t_s * tmp
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	tmp = 0.0
	if (t_m <= 5e-76)
		tmp = Float64(Float64(2.0 * (l ^ 2.0)) / Float64(t_m * (k ^ 4.0)));
	elseif (t_m <= 1.65e+101)
		tmp = Float64(2.0 / Float64(Float64((t_m ^ 3.0) * Float64(2.0 * Float64((k ^ 2.0) / l))) / l));
	else
		tmp = Float64(2.0 / Float64(Float64(sin(k) * Float64((t_m ^ 3.0) / Float64(l * l))) * Float64(2.0 * k)));
	end
	return Float64(t_s * tmp)
end
t\_m = abs(t);
t\_s = sign(t) * abs(1.0);
function tmp_2 = code(t_s, t_m, l, k)
	tmp = 0.0;
	if (t_m <= 5e-76)
		tmp = (2.0 * (l ^ 2.0)) / (t_m * (k ^ 4.0));
	elseif (t_m <= 1.65e+101)
		tmp = 2.0 / (((t_m ^ 3.0) * (2.0 * ((k ^ 2.0) / l))) / l);
	else
		tmp = 2.0 / ((sin(k) * ((t_m ^ 3.0) / (l * l))) * (2.0 * k));
	end
	tmp_2 = t_s * tmp;
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[t$95$m, 5e-76], N[(N[(2.0 * N[Power[l, 2.0], $MachinePrecision]), $MachinePrecision] / N[(t$95$m * N[Power[k, 4.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$m, 1.65e+101], N[(2.0 / N[(N[(N[Power[t$95$m, 3.0], $MachinePrecision] * N[(2.0 * N[(N[Power[k, 2.0], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(N[Sin[k], $MachinePrecision] * N[(N[Power[t$95$m, 3.0], $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(2.0 * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_m \leq 5 \cdot 10^{-76}:\\
\;\;\;\;\frac{2 \cdot {\ell}^{2}}{t\_m \cdot {k}^{4}}\\

\mathbf{elif}\;t\_m \leq 1.65 \cdot 10^{+101}:\\
\;\;\;\;\frac{2}{\frac{{t\_m}^{3} \cdot \left(2 \cdot \frac{{k}^{2}}{\ell}\right)}{\ell}}\\

\mathbf{else}:\\
\;\;\;\;\frac{2}{\left(\sin k \cdot \frac{{t\_m}^{3}}{\ell \cdot \ell}\right) \cdot \left(2 \cdot k\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < 4.9999999999999998e-76

    1. Initial program 50.2%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified50.2%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in t around 0 70.2%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot \left(t \cdot {\sin k}^{2}\right)}{{\ell}^{2} \cdot \cos k}}} \]
    5. Step-by-step derivation
      1. associate-*r*70.2%

        \[\leadsto \frac{2}{\frac{\color{blue}{\left({k}^{2} \cdot t\right) \cdot {\sin k}^{2}}}{{\ell}^{2} \cdot \cos k}} \]
      2. times-frac71.7%

        \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]
    6. Simplified71.7%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]
    7. Taylor expanded in k around 0 59.9%

      \[\leadsto \color{blue}{2 \cdot \frac{{\ell}^{2}}{{k}^{4} \cdot t}} \]
    8. Step-by-step derivation
      1. associate-*r/59.9%

        \[\leadsto \color{blue}{\frac{2 \cdot {\ell}^{2}}{{k}^{4} \cdot t}} \]
      2. *-commutative59.9%

        \[\leadsto \frac{2 \cdot {\ell}^{2}}{\color{blue}{t \cdot {k}^{4}}} \]
    9. Simplified59.9%

      \[\leadsto \color{blue}{\frac{2 \cdot {\ell}^{2}}{t \cdot {k}^{4}}} \]

    if 4.9999999999999998e-76 < t < 1.65000000000000006e101

    1. Initial program 71.7%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified71.6%

      \[\leadsto \color{blue}{\frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in k around 0 59.1%

      \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \color{blue}{\left(2 \cdot {k}^{2}\right)}} \]
    5. Step-by-step derivation
      1. associate-*l/59.6%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell} \cdot \left(2 \cdot {k}^{2}\right)}{\ell}}} \]
    6. Applied egg-rr59.6%

      \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell} \cdot \left(2 \cdot {k}^{2}\right)}{\ell}}} \]
    7. Step-by-step derivation
      1. associate-/l*62.0%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell} \cdot \frac{2 \cdot {k}^{2}}{\ell}}} \]
    8. Simplified62.0%

      \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell} \cdot \frac{2 \cdot {k}^{2}}{\ell}}} \]
    9. Step-by-step derivation
      1. associate-*l/66.1%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3} \cdot \frac{2 \cdot {k}^{2}}{\ell}}{\ell}}} \]
      2. associate-/l*66.1%

        \[\leadsto \frac{2}{\frac{{t}^{3} \cdot \color{blue}{\left(2 \cdot \frac{{k}^{2}}{\ell}\right)}}{\ell}} \]
    10. Applied egg-rr66.1%

      \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3} \cdot \left(2 \cdot \frac{{k}^{2}}{\ell}\right)}{\ell}}} \]

    if 1.65000000000000006e101 < t

    1. Initial program 67.1%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified67.1%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in k around 0 67.1%

      \[\leadsto \frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \color{blue}{\left(2 \cdot k\right)}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification61.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq 5 \cdot 10^{-76}:\\ \;\;\;\;\frac{2 \cdot {\ell}^{2}}{t \cdot {k}^{4}}\\ \mathbf{elif}\;t \leq 1.65 \cdot 10^{+101}:\\ \;\;\;\;\frac{2}{\frac{{t}^{3} \cdot \left(2 \cdot \frac{{k}^{2}}{\ell}\right)}{\ell}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{\left(\sin k \cdot \frac{{t}^{3}}{\ell \cdot \ell}\right) \cdot \left(2 \cdot k\right)}\\ \end{array} \]
  5. Add Preprocessing

Alternative 17: 57.4% accurate, 1.9× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ t\_s \cdot \begin{array}{l} \mathbf{if}\;k \leq 1.22 \cdot 10^{-24}:\\ \;\;\;\;\frac{2}{\frac{{t\_m}^{3} \cdot \left(2 \cdot \frac{{k}^{2}}{\ell}\right)}{\ell}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{{\ell}^{-2} \cdot \left(t\_m \cdot {k}^{4}\right)}\\ \end{array} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (*
  t_s
  (if (<= k 1.22e-24)
    (/ 2.0 (/ (* (pow t_m 3.0) (* 2.0 (/ (pow k 2.0) l))) l))
    (/ 2.0 (* (pow l -2.0) (* t_m (pow k 4.0)))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (k <= 1.22e-24) {
		tmp = 2.0 / ((pow(t_m, 3.0) * (2.0 * (pow(k, 2.0) / l))) / l);
	} else {
		tmp = 2.0 / (pow(l, -2.0) * (t_m * pow(k, 4.0)));
	}
	return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
    real(8), intent (in) :: t_s
    real(8), intent (in) :: t_m
    real(8), intent (in) :: l
    real(8), intent (in) :: k
    real(8) :: tmp
    if (k <= 1.22d-24) then
        tmp = 2.0d0 / (((t_m ** 3.0d0) * (2.0d0 * ((k ** 2.0d0) / l))) / l)
    else
        tmp = 2.0d0 / ((l ** (-2.0d0)) * (t_m * (k ** 4.0d0)))
    end if
    code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (k <= 1.22e-24) {
		tmp = 2.0 / ((Math.pow(t_m, 3.0) * (2.0 * (Math.pow(k, 2.0) / l))) / l);
	} else {
		tmp = 2.0 / (Math.pow(l, -2.0) * (t_m * Math.pow(k, 4.0)));
	}
	return t_s * tmp;
}
t\_m = math.fabs(t)
t\_s = math.copysign(1.0, t)
def code(t_s, t_m, l, k):
	tmp = 0
	if k <= 1.22e-24:
		tmp = 2.0 / ((math.pow(t_m, 3.0) * (2.0 * (math.pow(k, 2.0) / l))) / l)
	else:
		tmp = 2.0 / (math.pow(l, -2.0) * (t_m * math.pow(k, 4.0)))
	return t_s * tmp
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	tmp = 0.0
	if (k <= 1.22e-24)
		tmp = Float64(2.0 / Float64(Float64((t_m ^ 3.0) * Float64(2.0 * Float64((k ^ 2.0) / l))) / l));
	else
		tmp = Float64(2.0 / Float64((l ^ -2.0) * Float64(t_m * (k ^ 4.0))));
	end
	return Float64(t_s * tmp)
end
t\_m = abs(t);
t\_s = sign(t) * abs(1.0);
function tmp_2 = code(t_s, t_m, l, k)
	tmp = 0.0;
	if (k <= 1.22e-24)
		tmp = 2.0 / (((t_m ^ 3.0) * (2.0 * ((k ^ 2.0) / l))) / l);
	else
		tmp = 2.0 / ((l ^ -2.0) * (t_m * (k ^ 4.0)));
	end
	tmp_2 = t_s * tmp;
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[k, 1.22e-24], N[(2.0 / N[(N[(N[Power[t$95$m, 3.0], $MachinePrecision] * N[(2.0 * N[(N[Power[k, 2.0], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[Power[l, -2.0], $MachinePrecision] * N[(t$95$m * N[Power[k, 4.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 1.22 \cdot 10^{-24}:\\
\;\;\;\;\frac{2}{\frac{{t\_m}^{3} \cdot \left(2 \cdot \frac{{k}^{2}}{\ell}\right)}{\ell}}\\

\mathbf{else}:\\
\;\;\;\;\frac{2}{{\ell}^{-2} \cdot \left(t\_m \cdot {k}^{4}\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if k < 1.22000000000000004e-24

    1. Initial program 56.7%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified56.6%

      \[\leadsto \color{blue}{\frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in k around 0 56.4%

      \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \color{blue}{\left(2 \cdot {k}^{2}\right)}} \]
    5. Step-by-step derivation
      1. associate-*l/56.6%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell} \cdot \left(2 \cdot {k}^{2}\right)}{\ell}}} \]
    6. Applied egg-rr56.6%

      \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell} \cdot \left(2 \cdot {k}^{2}\right)}{\ell}}} \]
    7. Step-by-step derivation
      1. associate-/l*56.9%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell} \cdot \frac{2 \cdot {k}^{2}}{\ell}}} \]
    8. Simplified56.9%

      \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3}}{\ell} \cdot \frac{2 \cdot {k}^{2}}{\ell}}} \]
    9. Step-by-step derivation
      1. associate-*l/57.8%

        \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3} \cdot \frac{2 \cdot {k}^{2}}{\ell}}{\ell}}} \]
      2. associate-/l*57.8%

        \[\leadsto \frac{2}{\frac{{t}^{3} \cdot \color{blue}{\left(2 \cdot \frac{{k}^{2}}{\ell}\right)}}{\ell}} \]
    10. Applied egg-rr57.8%

      \[\leadsto \frac{2}{\color{blue}{\frac{{t}^{3} \cdot \left(2 \cdot \frac{{k}^{2}}{\ell}\right)}{\ell}}} \]

    if 1.22000000000000004e-24 < k

    1. Initial program 53.1%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified53.1%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in t around 0 74.8%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot \left(t \cdot {\sin k}^{2}\right)}{{\ell}^{2} \cdot \cos k}}} \]
    5. Step-by-step derivation
      1. associate-*r*74.8%

        \[\leadsto \frac{2}{\frac{\color{blue}{\left({k}^{2} \cdot t\right) \cdot {\sin k}^{2}}}{{\ell}^{2} \cdot \cos k}} \]
      2. times-frac74.8%

        \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]
    6. Simplified74.8%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]
    7. Taylor expanded in k around 0 59.0%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{4} \cdot t}{{\ell}^{2}}}} \]
    8. Step-by-step derivation
      1. associate-/l*58.9%

        \[\leadsto \frac{2}{\color{blue}{{k}^{4} \cdot \frac{t}{{\ell}^{2}}}} \]
    9. Simplified58.9%

      \[\leadsto \frac{2}{\color{blue}{{k}^{4} \cdot \frac{t}{{\ell}^{2}}}} \]
    10. Step-by-step derivation
      1. pow158.9%

        \[\leadsto \frac{2}{\color{blue}{{\left({k}^{4} \cdot \frac{t}{{\ell}^{2}}\right)}^{1}}} \]
      2. div-inv58.9%

        \[\leadsto \frac{2}{{\left({k}^{4} \cdot \color{blue}{\left(t \cdot \frac{1}{{\ell}^{2}}\right)}\right)}^{1}} \]
      3. pow-flip58.9%

        \[\leadsto \frac{2}{{\left({k}^{4} \cdot \left(t \cdot \color{blue}{{\ell}^{\left(-2\right)}}\right)\right)}^{1}} \]
      4. metadata-eval58.9%

        \[\leadsto \frac{2}{{\left({k}^{4} \cdot \left(t \cdot {\ell}^{\color{blue}{-2}}\right)\right)}^{1}} \]
    11. Applied egg-rr58.9%

      \[\leadsto \frac{2}{\color{blue}{{\left({k}^{4} \cdot \left(t \cdot {\ell}^{-2}\right)\right)}^{1}}} \]
    12. Step-by-step derivation
      1. unpow158.9%

        \[\leadsto \frac{2}{\color{blue}{{k}^{4} \cdot \left(t \cdot {\ell}^{-2}\right)}} \]
      2. associate-*r*59.0%

        \[\leadsto \frac{2}{\color{blue}{\left({k}^{4} \cdot t\right) \cdot {\ell}^{-2}}} \]
      3. *-commutative59.0%

        \[\leadsto \frac{2}{\color{blue}{\left(t \cdot {k}^{4}\right)} \cdot {\ell}^{-2}} \]
    13. Simplified59.0%

      \[\leadsto \frac{2}{\color{blue}{\left(t \cdot {k}^{4}\right) \cdot {\ell}^{-2}}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification58.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;k \leq 1.22 \cdot 10^{-24}:\\ \;\;\;\;\frac{2}{\frac{{t}^{3} \cdot \left(2 \cdot \frac{{k}^{2}}{\ell}\right)}{\ell}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{{\ell}^{-2} \cdot \left(t \cdot {k}^{4}\right)}\\ \end{array} \]
  5. Add Preprocessing

Alternative 18: 57.4% accurate, 1.9× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ t\_s \cdot \begin{array}{l} \mathbf{if}\;k \leq 8 \cdot 10^{-25}:\\ \;\;\;\;\frac{2}{\frac{\frac{{t\_m}^{3}}{\ell} \cdot \left(2 \cdot {k}^{2}\right)}{\ell}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{{\ell}^{-2} \cdot \left(t\_m \cdot {k}^{4}\right)}\\ \end{array} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (*
  t_s
  (if (<= k 8e-25)
    (/ 2.0 (/ (* (/ (pow t_m 3.0) l) (* 2.0 (pow k 2.0))) l))
    (/ 2.0 (* (pow l -2.0) (* t_m (pow k 4.0)))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (k <= 8e-25) {
		tmp = 2.0 / (((pow(t_m, 3.0) / l) * (2.0 * pow(k, 2.0))) / l);
	} else {
		tmp = 2.0 / (pow(l, -2.0) * (t_m * pow(k, 4.0)));
	}
	return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
    real(8), intent (in) :: t_s
    real(8), intent (in) :: t_m
    real(8), intent (in) :: l
    real(8), intent (in) :: k
    real(8) :: tmp
    if (k <= 8d-25) then
        tmp = 2.0d0 / ((((t_m ** 3.0d0) / l) * (2.0d0 * (k ** 2.0d0))) / l)
    else
        tmp = 2.0d0 / ((l ** (-2.0d0)) * (t_m * (k ** 4.0d0)))
    end if
    code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (k <= 8e-25) {
		tmp = 2.0 / (((Math.pow(t_m, 3.0) / l) * (2.0 * Math.pow(k, 2.0))) / l);
	} else {
		tmp = 2.0 / (Math.pow(l, -2.0) * (t_m * Math.pow(k, 4.0)));
	}
	return t_s * tmp;
}
t\_m = math.fabs(t)
t\_s = math.copysign(1.0, t)
def code(t_s, t_m, l, k):
	tmp = 0
	if k <= 8e-25:
		tmp = 2.0 / (((math.pow(t_m, 3.0) / l) * (2.0 * math.pow(k, 2.0))) / l)
	else:
		tmp = 2.0 / (math.pow(l, -2.0) * (t_m * math.pow(k, 4.0)))
	return t_s * tmp
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	tmp = 0.0
	if (k <= 8e-25)
		tmp = Float64(2.0 / Float64(Float64(Float64((t_m ^ 3.0) / l) * Float64(2.0 * (k ^ 2.0))) / l));
	else
		tmp = Float64(2.0 / Float64((l ^ -2.0) * Float64(t_m * (k ^ 4.0))));
	end
	return Float64(t_s * tmp)
end
t\_m = abs(t);
t\_s = sign(t) * abs(1.0);
function tmp_2 = code(t_s, t_m, l, k)
	tmp = 0.0;
	if (k <= 8e-25)
		tmp = 2.0 / ((((t_m ^ 3.0) / l) * (2.0 * (k ^ 2.0))) / l);
	else
		tmp = 2.0 / ((l ^ -2.0) * (t_m * (k ^ 4.0)));
	end
	tmp_2 = t_s * tmp;
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[k, 8e-25], N[(2.0 / N[(N[(N[(N[Power[t$95$m, 3.0], $MachinePrecision] / l), $MachinePrecision] * N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[Power[l, -2.0], $MachinePrecision] * N[(t$95$m * N[Power[k, 4.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 8 \cdot 10^{-25}:\\
\;\;\;\;\frac{2}{\frac{\frac{{t\_m}^{3}}{\ell} \cdot \left(2 \cdot {k}^{2}\right)}{\ell}}\\

\mathbf{else}:\\
\;\;\;\;\frac{2}{{\ell}^{-2} \cdot \left(t\_m \cdot {k}^{4}\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if k < 8.00000000000000031e-25

    1. Initial program 56.7%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified56.6%

      \[\leadsto \color{blue}{\frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in k around 0 56.4%

      \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \color{blue}{\left(2 \cdot {k}^{2}\right)}} \]
    5. Step-by-step derivation
      1. associate-*l/56.6%

        \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell} \cdot \left(2 \cdot {k}^{2}\right)}{\ell}}} \]
    6. Applied egg-rr56.6%

      \[\leadsto \frac{2}{\color{blue}{\frac{\frac{{t}^{3}}{\ell} \cdot \left(2 \cdot {k}^{2}\right)}{\ell}}} \]

    if 8.00000000000000031e-25 < k

    1. Initial program 53.1%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified53.1%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in t around 0 74.8%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot \left(t \cdot {\sin k}^{2}\right)}{{\ell}^{2} \cdot \cos k}}} \]
    5. Step-by-step derivation
      1. associate-*r*74.8%

        \[\leadsto \frac{2}{\frac{\color{blue}{\left({k}^{2} \cdot t\right) \cdot {\sin k}^{2}}}{{\ell}^{2} \cdot \cos k}} \]
      2. times-frac74.8%

        \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]
    6. Simplified74.8%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]
    7. Taylor expanded in k around 0 59.0%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{4} \cdot t}{{\ell}^{2}}}} \]
    8. Step-by-step derivation
      1. associate-/l*58.9%

        \[\leadsto \frac{2}{\color{blue}{{k}^{4} \cdot \frac{t}{{\ell}^{2}}}} \]
    9. Simplified58.9%

      \[\leadsto \frac{2}{\color{blue}{{k}^{4} \cdot \frac{t}{{\ell}^{2}}}} \]
    10. Step-by-step derivation
      1. pow158.9%

        \[\leadsto \frac{2}{\color{blue}{{\left({k}^{4} \cdot \frac{t}{{\ell}^{2}}\right)}^{1}}} \]
      2. div-inv58.9%

        \[\leadsto \frac{2}{{\left({k}^{4} \cdot \color{blue}{\left(t \cdot \frac{1}{{\ell}^{2}}\right)}\right)}^{1}} \]
      3. pow-flip58.9%

        \[\leadsto \frac{2}{{\left({k}^{4} \cdot \left(t \cdot \color{blue}{{\ell}^{\left(-2\right)}}\right)\right)}^{1}} \]
      4. metadata-eval58.9%

        \[\leadsto \frac{2}{{\left({k}^{4} \cdot \left(t \cdot {\ell}^{\color{blue}{-2}}\right)\right)}^{1}} \]
    11. Applied egg-rr58.9%

      \[\leadsto \frac{2}{\color{blue}{{\left({k}^{4} \cdot \left(t \cdot {\ell}^{-2}\right)\right)}^{1}}} \]
    12. Step-by-step derivation
      1. unpow158.9%

        \[\leadsto \frac{2}{\color{blue}{{k}^{4} \cdot \left(t \cdot {\ell}^{-2}\right)}} \]
      2. associate-*r*59.0%

        \[\leadsto \frac{2}{\color{blue}{\left({k}^{4} \cdot t\right) \cdot {\ell}^{-2}}} \]
      3. *-commutative59.0%

        \[\leadsto \frac{2}{\color{blue}{\left(t \cdot {k}^{4}\right)} \cdot {\ell}^{-2}} \]
    13. Simplified59.0%

      \[\leadsto \frac{2}{\color{blue}{\left(t \cdot {k}^{4}\right) \cdot {\ell}^{-2}}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification57.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;k \leq 8 \cdot 10^{-25}:\\ \;\;\;\;\frac{2}{\frac{\frac{{t}^{3}}{\ell} \cdot \left(2 \cdot {k}^{2}\right)}{\ell}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{{\ell}^{-2} \cdot \left(t \cdot {k}^{4}\right)}\\ \end{array} \]
  5. Add Preprocessing

Alternative 19: 57.0% accurate, 1.9× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ t\_s \cdot \begin{array}{l} \mathbf{if}\;k \leq 5.8 \cdot 10^{-25}:\\ \;\;\;\;\frac{2}{\left(2 \cdot {k}^{2}\right) \cdot \frac{\frac{{t\_m}^{3}}{\ell}}{\ell}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{{\ell}^{-2} \cdot \left(t\_m \cdot {k}^{4}\right)}\\ \end{array} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (*
  t_s
  (if (<= k 5.8e-25)
    (/ 2.0 (* (* 2.0 (pow k 2.0)) (/ (/ (pow t_m 3.0) l) l)))
    (/ 2.0 (* (pow l -2.0) (* t_m (pow k 4.0)))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (k <= 5.8e-25) {
		tmp = 2.0 / ((2.0 * pow(k, 2.0)) * ((pow(t_m, 3.0) / l) / l));
	} else {
		tmp = 2.0 / (pow(l, -2.0) * (t_m * pow(k, 4.0)));
	}
	return t_s * tmp;
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
    real(8), intent (in) :: t_s
    real(8), intent (in) :: t_m
    real(8), intent (in) :: l
    real(8), intent (in) :: k
    real(8) :: tmp
    if (k <= 5.8d-25) then
        tmp = 2.0d0 / ((2.0d0 * (k ** 2.0d0)) * (((t_m ** 3.0d0) / l) / l))
    else
        tmp = 2.0d0 / ((l ** (-2.0d0)) * (t_m * (k ** 4.0d0)))
    end if
    code = t_s * tmp
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	double tmp;
	if (k <= 5.8e-25) {
		tmp = 2.0 / ((2.0 * Math.pow(k, 2.0)) * ((Math.pow(t_m, 3.0) / l) / l));
	} else {
		tmp = 2.0 / (Math.pow(l, -2.0) * (t_m * Math.pow(k, 4.0)));
	}
	return t_s * tmp;
}
t\_m = math.fabs(t)
t\_s = math.copysign(1.0, t)
def code(t_s, t_m, l, k):
	tmp = 0
	if k <= 5.8e-25:
		tmp = 2.0 / ((2.0 * math.pow(k, 2.0)) * ((math.pow(t_m, 3.0) / l) / l))
	else:
		tmp = 2.0 / (math.pow(l, -2.0) * (t_m * math.pow(k, 4.0)))
	return t_s * tmp
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	tmp = 0.0
	if (k <= 5.8e-25)
		tmp = Float64(2.0 / Float64(Float64(2.0 * (k ^ 2.0)) * Float64(Float64((t_m ^ 3.0) / l) / l)));
	else
		tmp = Float64(2.0 / Float64((l ^ -2.0) * Float64(t_m * (k ^ 4.0))));
	end
	return Float64(t_s * tmp)
end
t\_m = abs(t);
t\_s = sign(t) * abs(1.0);
function tmp_2 = code(t_s, t_m, l, k)
	tmp = 0.0;
	if (k <= 5.8e-25)
		tmp = 2.0 / ((2.0 * (k ^ 2.0)) * (((t_m ^ 3.0) / l) / l));
	else
		tmp = 2.0 / ((l ^ -2.0) * (t_m * (k ^ 4.0)));
	end
	tmp_2 = t_s * tmp;
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * If[LessEqual[k, 5.8e-25], N[(2.0 / N[(N[(2.0 * N[Power[k, 2.0], $MachinePrecision]), $MachinePrecision] * N[(N[(N[Power[t$95$m, 3.0], $MachinePrecision] / l), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[Power[l, -2.0], $MachinePrecision] * N[(t$95$m * N[Power[k, 4.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
t\_s \cdot \begin{array}{l}
\mathbf{if}\;k \leq 5.8 \cdot 10^{-25}:\\
\;\;\;\;\frac{2}{\left(2 \cdot {k}^{2}\right) \cdot \frac{\frac{{t\_m}^{3}}{\ell}}{\ell}}\\

\mathbf{else}:\\
\;\;\;\;\frac{2}{{\ell}^{-2} \cdot \left(t\_m \cdot {k}^{4}\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if k < 5.8000000000000001e-25

    1. Initial program 56.7%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified56.6%

      \[\leadsto \color{blue}{\frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \left(\left(\sin k \cdot \tan k\right) \cdot \left(2 + {\left(\frac{k}{t}\right)}^{2}\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in k around 0 56.4%

      \[\leadsto \frac{2}{\frac{\frac{{t}^{3}}{\ell}}{\ell} \cdot \color{blue}{\left(2 \cdot {k}^{2}\right)}} \]

    if 5.8000000000000001e-25 < k

    1. Initial program 53.1%

      \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
    2. Simplified53.1%

      \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in t around 0 74.8%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot \left(t \cdot {\sin k}^{2}\right)}{{\ell}^{2} \cdot \cos k}}} \]
    5. Step-by-step derivation
      1. associate-*r*74.8%

        \[\leadsto \frac{2}{\frac{\color{blue}{\left({k}^{2} \cdot t\right) \cdot {\sin k}^{2}}}{{\ell}^{2} \cdot \cos k}} \]
      2. times-frac74.8%

        \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]
    6. Simplified74.8%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]
    7. Taylor expanded in k around 0 59.0%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{4} \cdot t}{{\ell}^{2}}}} \]
    8. Step-by-step derivation
      1. associate-/l*58.9%

        \[\leadsto \frac{2}{\color{blue}{{k}^{4} \cdot \frac{t}{{\ell}^{2}}}} \]
    9. Simplified58.9%

      \[\leadsto \frac{2}{\color{blue}{{k}^{4} \cdot \frac{t}{{\ell}^{2}}}} \]
    10. Step-by-step derivation
      1. pow158.9%

        \[\leadsto \frac{2}{\color{blue}{{\left({k}^{4} \cdot \frac{t}{{\ell}^{2}}\right)}^{1}}} \]
      2. div-inv58.9%

        \[\leadsto \frac{2}{{\left({k}^{4} \cdot \color{blue}{\left(t \cdot \frac{1}{{\ell}^{2}}\right)}\right)}^{1}} \]
      3. pow-flip58.9%

        \[\leadsto \frac{2}{{\left({k}^{4} \cdot \left(t \cdot \color{blue}{{\ell}^{\left(-2\right)}}\right)\right)}^{1}} \]
      4. metadata-eval58.9%

        \[\leadsto \frac{2}{{\left({k}^{4} \cdot \left(t \cdot {\ell}^{\color{blue}{-2}}\right)\right)}^{1}} \]
    11. Applied egg-rr58.9%

      \[\leadsto \frac{2}{\color{blue}{{\left({k}^{4} \cdot \left(t \cdot {\ell}^{-2}\right)\right)}^{1}}} \]
    12. Step-by-step derivation
      1. unpow158.9%

        \[\leadsto \frac{2}{\color{blue}{{k}^{4} \cdot \left(t \cdot {\ell}^{-2}\right)}} \]
      2. associate-*r*59.0%

        \[\leadsto \frac{2}{\color{blue}{\left({k}^{4} \cdot t\right) \cdot {\ell}^{-2}}} \]
      3. *-commutative59.0%

        \[\leadsto \frac{2}{\color{blue}{\left(t \cdot {k}^{4}\right)} \cdot {\ell}^{-2}} \]
    13. Simplified59.0%

      \[\leadsto \frac{2}{\color{blue}{\left(t \cdot {k}^{4}\right) \cdot {\ell}^{-2}}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification57.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;k \leq 5.8 \cdot 10^{-25}:\\ \;\;\;\;\frac{2}{\left(2 \cdot {k}^{2}\right) \cdot \frac{\frac{{t}^{3}}{\ell}}{\ell}}\\ \mathbf{else}:\\ \;\;\;\;\frac{2}{{\ell}^{-2} \cdot \left(t \cdot {k}^{4}\right)}\\ \end{array} \]
  5. Add Preprocessing

Alternative 20: 52.4% accurate, 2.0× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ t\_s \cdot \frac{2}{{k}^{4} \cdot \frac{t\_m}{{\ell}^{2}}} \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (* t_s (/ 2.0 (* (pow k 4.0) (/ t_m (pow l 2.0))))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	return t_s * (2.0 / (pow(k, 4.0) * (t_m / pow(l, 2.0))));
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
    real(8), intent (in) :: t_s
    real(8), intent (in) :: t_m
    real(8), intent (in) :: l
    real(8), intent (in) :: k
    code = t_s * (2.0d0 / ((k ** 4.0d0) * (t_m / (l ** 2.0d0))))
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	return t_s * (2.0 / (Math.pow(k, 4.0) * (t_m / Math.pow(l, 2.0))));
}
t\_m = math.fabs(t)
t\_s = math.copysign(1.0, t)
def code(t_s, t_m, l, k):
	return t_s * (2.0 / (math.pow(k, 4.0) * (t_m / math.pow(l, 2.0))))
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	return Float64(t_s * Float64(2.0 / Float64((k ^ 4.0) * Float64(t_m / (l ^ 2.0)))))
end
t\_m = abs(t);
t\_s = sign(t) * abs(1.0);
function tmp = code(t_s, t_m, l, k)
	tmp = t_s * (2.0 / ((k ^ 4.0) * (t_m / (l ^ 2.0))));
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * N[(2.0 / N[(N[Power[k, 4.0], $MachinePrecision] * N[(t$95$m / N[Power[l, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
t\_s \cdot \frac{2}{{k}^{4} \cdot \frac{t\_m}{{\ell}^{2}}}
\end{array}
Derivation
  1. Initial program 55.7%

    \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
  2. Simplified55.7%

    \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
  3. Add Preprocessing
  4. Taylor expanded in t around 0 63.6%

    \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot \left(t \cdot {\sin k}^{2}\right)}{{\ell}^{2} \cdot \cos k}}} \]
  5. Step-by-step derivation
    1. associate-*r*63.6%

      \[\leadsto \frac{2}{\frac{\color{blue}{\left({k}^{2} \cdot t\right) \cdot {\sin k}^{2}}}{{\ell}^{2} \cdot \cos k}} \]
    2. times-frac65.5%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]
  6. Simplified65.5%

    \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]
  7. Taylor expanded in k around 0 55.6%

    \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{4} \cdot t}{{\ell}^{2}}}} \]
  8. Step-by-step derivation
    1. associate-/l*55.9%

      \[\leadsto \frac{2}{\color{blue}{{k}^{4} \cdot \frac{t}{{\ell}^{2}}}} \]
  9. Simplified55.9%

    \[\leadsto \frac{2}{\color{blue}{{k}^{4} \cdot \frac{t}{{\ell}^{2}}}} \]
  10. Add Preprocessing

Alternative 21: 52.3% accurate, 2.0× speedup?

\[\begin{array}{l} t\_m = \left|t\right| \\ t\_s = \mathsf{copysign}\left(1, t\right) \\ t\_s \cdot \left(\frac{2}{{k}^{4}} \cdot \frac{{\ell}^{2}}{t\_m}\right) \end{array} \]
t\_m = (fabs.f64 t)
t\_s = (copysign.f64 #s(literal 1 binary64) t)
(FPCore (t_s t_m l k)
 :precision binary64
 (* t_s (* (/ 2.0 (pow k 4.0)) (/ (pow l 2.0) t_m))))
t\_m = fabs(t);
t\_s = copysign(1.0, t);
double code(double t_s, double t_m, double l, double k) {
	return t_s * ((2.0 / pow(k, 4.0)) * (pow(l, 2.0) / t_m));
}
t\_m = abs(t)
t\_s = copysign(1.0d0, t)
real(8) function code(t_s, t_m, l, k)
    real(8), intent (in) :: t_s
    real(8), intent (in) :: t_m
    real(8), intent (in) :: l
    real(8), intent (in) :: k
    code = t_s * ((2.0d0 / (k ** 4.0d0)) * ((l ** 2.0d0) / t_m))
end function
t\_m = Math.abs(t);
t\_s = Math.copySign(1.0, t);
public static double code(double t_s, double t_m, double l, double k) {
	return t_s * ((2.0 / Math.pow(k, 4.0)) * (Math.pow(l, 2.0) / t_m));
}
t\_m = math.fabs(t)
t\_s = math.copysign(1.0, t)
def code(t_s, t_m, l, k):
	return t_s * ((2.0 / math.pow(k, 4.0)) * (math.pow(l, 2.0) / t_m))
t\_m = abs(t)
t\_s = copysign(1.0, t)
function code(t_s, t_m, l, k)
	return Float64(t_s * Float64(Float64(2.0 / (k ^ 4.0)) * Float64((l ^ 2.0) / t_m)))
end
t\_m = abs(t);
t\_s = sign(t) * abs(1.0);
function tmp = code(t_s, t_m, l, k)
	tmp = t_s * ((2.0 / (k ^ 4.0)) * ((l ^ 2.0) / t_m));
end
t\_m = N[Abs[t], $MachinePrecision]
t\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[t]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[t$95$s_, t$95$m_, l_, k_] := N[(t$95$s * N[(N[(2.0 / N[Power[k, 4.0], $MachinePrecision]), $MachinePrecision] * N[(N[Power[l, 2.0], $MachinePrecision] / t$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
t\_m = \left|t\right|
\\
t\_s = \mathsf{copysign}\left(1, t\right)

\\
t\_s \cdot \left(\frac{2}{{k}^{4}} \cdot \frac{{\ell}^{2}}{t\_m}\right)
\end{array}
Derivation
  1. Initial program 55.7%

    \[\frac{2}{\left(\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \tan k\right) \cdot \left(\left(1 + {\left(\frac{k}{t}\right)}^{2}\right) + 1\right)} \]
  2. Simplified55.7%

    \[\leadsto \color{blue}{\frac{2}{\left(\frac{{t}^{3}}{\ell \cdot \ell} \cdot \sin k\right) \cdot \left(\tan k \cdot \left(1 + \left(1 + {\left(\frac{k}{t}\right)}^{2}\right)\right)\right)}} \]
  3. Add Preprocessing
  4. Taylor expanded in t around 0 63.6%

    \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot \left(t \cdot {\sin k}^{2}\right)}{{\ell}^{2} \cdot \cos k}}} \]
  5. Step-by-step derivation
    1. associate-*r*63.6%

      \[\leadsto \frac{2}{\frac{\color{blue}{\left({k}^{2} \cdot t\right) \cdot {\sin k}^{2}}}{{\ell}^{2} \cdot \cos k}} \]
    2. times-frac65.5%

      \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]
  6. Simplified65.5%

    \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{2} \cdot t}{{\ell}^{2}} \cdot \frac{{\sin k}^{2}}{\cos k}}} \]
  7. Taylor expanded in k around 0 55.6%

    \[\leadsto \frac{2}{\color{blue}{\frac{{k}^{4} \cdot t}{{\ell}^{2}}}} \]
  8. Step-by-step derivation
    1. associate-/l*55.9%

      \[\leadsto \frac{2}{\color{blue}{{k}^{4} \cdot \frac{t}{{\ell}^{2}}}} \]
  9. Simplified55.9%

    \[\leadsto \frac{2}{\color{blue}{{k}^{4} \cdot \frac{t}{{\ell}^{2}}}} \]
  10. Taylor expanded in k around 0 55.6%

    \[\leadsto \color{blue}{2 \cdot \frac{{\ell}^{2}}{{k}^{4} \cdot t}} \]
  11. Step-by-step derivation
    1. associate-*r/55.6%

      \[\leadsto \color{blue}{\frac{2 \cdot {\ell}^{2}}{{k}^{4} \cdot t}} \]
    2. times-frac55.8%

      \[\leadsto \color{blue}{\frac{2}{{k}^{4}} \cdot \frac{{\ell}^{2}}{t}} \]
  12. Simplified55.8%

    \[\leadsto \color{blue}{\frac{2}{{k}^{4}} \cdot \frac{{\ell}^{2}}{t}} \]
  13. Add Preprocessing

Reproduce

?
herbie shell --seed 2024137 
(FPCore (t l k)
  :name "Toniolo and Linder, Equation (10+)"
  :precision binary64
  (/ 2.0 (* (* (* (/ (pow t 3.0) (* l l)) (sin k)) (tan k)) (+ (+ 1.0 (pow (/ k t) 2.0)) 1.0))))