
(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:
Herbie found 15 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(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}
(FPCore (t l k) :precision binary64 (/ 2.0 (* (/ (/ k (cos k)) l) (* (* t (sin k)) (* k (/ (sin k) l))))))
double code(double t, double l, double k) {
return 2.0 / (((k / cos(k)) / l) * ((t * sin(k)) * (k * (sin(k) / l))));
}
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 / (((k / cos(k)) / l) * ((t * sin(k)) * (k * (sin(k) / l))))
end function
public static double code(double t, double l, double k) {
return 2.0 / (((k / Math.cos(k)) / l) * ((t * Math.sin(k)) * (k * (Math.sin(k) / l))));
}
def code(t, l, k): return 2.0 / (((k / math.cos(k)) / l) * ((t * math.sin(k)) * (k * (math.sin(k) / l))))
function code(t, l, k) return Float64(2.0 / Float64(Float64(Float64(k / cos(k)) / l) * Float64(Float64(t * sin(k)) * Float64(k * Float64(sin(k) / l))))) end
function tmp = code(t, l, k) tmp = 2.0 / (((k / cos(k)) / l) * ((t * sin(k)) * (k * (sin(k) / l)))); end
code[t_, l_, k_] := N[(2.0 / N[(N[(N[(k / N[Cos[k], $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision] * N[(N[(t * N[Sin[k], $MachinePrecision]), $MachinePrecision] * N[(k * N[(N[Sin[k], $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{2}{\frac{\frac{k}{\cos k}}{\ell} \cdot \left(\left(t \cdot \sin k\right) \cdot \left(k \cdot \frac{\sin k}{\ell}\right)\right)}
\end{array}
Initial program 32.3%
Taylor expanded in t around 0
unpow2N/A
associate-*l*N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
times-fracN/A
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-cos.f64N/A
*-commutativeN/A
lower-/.f64N/A
Applied rewrites92.2%
Applied rewrites94.7%
Applied rewrites98.8%
(FPCore (t l k)
:precision binary64
(let* ((t_1 (pow (sin k) 2.0)) (t_2 (* (cos k) l)))
(if (<= k 2.7e-34)
(/ 2.0 (/ (* (* (/ k l) k) t) (/ (/ l k) k)))
(if (<= k 6.6e+140)
(/ 2.0 (* k (/ (* (/ k l) (* t_1 t)) t_2)))
(/ 2.0 (* t (* (/ (* t_1 k) l) (/ k t_2))))))))
double code(double t, double l, double k) {
double t_1 = pow(sin(k), 2.0);
double t_2 = cos(k) * l;
double tmp;
if (k <= 2.7e-34) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else if (k <= 6.6e+140) {
tmp = 2.0 / (k * (((k / l) * (t_1 * t)) / t_2));
} else {
tmp = 2.0 / (t * (((t_1 * k) / l) * (k / t_2)));
}
return tmp;
}
real(8) function code(t, l, k)
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = sin(k) ** 2.0d0
t_2 = cos(k) * l
if (k <= 2.7d-34) then
tmp = 2.0d0 / ((((k / l) * k) * t) / ((l / k) / k))
else if (k <= 6.6d+140) then
tmp = 2.0d0 / (k * (((k / l) * (t_1 * t)) / t_2))
else
tmp = 2.0d0 / (t * (((t_1 * k) / l) * (k / t_2)))
end if
code = tmp
end function
public static double code(double t, double l, double k) {
double t_1 = Math.pow(Math.sin(k), 2.0);
double t_2 = Math.cos(k) * l;
double tmp;
if (k <= 2.7e-34) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else if (k <= 6.6e+140) {
tmp = 2.0 / (k * (((k / l) * (t_1 * t)) / t_2));
} else {
tmp = 2.0 / (t * (((t_1 * k) / l) * (k / t_2)));
}
return tmp;
}
def code(t, l, k): t_1 = math.pow(math.sin(k), 2.0) t_2 = math.cos(k) * l tmp = 0 if k <= 2.7e-34: tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)) elif k <= 6.6e+140: tmp = 2.0 / (k * (((k / l) * (t_1 * t)) / t_2)) else: tmp = 2.0 / (t * (((t_1 * k) / l) * (k / t_2))) return tmp
function code(t, l, k) t_1 = sin(k) ^ 2.0 t_2 = Float64(cos(k) * l) tmp = 0.0 if (k <= 2.7e-34) tmp = Float64(2.0 / Float64(Float64(Float64(Float64(k / l) * k) * t) / Float64(Float64(l / k) / k))); elseif (k <= 6.6e+140) tmp = Float64(2.0 / Float64(k * Float64(Float64(Float64(k / l) * Float64(t_1 * t)) / t_2))); else tmp = Float64(2.0 / Float64(t * Float64(Float64(Float64(t_1 * k) / l) * Float64(k / t_2)))); end return tmp end
function tmp_2 = code(t, l, k) t_1 = sin(k) ^ 2.0; t_2 = cos(k) * l; tmp = 0.0; if (k <= 2.7e-34) tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)); elseif (k <= 6.6e+140) tmp = 2.0 / (k * (((k / l) * (t_1 * t)) / t_2)); else tmp = 2.0 / (t * (((t_1 * k) / l) * (k / t_2))); end tmp_2 = tmp; end
code[t_, l_, k_] := Block[{t$95$1 = N[Power[N[Sin[k], $MachinePrecision], 2.0], $MachinePrecision]}, Block[{t$95$2 = N[(N[Cos[k], $MachinePrecision] * l), $MachinePrecision]}, If[LessEqual[k, 2.7e-34], N[(2.0 / N[(N[(N[(N[(k / l), $MachinePrecision] * k), $MachinePrecision] * t), $MachinePrecision] / N[(N[(l / k), $MachinePrecision] / k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 6.6e+140], N[(2.0 / N[(k * N[(N[(N[(k / l), $MachinePrecision] * N[(t$95$1 * t), $MachinePrecision]), $MachinePrecision] / t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(t * N[(N[(N[(t$95$1 * k), $MachinePrecision] / l), $MachinePrecision] * N[(k / t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := {\sin k}^{2}\\
t_2 := \cos k \cdot \ell\\
\mathbf{if}\;k \leq 2.7 \cdot 10^{-34}:\\
\;\;\;\;\frac{2}{\frac{\left(\frac{k}{\ell} \cdot k\right) \cdot t}{\frac{\frac{\ell}{k}}{k}}}\\
\mathbf{elif}\;k \leq 6.6 \cdot 10^{+140}:\\
\;\;\;\;\frac{2}{k \cdot \frac{\frac{k}{\ell} \cdot \left(t\_1 \cdot t\right)}{t\_2}}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{t \cdot \left(\frac{t\_1 \cdot k}{\ell} \cdot \frac{k}{t\_2}\right)}\\
\end{array}
\end{array}
if k < 2.70000000000000017e-34Initial program 34.1%
Taylor expanded in k around 0
*-commutativeN/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
unpow2N/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-pow.f6475.4
Applied rewrites75.4%
Applied rewrites65.3%
Applied rewrites86.1%
if 2.70000000000000017e-34 < k < 6.6000000000000003e140Initial program 15.4%
Taylor expanded in t around 0
unpow2N/A
associate-*l*N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
times-fracN/A
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-cos.f64N/A
*-commutativeN/A
lower-/.f64N/A
Applied rewrites94.0%
Applied rewrites94.0%
Applied rewrites96.1%
if 6.6000000000000003e140 < k Initial program 43.7%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
associate-*l*N/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*l*N/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites77.3%
Taylor expanded in t around 0
*-commutativeN/A
unpow2N/A
associate-*r*N/A
unpow2N/A
associate-*l*N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
lower-pow.f64N/A
lower-sin.f64N/A
lower-/.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-cos.f6496.5
Applied rewrites96.5%
(FPCore (t l k) :precision binary64 (if (<= k 2.7e-34) (/ 2.0 (/ (* (* (/ k l) k) t) (/ (/ l k) k))) (/ 2.0 (* (/ k (* l (cos k))) (/ (* (* (pow (sin k) 2.0) t) k) l)))))
double code(double t, double l, double k) {
double tmp;
if (k <= 2.7e-34) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else {
tmp = 2.0 / ((k / (l * cos(k))) * (((pow(sin(k), 2.0) * t) * k) / l));
}
return tmp;
}
real(8) function code(t, l, k)
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: tmp
if (k <= 2.7d-34) then
tmp = 2.0d0 / ((((k / l) * k) * t) / ((l / k) / k))
else
tmp = 2.0d0 / ((k / (l * cos(k))) * ((((sin(k) ** 2.0d0) * t) * k) / l))
end if
code = tmp
end function
public static double code(double t, double l, double k) {
double tmp;
if (k <= 2.7e-34) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else {
tmp = 2.0 / ((k / (l * Math.cos(k))) * (((Math.pow(Math.sin(k), 2.0) * t) * k) / l));
}
return tmp;
}
def code(t, l, k): tmp = 0 if k <= 2.7e-34: tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)) else: tmp = 2.0 / ((k / (l * math.cos(k))) * (((math.pow(math.sin(k), 2.0) * t) * k) / l)) return tmp
function code(t, l, k) tmp = 0.0 if (k <= 2.7e-34) tmp = Float64(2.0 / Float64(Float64(Float64(Float64(k / l) * k) * t) / Float64(Float64(l / k) / k))); else tmp = Float64(2.0 / Float64(Float64(k / Float64(l * cos(k))) * Float64(Float64(Float64((sin(k) ^ 2.0) * t) * k) / l))); end return tmp end
function tmp_2 = code(t, l, k) tmp = 0.0; if (k <= 2.7e-34) tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)); else tmp = 2.0 / ((k / (l * cos(k))) * ((((sin(k) ^ 2.0) * t) * k) / l)); end tmp_2 = tmp; end
code[t_, l_, k_] := If[LessEqual[k, 2.7e-34], N[(2.0 / N[(N[(N[(N[(k / l), $MachinePrecision] * k), $MachinePrecision] * t), $MachinePrecision] / N[(N[(l / k), $MachinePrecision] / k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(k / N[(l * N[Cos[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(N[(N[Power[N[Sin[k], $MachinePrecision], 2.0], $MachinePrecision] * t), $MachinePrecision] * k), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;k \leq 2.7 \cdot 10^{-34}:\\
\;\;\;\;\frac{2}{\frac{\left(\frac{k}{\ell} \cdot k\right) \cdot t}{\frac{\frac{\ell}{k}}{k}}}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\frac{k}{\ell \cdot \cos k} \cdot \frac{\left({\sin k}^{2} \cdot t\right) \cdot k}{\ell}}\\
\end{array}
\end{array}
if k < 2.70000000000000017e-34Initial program 34.1%
Taylor expanded in k around 0
*-commutativeN/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
unpow2N/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-pow.f6475.4
Applied rewrites75.4%
Applied rewrites65.3%
Applied rewrites86.1%
if 2.70000000000000017e-34 < k Initial program 27.5%
Taylor expanded in t around 0
unpow2N/A
associate-*l*N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
times-fracN/A
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-cos.f64N/A
*-commutativeN/A
lower-/.f64N/A
Applied rewrites92.6%
Applied rewrites92.5%
(FPCore (t l k) :precision binary64 (if (<= k 2.7e-34) (/ 2.0 (/ (* (* (/ k l) k) t) (/ (/ l k) k))) (/ 2.0 (* k (/ (* (/ k l) (* (pow (sin k) 2.0) t)) (* (cos k) l))))))
double code(double t, double l, double k) {
double tmp;
if (k <= 2.7e-34) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else {
tmp = 2.0 / (k * (((k / l) * (pow(sin(k), 2.0) * t)) / (cos(k) * l)));
}
return tmp;
}
real(8) function code(t, l, k)
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: tmp
if (k <= 2.7d-34) then
tmp = 2.0d0 / ((((k / l) * k) * t) / ((l / k) / k))
else
tmp = 2.0d0 / (k * (((k / l) * ((sin(k) ** 2.0d0) * t)) / (cos(k) * l)))
end if
code = tmp
end function
public static double code(double t, double l, double k) {
double tmp;
if (k <= 2.7e-34) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else {
tmp = 2.0 / (k * (((k / l) * (Math.pow(Math.sin(k), 2.0) * t)) / (Math.cos(k) * l)));
}
return tmp;
}
def code(t, l, k): tmp = 0 if k <= 2.7e-34: tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)) else: tmp = 2.0 / (k * (((k / l) * (math.pow(math.sin(k), 2.0) * t)) / (math.cos(k) * l))) return tmp
function code(t, l, k) tmp = 0.0 if (k <= 2.7e-34) tmp = Float64(2.0 / Float64(Float64(Float64(Float64(k / l) * k) * t) / Float64(Float64(l / k) / k))); else tmp = Float64(2.0 / Float64(k * Float64(Float64(Float64(k / l) * Float64((sin(k) ^ 2.0) * t)) / Float64(cos(k) * l)))); end return tmp end
function tmp_2 = code(t, l, k) tmp = 0.0; if (k <= 2.7e-34) tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)); else tmp = 2.0 / (k * (((k / l) * ((sin(k) ^ 2.0) * t)) / (cos(k) * l))); end tmp_2 = tmp; end
code[t_, l_, k_] := If[LessEqual[k, 2.7e-34], N[(2.0 / N[(N[(N[(N[(k / l), $MachinePrecision] * k), $MachinePrecision] * t), $MachinePrecision] / N[(N[(l / k), $MachinePrecision] / k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(k * N[(N[(N[(k / l), $MachinePrecision] * N[(N[Power[N[Sin[k], $MachinePrecision], 2.0], $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision] / N[(N[Cos[k], $MachinePrecision] * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;k \leq 2.7 \cdot 10^{-34}:\\
\;\;\;\;\frac{2}{\frac{\left(\frac{k}{\ell} \cdot k\right) \cdot t}{\frac{\frac{\ell}{k}}{k}}}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{k \cdot \frac{\frac{k}{\ell} \cdot \left({\sin k}^{2} \cdot t\right)}{\cos k \cdot \ell}}\\
\end{array}
\end{array}
if k < 2.70000000000000017e-34Initial program 34.1%
Taylor expanded in k around 0
*-commutativeN/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
unpow2N/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-pow.f6475.4
Applied rewrites75.4%
Applied rewrites65.3%
Applied rewrites86.1%
if 2.70000000000000017e-34 < k Initial program 27.5%
Taylor expanded in t around 0
unpow2N/A
associate-*l*N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
times-fracN/A
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-cos.f64N/A
*-commutativeN/A
lower-/.f64N/A
Applied rewrites92.6%
Applied rewrites92.5%
Applied rewrites96.3%
(FPCore (t l k)
:precision binary64
(if (<= k 3.8e-14)
(/ 2.0 (/ (* (* (/ k l) k) t) (/ (/ l k) k)))
(if (<= k 1.6e+141)
(* (/ (* 2.0 (cos k)) (* (* k k) t)) (* (* l (pow (sin k) -2.0)) l))
(/
2.0
(*
t
(* (* (/ t l) (/ t l)) (* (/ k t) (* (/ k t) (* (tan k) (sin k))))))))))
double code(double t, double l, double k) {
double tmp;
if (k <= 3.8e-14) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else if (k <= 1.6e+141) {
tmp = ((2.0 * cos(k)) / ((k * k) * t)) * ((l * pow(sin(k), -2.0)) * l);
} else {
tmp = 2.0 / (t * (((t / l) * (t / l)) * ((k / t) * ((k / t) * (tan(k) * sin(k))))));
}
return tmp;
}
real(8) function code(t, l, k)
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: tmp
if (k <= 3.8d-14) then
tmp = 2.0d0 / ((((k / l) * k) * t) / ((l / k) / k))
else if (k <= 1.6d+141) then
tmp = ((2.0d0 * cos(k)) / ((k * k) * t)) * ((l * (sin(k) ** (-2.0d0))) * l)
else
tmp = 2.0d0 / (t * (((t / l) * (t / l)) * ((k / t) * ((k / t) * (tan(k) * sin(k))))))
end if
code = tmp
end function
public static double code(double t, double l, double k) {
double tmp;
if (k <= 3.8e-14) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else if (k <= 1.6e+141) {
tmp = ((2.0 * Math.cos(k)) / ((k * k) * t)) * ((l * Math.pow(Math.sin(k), -2.0)) * l);
} else {
tmp = 2.0 / (t * (((t / l) * (t / l)) * ((k / t) * ((k / t) * (Math.tan(k) * Math.sin(k))))));
}
return tmp;
}
def code(t, l, k): tmp = 0 if k <= 3.8e-14: tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)) elif k <= 1.6e+141: tmp = ((2.0 * math.cos(k)) / ((k * k) * t)) * ((l * math.pow(math.sin(k), -2.0)) * l) else: tmp = 2.0 / (t * (((t / l) * (t / l)) * ((k / t) * ((k / t) * (math.tan(k) * math.sin(k)))))) return tmp
function code(t, l, k) tmp = 0.0 if (k <= 3.8e-14) tmp = Float64(2.0 / Float64(Float64(Float64(Float64(k / l) * k) * t) / Float64(Float64(l / k) / k))); elseif (k <= 1.6e+141) tmp = Float64(Float64(Float64(2.0 * cos(k)) / Float64(Float64(k * k) * t)) * Float64(Float64(l * (sin(k) ^ -2.0)) * l)); else tmp = Float64(2.0 / Float64(t * Float64(Float64(Float64(t / l) * Float64(t / l)) * Float64(Float64(k / t) * Float64(Float64(k / t) * Float64(tan(k) * sin(k))))))); end return tmp end
function tmp_2 = code(t, l, k) tmp = 0.0; if (k <= 3.8e-14) tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)); elseif (k <= 1.6e+141) tmp = ((2.0 * cos(k)) / ((k * k) * t)) * ((l * (sin(k) ^ -2.0)) * l); else tmp = 2.0 / (t * (((t / l) * (t / l)) * ((k / t) * ((k / t) * (tan(k) * sin(k)))))); end tmp_2 = tmp; end
code[t_, l_, k_] := If[LessEqual[k, 3.8e-14], N[(2.0 / N[(N[(N[(N[(k / l), $MachinePrecision] * k), $MachinePrecision] * t), $MachinePrecision] / N[(N[(l / k), $MachinePrecision] / k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 1.6e+141], N[(N[(N[(2.0 * N[Cos[k], $MachinePrecision]), $MachinePrecision] / N[(N[(k * k), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision] * N[(N[(l * N[Power[N[Sin[k], $MachinePrecision], -2.0], $MachinePrecision]), $MachinePrecision] * l), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(t * N[(N[(N[(t / l), $MachinePrecision] * N[(t / l), $MachinePrecision]), $MachinePrecision] * N[(N[(k / t), $MachinePrecision] * N[(N[(k / t), $MachinePrecision] * N[(N[Tan[k], $MachinePrecision] * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;k \leq 3.8 \cdot 10^{-14}:\\
\;\;\;\;\frac{2}{\frac{\left(\frac{k}{\ell} \cdot k\right) \cdot t}{\frac{\frac{\ell}{k}}{k}}}\\
\mathbf{elif}\;k \leq 1.6 \cdot 10^{+141}:\\
\;\;\;\;\frac{2 \cdot \cos k}{\left(k \cdot k\right) \cdot t} \cdot \left(\left(\ell \cdot {\sin k}^{-2}\right) \cdot \ell\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{t \cdot \left(\left(\frac{t}{\ell} \cdot \frac{t}{\ell}\right) \cdot \left(\frac{k}{t} \cdot \left(\frac{k}{t} \cdot \left(\tan k \cdot \sin k\right)\right)\right)\right)}\\
\end{array}
\end{array}
if k < 3.8000000000000002e-14Initial program 34.1%
Taylor expanded in k around 0
*-commutativeN/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
unpow2N/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-pow.f6475.8
Applied rewrites75.8%
Applied rewrites65.5%
Applied rewrites86.5%
if 3.8000000000000002e-14 < k < 1.60000000000000009e141Initial program 12.2%
Taylor expanded in t around 0
unpow2N/A
associate-*l*N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
times-fracN/A
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-cos.f64N/A
*-commutativeN/A
lower-/.f64N/A
Applied rewrites93.1%
Taylor expanded in t around 0
associate-*r/N/A
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
lower-cos.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f64N/A
lower-pow.f64N/A
lower-sin.f6485.1
Applied rewrites85.1%
Applied rewrites85.1%
if 1.60000000000000009e141 < k Initial program 43.7%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
associate-*l*N/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*l*N/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites77.3%
lift-*.f64N/A
*-commutativeN/A
lift-pow.f64N/A
unpow2N/A
associate-*l*N/A
lower-*.f64N/A
lower-*.f6477.2
Applied rewrites77.2%
lift-/.f64N/A
lift-*.f64N/A
*-commutativeN/A
associate-/l*N/A
lift-/.f64N/A
lower-*.f6480.0
Applied rewrites80.0%
(FPCore (t l k) :precision binary64 (if (<= k 2.7e-30) (/ 2.0 (/ (* (* (/ k l) k) t) (/ (/ l k) k))) (/ 2.0 (* k (/ (* (* k (pow (sin k) 2.0)) t) (* (* (cos k) l) l))))))
double code(double t, double l, double k) {
double tmp;
if (k <= 2.7e-30) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else {
tmp = 2.0 / (k * (((k * pow(sin(k), 2.0)) * t) / ((cos(k) * l) * l)));
}
return tmp;
}
real(8) function code(t, l, k)
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: tmp
if (k <= 2.7d-30) then
tmp = 2.0d0 / ((((k / l) * k) * t) / ((l / k) / k))
else
tmp = 2.0d0 / (k * (((k * (sin(k) ** 2.0d0)) * t) / ((cos(k) * l) * l)))
end if
code = tmp
end function
public static double code(double t, double l, double k) {
double tmp;
if (k <= 2.7e-30) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else {
tmp = 2.0 / (k * (((k * Math.pow(Math.sin(k), 2.0)) * t) / ((Math.cos(k) * l) * l)));
}
return tmp;
}
def code(t, l, k): tmp = 0 if k <= 2.7e-30: tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)) else: tmp = 2.0 / (k * (((k * math.pow(math.sin(k), 2.0)) * t) / ((math.cos(k) * l) * l))) return tmp
function code(t, l, k) tmp = 0.0 if (k <= 2.7e-30) tmp = Float64(2.0 / Float64(Float64(Float64(Float64(k / l) * k) * t) / Float64(Float64(l / k) / k))); else tmp = Float64(2.0 / Float64(k * Float64(Float64(Float64(k * (sin(k) ^ 2.0)) * t) / Float64(Float64(cos(k) * l) * l)))); end return tmp end
function tmp_2 = code(t, l, k) tmp = 0.0; if (k <= 2.7e-30) tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)); else tmp = 2.0 / (k * (((k * (sin(k) ^ 2.0)) * t) / ((cos(k) * l) * l))); end tmp_2 = tmp; end
code[t_, l_, k_] := If[LessEqual[k, 2.7e-30], N[(2.0 / N[(N[(N[(N[(k / l), $MachinePrecision] * k), $MachinePrecision] * t), $MachinePrecision] / N[(N[(l / k), $MachinePrecision] / k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(k * N[(N[(N[(k * N[Power[N[Sin[k], $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision] / N[(N[(N[Cos[k], $MachinePrecision] * l), $MachinePrecision] * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;k \leq 2.7 \cdot 10^{-30}:\\
\;\;\;\;\frac{2}{\frac{\left(\frac{k}{\ell} \cdot k\right) \cdot t}{\frac{\frac{\ell}{k}}{k}}}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{k \cdot \frac{\left(k \cdot {\sin k}^{2}\right) \cdot t}{\left(\cos k \cdot \ell\right) \cdot \ell}}\\
\end{array}
\end{array}
if k < 2.69999999999999987e-30Initial program 34.3%
Taylor expanded in k around 0
*-commutativeN/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
unpow2N/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-pow.f6475.7
Applied rewrites75.7%
Applied rewrites65.1%
Applied rewrites86.2%
if 2.69999999999999987e-30 < k Initial program 26.8%
Taylor expanded in t around 0
unpow2N/A
associate-*l*N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
times-fracN/A
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-cos.f64N/A
*-commutativeN/A
lower-/.f64N/A
Applied rewrites92.4%
Applied rewrites92.3%
Applied rewrites84.8%
(FPCore (t l k) :precision binary64 (if (<= k 2.7e-30) (/ 2.0 (/ (* (* (/ k l) k) t) (/ (/ l k) k))) (* (/ 2.0 (* (* (pow (sin k) 2.0) t) k)) (/ (* (* (cos k) l) l) k))))
double code(double t, double l, double k) {
double tmp;
if (k <= 2.7e-30) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else {
tmp = (2.0 / ((pow(sin(k), 2.0) * t) * k)) * (((cos(k) * l) * l) / k);
}
return tmp;
}
real(8) function code(t, l, k)
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: tmp
if (k <= 2.7d-30) then
tmp = 2.0d0 / ((((k / l) * k) * t) / ((l / k) / k))
else
tmp = (2.0d0 / (((sin(k) ** 2.0d0) * t) * k)) * (((cos(k) * l) * l) / k)
end if
code = tmp
end function
public static double code(double t, double l, double k) {
double tmp;
if (k <= 2.7e-30) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else {
tmp = (2.0 / ((Math.pow(Math.sin(k), 2.0) * t) * k)) * (((Math.cos(k) * l) * l) / k);
}
return tmp;
}
def code(t, l, k): tmp = 0 if k <= 2.7e-30: tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)) else: tmp = (2.0 / ((math.pow(math.sin(k), 2.0) * t) * k)) * (((math.cos(k) * l) * l) / k) return tmp
function code(t, l, k) tmp = 0.0 if (k <= 2.7e-30) tmp = Float64(2.0 / Float64(Float64(Float64(Float64(k / l) * k) * t) / Float64(Float64(l / k) / k))); else tmp = Float64(Float64(2.0 / Float64(Float64((sin(k) ^ 2.0) * t) * k)) * Float64(Float64(Float64(cos(k) * l) * l) / k)); end return tmp end
function tmp_2 = code(t, l, k) tmp = 0.0; if (k <= 2.7e-30) tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)); else tmp = (2.0 / (((sin(k) ^ 2.0) * t) * k)) * (((cos(k) * l) * l) / k); end tmp_2 = tmp; end
code[t_, l_, k_] := If[LessEqual[k, 2.7e-30], N[(2.0 / N[(N[(N[(N[(k / l), $MachinePrecision] * k), $MachinePrecision] * t), $MachinePrecision] / N[(N[(l / k), $MachinePrecision] / k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(2.0 / N[(N[(N[Power[N[Sin[k], $MachinePrecision], 2.0], $MachinePrecision] * t), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision] * N[(N[(N[(N[Cos[k], $MachinePrecision] * l), $MachinePrecision] * l), $MachinePrecision] / k), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;k \leq 2.7 \cdot 10^{-30}:\\
\;\;\;\;\frac{2}{\frac{\left(\frac{k}{\ell} \cdot k\right) \cdot t}{\frac{\frac{\ell}{k}}{k}}}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\left({\sin k}^{2} \cdot t\right) \cdot k} \cdot \frac{\left(\cos k \cdot \ell\right) \cdot \ell}{k}\\
\end{array}
\end{array}
if k < 2.69999999999999987e-30Initial program 34.3%
Taylor expanded in k around 0
*-commutativeN/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
unpow2N/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-pow.f6475.7
Applied rewrites75.7%
Applied rewrites65.1%
Applied rewrites86.2%
if 2.69999999999999987e-30 < k Initial program 26.8%
Taylor expanded in t around 0
unpow2N/A
associate-*l*N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
times-fracN/A
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-cos.f64N/A
*-commutativeN/A
lower-/.f64N/A
Applied rewrites92.4%
Applied rewrites92.2%
Applied rewrites99.1%
Taylor expanded in t around 0
associate-*r/N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
*-commutativeN/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-pow.f64N/A
lower-sin.f64N/A
lower-/.f64N/A
Applied rewrites83.7%
(FPCore (t l k)
:precision binary64
(if (<= k 2.55e-30)
(/ 2.0 (/ (* (* (/ k l) k) t) (/ (/ l k) k)))
(if (<= k 1.6e+141)
(* (* (cos k) 2.0) (/ (* l l) (* t (pow (* (sin k) k) 2.0))))
(/
2.0
(*
t
(* (* (/ t l) (/ t l)) (* (/ k t) (* (/ k t) (* (tan k) (sin k))))))))))
double code(double t, double l, double k) {
double tmp;
if (k <= 2.55e-30) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else if (k <= 1.6e+141) {
tmp = (cos(k) * 2.0) * ((l * l) / (t * pow((sin(k) * k), 2.0)));
} else {
tmp = 2.0 / (t * (((t / l) * (t / l)) * ((k / t) * ((k / t) * (tan(k) * sin(k))))));
}
return tmp;
}
real(8) function code(t, l, k)
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: tmp
if (k <= 2.55d-30) then
tmp = 2.0d0 / ((((k / l) * k) * t) / ((l / k) / k))
else if (k <= 1.6d+141) then
tmp = (cos(k) * 2.0d0) * ((l * l) / (t * ((sin(k) * k) ** 2.0d0)))
else
tmp = 2.0d0 / (t * (((t / l) * (t / l)) * ((k / t) * ((k / t) * (tan(k) * sin(k))))))
end if
code = tmp
end function
public static double code(double t, double l, double k) {
double tmp;
if (k <= 2.55e-30) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else if (k <= 1.6e+141) {
tmp = (Math.cos(k) * 2.0) * ((l * l) / (t * Math.pow((Math.sin(k) * k), 2.0)));
} else {
tmp = 2.0 / (t * (((t / l) * (t / l)) * ((k / t) * ((k / t) * (Math.tan(k) * Math.sin(k))))));
}
return tmp;
}
def code(t, l, k): tmp = 0 if k <= 2.55e-30: tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)) elif k <= 1.6e+141: tmp = (math.cos(k) * 2.0) * ((l * l) / (t * math.pow((math.sin(k) * k), 2.0))) else: tmp = 2.0 / (t * (((t / l) * (t / l)) * ((k / t) * ((k / t) * (math.tan(k) * math.sin(k)))))) return tmp
function code(t, l, k) tmp = 0.0 if (k <= 2.55e-30) tmp = Float64(2.0 / Float64(Float64(Float64(Float64(k / l) * k) * t) / Float64(Float64(l / k) / k))); elseif (k <= 1.6e+141) tmp = Float64(Float64(cos(k) * 2.0) * Float64(Float64(l * l) / Float64(t * (Float64(sin(k) * k) ^ 2.0)))); else tmp = Float64(2.0 / Float64(t * Float64(Float64(Float64(t / l) * Float64(t / l)) * Float64(Float64(k / t) * Float64(Float64(k / t) * Float64(tan(k) * sin(k))))))); end return tmp end
function tmp_2 = code(t, l, k) tmp = 0.0; if (k <= 2.55e-30) tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)); elseif (k <= 1.6e+141) tmp = (cos(k) * 2.0) * ((l * l) / (t * ((sin(k) * k) ^ 2.0))); else tmp = 2.0 / (t * (((t / l) * (t / l)) * ((k / t) * ((k / t) * (tan(k) * sin(k)))))); end tmp_2 = tmp; end
code[t_, l_, k_] := If[LessEqual[k, 2.55e-30], N[(2.0 / N[(N[(N[(N[(k / l), $MachinePrecision] * k), $MachinePrecision] * t), $MachinePrecision] / N[(N[(l / k), $MachinePrecision] / k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 1.6e+141], N[(N[(N[Cos[k], $MachinePrecision] * 2.0), $MachinePrecision] * N[(N[(l * l), $MachinePrecision] / N[(t * N[Power[N[(N[Sin[k], $MachinePrecision] * k), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(t * N[(N[(N[(t / l), $MachinePrecision] * N[(t / l), $MachinePrecision]), $MachinePrecision] * N[(N[(k / t), $MachinePrecision] * N[(N[(k / t), $MachinePrecision] * N[(N[Tan[k], $MachinePrecision] * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;k \leq 2.55 \cdot 10^{-30}:\\
\;\;\;\;\frac{2}{\frac{\left(\frac{k}{\ell} \cdot k\right) \cdot t}{\frac{\frac{\ell}{k}}{k}}}\\
\mathbf{elif}\;k \leq 1.6 \cdot 10^{+141}:\\
\;\;\;\;\left(\cos k \cdot 2\right) \cdot \frac{\ell \cdot \ell}{t \cdot {\left(\sin k \cdot k\right)}^{2}}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{t \cdot \left(\left(\frac{t}{\ell} \cdot \frac{t}{\ell}\right) \cdot \left(\frac{k}{t} \cdot \left(\frac{k}{t} \cdot \left(\tan k \cdot \sin k\right)\right)\right)\right)}\\
\end{array}
\end{array}
if k < 2.54999999999999986e-30Initial program 34.3%
Taylor expanded in k around 0
*-commutativeN/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
unpow2N/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-pow.f6475.7
Applied rewrites75.7%
Applied rewrites65.1%
Applied rewrites86.2%
if 2.54999999999999986e-30 < k < 1.60000000000000009e141Initial program 13.6%
Taylor expanded in t around 0
unpow2N/A
associate-*l*N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
times-fracN/A
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-cos.f64N/A
*-commutativeN/A
lower-/.f64N/A
Applied rewrites93.8%
Taylor expanded in t around 0
associate-*r/N/A
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
lower-cos.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f64N/A
lower-pow.f64N/A
lower-sin.f6486.6
Applied rewrites86.6%
Applied rewrites86.5%
if 1.60000000000000009e141 < k Initial program 43.7%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
associate-*l*N/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*l*N/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites77.3%
lift-*.f64N/A
*-commutativeN/A
lift-pow.f64N/A
unpow2N/A
associate-*l*N/A
lower-*.f64N/A
lower-*.f6477.2
Applied rewrites77.2%
lift-/.f64N/A
lift-*.f64N/A
*-commutativeN/A
associate-/l*N/A
lift-/.f64N/A
lower-*.f6480.0
Applied rewrites80.0%
(FPCore (t l k)
:precision binary64
(if (<= k 0.000135)
(/ 2.0 (/ (* (* (/ k l) k) t) (/ (/ l k) k)))
(if (<= k 1.6e+141)
(*
(/ (* 2.0 (cos k)) (* (* k k) t))
(/ (* l l) (- 0.5 (* 0.5 (cos (+ k k))))))
(/
2.0
(*
t
(* (* (/ t l) (/ t l)) (* (/ k t) (* (/ k t) (* (tan k) (sin k))))))))))
double code(double t, double l, double k) {
double tmp;
if (k <= 0.000135) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else if (k <= 1.6e+141) {
tmp = ((2.0 * cos(k)) / ((k * k) * t)) * ((l * l) / (0.5 - (0.5 * cos((k + k)))));
} else {
tmp = 2.0 / (t * (((t / l) * (t / l)) * ((k / t) * ((k / t) * (tan(k) * sin(k))))));
}
return tmp;
}
real(8) function code(t, l, k)
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: tmp
if (k <= 0.000135d0) then
tmp = 2.0d0 / ((((k / l) * k) * t) / ((l / k) / k))
else if (k <= 1.6d+141) then
tmp = ((2.0d0 * cos(k)) / ((k * k) * t)) * ((l * l) / (0.5d0 - (0.5d0 * cos((k + k)))))
else
tmp = 2.0d0 / (t * (((t / l) * (t / l)) * ((k / t) * ((k / t) * (tan(k) * sin(k))))))
end if
code = tmp
end function
public static double code(double t, double l, double k) {
double tmp;
if (k <= 0.000135) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else if (k <= 1.6e+141) {
tmp = ((2.0 * Math.cos(k)) / ((k * k) * t)) * ((l * l) / (0.5 - (0.5 * Math.cos((k + k)))));
} else {
tmp = 2.0 / (t * (((t / l) * (t / l)) * ((k / t) * ((k / t) * (Math.tan(k) * Math.sin(k))))));
}
return tmp;
}
def code(t, l, k): tmp = 0 if k <= 0.000135: tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)) elif k <= 1.6e+141: tmp = ((2.0 * math.cos(k)) / ((k * k) * t)) * ((l * l) / (0.5 - (0.5 * math.cos((k + k))))) else: tmp = 2.0 / (t * (((t / l) * (t / l)) * ((k / t) * ((k / t) * (math.tan(k) * math.sin(k)))))) return tmp
function code(t, l, k) tmp = 0.0 if (k <= 0.000135) tmp = Float64(2.0 / Float64(Float64(Float64(Float64(k / l) * k) * t) / Float64(Float64(l / k) / k))); elseif (k <= 1.6e+141) tmp = Float64(Float64(Float64(2.0 * cos(k)) / Float64(Float64(k * k) * t)) * Float64(Float64(l * l) / Float64(0.5 - Float64(0.5 * cos(Float64(k + k)))))); else tmp = Float64(2.0 / Float64(t * Float64(Float64(Float64(t / l) * Float64(t / l)) * Float64(Float64(k / t) * Float64(Float64(k / t) * Float64(tan(k) * sin(k))))))); end return tmp end
function tmp_2 = code(t, l, k) tmp = 0.0; if (k <= 0.000135) tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)); elseif (k <= 1.6e+141) tmp = ((2.0 * cos(k)) / ((k * k) * t)) * ((l * l) / (0.5 - (0.5 * cos((k + k))))); else tmp = 2.0 / (t * (((t / l) * (t / l)) * ((k / t) * ((k / t) * (tan(k) * sin(k)))))); end tmp_2 = tmp; end
code[t_, l_, k_] := If[LessEqual[k, 0.000135], N[(2.0 / N[(N[(N[(N[(k / l), $MachinePrecision] * k), $MachinePrecision] * t), $MachinePrecision] / N[(N[(l / k), $MachinePrecision] / k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 1.6e+141], N[(N[(N[(2.0 * N[Cos[k], $MachinePrecision]), $MachinePrecision] / N[(N[(k * k), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision] * N[(N[(l * l), $MachinePrecision] / N[(0.5 - N[(0.5 * N[Cos[N[(k + k), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(t * N[(N[(N[(t / l), $MachinePrecision] * N[(t / l), $MachinePrecision]), $MachinePrecision] * N[(N[(k / t), $MachinePrecision] * N[(N[(k / t), $MachinePrecision] * N[(N[Tan[k], $MachinePrecision] * N[Sin[k], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;k \leq 0.000135:\\
\;\;\;\;\frac{2}{\frac{\left(\frac{k}{\ell} \cdot k\right) \cdot t}{\frac{\frac{\ell}{k}}{k}}}\\
\mathbf{elif}\;k \leq 1.6 \cdot 10^{+141}:\\
\;\;\;\;\frac{2 \cdot \cos k}{\left(k \cdot k\right) \cdot t} \cdot \frac{\ell \cdot \ell}{0.5 - 0.5 \cdot \cos \left(k + k\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{t \cdot \left(\left(\frac{t}{\ell} \cdot \frac{t}{\ell}\right) \cdot \left(\frac{k}{t} \cdot \left(\frac{k}{t} \cdot \left(\tan k \cdot \sin k\right)\right)\right)\right)}\\
\end{array}
\end{array}
if k < 1.35000000000000002e-4Initial program 34.1%
Taylor expanded in k around 0
*-commutativeN/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
unpow2N/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-pow.f6475.8
Applied rewrites75.8%
Applied rewrites65.5%
Applied rewrites86.5%
if 1.35000000000000002e-4 < k < 1.60000000000000009e141Initial program 12.2%
Taylor expanded in t around 0
unpow2N/A
associate-*l*N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
times-fracN/A
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-cos.f64N/A
*-commutativeN/A
lower-/.f64N/A
Applied rewrites93.1%
Taylor expanded in t around 0
associate-*r/N/A
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
lower-cos.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f64N/A
lower-pow.f64N/A
lower-sin.f6485.1
Applied rewrites85.1%
Applied rewrites84.2%
if 1.60000000000000009e141 < k Initial program 43.7%
lift-*.f64N/A
lift-*.f64N/A
associate-*l*N/A
lift-*.f64N/A
associate-*l*N/A
lift-/.f64N/A
lift-pow.f64N/A
cube-multN/A
associate-/l*N/A
associate-*l*N/A
lower-*.f64N/A
lower-*.f64N/A
Applied rewrites77.3%
lift-*.f64N/A
*-commutativeN/A
lift-pow.f64N/A
unpow2N/A
associate-*l*N/A
lower-*.f64N/A
lower-*.f6477.2
Applied rewrites77.2%
lift-/.f64N/A
lift-*.f64N/A
*-commutativeN/A
associate-/l*N/A
lift-/.f64N/A
lower-*.f6480.0
Applied rewrites80.0%
(FPCore (t l k)
:precision binary64
(if (<= k 0.000135)
(/ 2.0 (/ (* (* (/ k l) k) t) (/ (/ l k) k)))
(if (<= k 6.6e+140)
(*
(/ (* 2.0 (cos k)) (* (* k k) t))
(/ (* l l) (- 0.5 (* 0.5 (cos (+ k k))))))
(/ 2.0 (* (/ k l) (/ (* (* (pow (sin k) 2.0) t) k) l))))))
double code(double t, double l, double k) {
double tmp;
if (k <= 0.000135) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else if (k <= 6.6e+140) {
tmp = ((2.0 * cos(k)) / ((k * k) * t)) * ((l * l) / (0.5 - (0.5 * cos((k + k)))));
} else {
tmp = 2.0 / ((k / l) * (((pow(sin(k), 2.0) * t) * k) / l));
}
return tmp;
}
real(8) function code(t, l, k)
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: tmp
if (k <= 0.000135d0) then
tmp = 2.0d0 / ((((k / l) * k) * t) / ((l / k) / k))
else if (k <= 6.6d+140) then
tmp = ((2.0d0 * cos(k)) / ((k * k) * t)) * ((l * l) / (0.5d0 - (0.5d0 * cos((k + k)))))
else
tmp = 2.0d0 / ((k / l) * ((((sin(k) ** 2.0d0) * t) * k) / l))
end if
code = tmp
end function
public static double code(double t, double l, double k) {
double tmp;
if (k <= 0.000135) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else if (k <= 6.6e+140) {
tmp = ((2.0 * Math.cos(k)) / ((k * k) * t)) * ((l * l) / (0.5 - (0.5 * Math.cos((k + k)))));
} else {
tmp = 2.0 / ((k / l) * (((Math.pow(Math.sin(k), 2.0) * t) * k) / l));
}
return tmp;
}
def code(t, l, k): tmp = 0 if k <= 0.000135: tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)) elif k <= 6.6e+140: tmp = ((2.0 * math.cos(k)) / ((k * k) * t)) * ((l * l) / (0.5 - (0.5 * math.cos((k + k))))) else: tmp = 2.0 / ((k / l) * (((math.pow(math.sin(k), 2.0) * t) * k) / l)) return tmp
function code(t, l, k) tmp = 0.0 if (k <= 0.000135) tmp = Float64(2.0 / Float64(Float64(Float64(Float64(k / l) * k) * t) / Float64(Float64(l / k) / k))); elseif (k <= 6.6e+140) tmp = Float64(Float64(Float64(2.0 * cos(k)) / Float64(Float64(k * k) * t)) * Float64(Float64(l * l) / Float64(0.5 - Float64(0.5 * cos(Float64(k + k)))))); else tmp = Float64(2.0 / Float64(Float64(k / l) * Float64(Float64(Float64((sin(k) ^ 2.0) * t) * k) / l))); end return tmp end
function tmp_2 = code(t, l, k) tmp = 0.0; if (k <= 0.000135) tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)); elseif (k <= 6.6e+140) tmp = ((2.0 * cos(k)) / ((k * k) * t)) * ((l * l) / (0.5 - (0.5 * cos((k + k))))); else tmp = 2.0 / ((k / l) * ((((sin(k) ^ 2.0) * t) * k) / l)); end tmp_2 = tmp; end
code[t_, l_, k_] := If[LessEqual[k, 0.000135], N[(2.0 / N[(N[(N[(N[(k / l), $MachinePrecision] * k), $MachinePrecision] * t), $MachinePrecision] / N[(N[(l / k), $MachinePrecision] / k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 6.6e+140], N[(N[(N[(2.0 * N[Cos[k], $MachinePrecision]), $MachinePrecision] / N[(N[(k * k), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision] * N[(N[(l * l), $MachinePrecision] / N[(0.5 - N[(0.5 * N[Cos[N[(k + k), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(k / l), $MachinePrecision] * N[(N[(N[(N[Power[N[Sin[k], $MachinePrecision], 2.0], $MachinePrecision] * t), $MachinePrecision] * k), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;k \leq 0.000135:\\
\;\;\;\;\frac{2}{\frac{\left(\frac{k}{\ell} \cdot k\right) \cdot t}{\frac{\frac{\ell}{k}}{k}}}\\
\mathbf{elif}\;k \leq 6.6 \cdot 10^{+140}:\\
\;\;\;\;\frac{2 \cdot \cos k}{\left(k \cdot k\right) \cdot t} \cdot \frac{\ell \cdot \ell}{0.5 - 0.5 \cdot \cos \left(k + k\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\frac{k}{\ell} \cdot \frac{\left({\sin k}^{2} \cdot t\right) \cdot k}{\ell}}\\
\end{array}
\end{array}
if k < 1.35000000000000002e-4Initial program 34.1%
Taylor expanded in k around 0
*-commutativeN/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
unpow2N/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-pow.f6475.8
Applied rewrites75.8%
Applied rewrites65.5%
Applied rewrites86.5%
if 1.35000000000000002e-4 < k < 6.6000000000000003e140Initial program 12.2%
Taylor expanded in t around 0
unpow2N/A
associate-*l*N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
times-fracN/A
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-cos.f64N/A
*-commutativeN/A
lower-/.f64N/A
Applied rewrites93.1%
Taylor expanded in t around 0
associate-*r/N/A
associate-*r*N/A
*-commutativeN/A
associate-*r*N/A
times-fracN/A
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
lower-cos.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f64N/A
lower-pow.f64N/A
lower-sin.f6485.1
Applied rewrites85.1%
Applied rewrites84.2%
if 6.6000000000000003e140 < k Initial program 43.7%
Taylor expanded in t around 0
unpow2N/A
associate-*l*N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
times-fracN/A
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-cos.f64N/A
*-commutativeN/A
lower-/.f64N/A
Applied rewrites90.6%
Taylor expanded in k around 0
Applied rewrites67.7%
(FPCore (t l k) :precision binary64 (if (<= k 24.0) (/ 2.0 (/ (* (* (/ k l) k) t) (/ (/ l k) k))) (/ 2.0 (* (/ k l) (/ (* (* (pow (sin k) 2.0) t) k) l)))))
double code(double t, double l, double k) {
double tmp;
if (k <= 24.0) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else {
tmp = 2.0 / ((k / l) * (((pow(sin(k), 2.0) * t) * k) / l));
}
return tmp;
}
real(8) function code(t, l, k)
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: k
real(8) :: tmp
if (k <= 24.0d0) then
tmp = 2.0d0 / ((((k / l) * k) * t) / ((l / k) / k))
else
tmp = 2.0d0 / ((k / l) * ((((sin(k) ** 2.0d0) * t) * k) / l))
end if
code = tmp
end function
public static double code(double t, double l, double k) {
double tmp;
if (k <= 24.0) {
tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
} else {
tmp = 2.0 / ((k / l) * (((Math.pow(Math.sin(k), 2.0) * t) * k) / l));
}
return tmp;
}
def code(t, l, k): tmp = 0 if k <= 24.0: tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)) else: tmp = 2.0 / ((k / l) * (((math.pow(math.sin(k), 2.0) * t) * k) / l)) return tmp
function code(t, l, k) tmp = 0.0 if (k <= 24.0) tmp = Float64(2.0 / Float64(Float64(Float64(Float64(k / l) * k) * t) / Float64(Float64(l / k) / k))); else tmp = Float64(2.0 / Float64(Float64(k / l) * Float64(Float64(Float64((sin(k) ^ 2.0) * t) * k) / l))); end return tmp end
function tmp_2 = code(t, l, k) tmp = 0.0; if (k <= 24.0) tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)); else tmp = 2.0 / ((k / l) * ((((sin(k) ^ 2.0) * t) * k) / l)); end tmp_2 = tmp; end
code[t_, l_, k_] := If[LessEqual[k, 24.0], N[(2.0 / N[(N[(N[(N[(k / l), $MachinePrecision] * k), $MachinePrecision] * t), $MachinePrecision] / N[(N[(l / k), $MachinePrecision] / k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 / N[(N[(k / l), $MachinePrecision] * N[(N[(N[(N[Power[N[Sin[k], $MachinePrecision], 2.0], $MachinePrecision] * t), $MachinePrecision] * k), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;k \leq 24:\\
\;\;\;\;\frac{2}{\frac{\left(\frac{k}{\ell} \cdot k\right) \cdot t}{\frac{\frac{\ell}{k}}{k}}}\\
\mathbf{else}:\\
\;\;\;\;\frac{2}{\frac{k}{\ell} \cdot \frac{\left({\sin k}^{2} \cdot t\right) \cdot k}{\ell}}\\
\end{array}
\end{array}
if k < 24Initial program 33.7%
Taylor expanded in k around 0
*-commutativeN/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
unpow2N/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-pow.f6475.8
Applied rewrites75.8%
Applied rewrites65.7%
Applied rewrites86.4%
if 24 < k Initial program 27.8%
Taylor expanded in t around 0
unpow2N/A
associate-*l*N/A
*-commutativeN/A
unpow2N/A
associate-*r*N/A
times-fracN/A
*-commutativeN/A
lower-*.f64N/A
*-commutativeN/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-cos.f64N/A
*-commutativeN/A
lower-/.f64N/A
Applied rewrites91.7%
Taylor expanded in k around 0
Applied rewrites52.1%
(FPCore (t l k) :precision binary64 (/ 2.0 (/ (* (* (/ k l) k) t) (/ (/ l k) k))))
double code(double t, double l, double k) {
return 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
}
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 / ((((k / l) * k) * t) / ((l / k) / k))
end function
public static double code(double t, double l, double k) {
return 2.0 / ((((k / l) * k) * t) / ((l / k) / k));
}
def code(t, l, k): return 2.0 / ((((k / l) * k) * t) / ((l / k) / k))
function code(t, l, k) return Float64(2.0 / Float64(Float64(Float64(Float64(k / l) * k) * t) / Float64(Float64(l / k) / k))) end
function tmp = code(t, l, k) tmp = 2.0 / ((((k / l) * k) * t) / ((l / k) / k)); end
code[t_, l_, k_] := N[(2.0 / N[(N[(N[(N[(k / l), $MachinePrecision] * k), $MachinePrecision] * t), $MachinePrecision] / N[(N[(l / k), $MachinePrecision] / k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{2}{\frac{\left(\frac{k}{\ell} \cdot k\right) \cdot t}{\frac{\frac{\ell}{k}}{k}}}
\end{array}
Initial program 32.3%
Taylor expanded in k around 0
*-commutativeN/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
unpow2N/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-pow.f6468.6
Applied rewrites68.6%
Applied rewrites60.8%
Applied rewrites76.7%
(FPCore (t l k) :precision binary64 (/ 2.0 (* k (* (/ k l) (/ t (/ (/ l k) k))))))
double code(double t, double l, double k) {
return 2.0 / (k * ((k / l) * (t / ((l / k) / k))));
}
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 / (k * ((k / l) * (t / ((l / k) / k))))
end function
public static double code(double t, double l, double k) {
return 2.0 / (k * ((k / l) * (t / ((l / k) / k))));
}
def code(t, l, k): return 2.0 / (k * ((k / l) * (t / ((l / k) / k))))
function code(t, l, k) return Float64(2.0 / Float64(k * Float64(Float64(k / l) * Float64(t / Float64(Float64(l / k) / k))))) end
function tmp = code(t, l, k) tmp = 2.0 / (k * ((k / l) * (t / ((l / k) / k)))); end
code[t_, l_, k_] := N[(2.0 / N[(k * N[(N[(k / l), $MachinePrecision] * N[(t / N[(N[(l / k), $MachinePrecision] / k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{2}{k \cdot \left(\frac{k}{\ell} \cdot \frac{t}{\frac{\frac{\ell}{k}}{k}}\right)}
\end{array}
Initial program 32.3%
Taylor expanded in k around 0
*-commutativeN/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
unpow2N/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-pow.f6468.6
Applied rewrites68.6%
Applied rewrites72.3%
Applied rewrites74.5%
Applied rewrites76.7%
(FPCore (t l k) :precision binary64 (/ 2.0 (* k (* (/ k l) (* k (/ (* k t) l))))))
double code(double t, double l, double k) {
return 2.0 / (k * ((k / l) * (k * ((k * t) / l))));
}
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 / (k * ((k / l) * (k * ((k * t) / l))))
end function
public static double code(double t, double l, double k) {
return 2.0 / (k * ((k / l) * (k * ((k * t) / l))));
}
def code(t, l, k): return 2.0 / (k * ((k / l) * (k * ((k * t) / l))))
function code(t, l, k) return Float64(2.0 / Float64(k * Float64(Float64(k / l) * Float64(k * Float64(Float64(k * t) / l))))) end
function tmp = code(t, l, k) tmp = 2.0 / (k * ((k / l) * (k * ((k * t) / l)))); end
code[t_, l_, k_] := N[(2.0 / N[(k * N[(N[(k / l), $MachinePrecision] * N[(k * N[(N[(k * t), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{2}{k \cdot \left(\frac{k}{\ell} \cdot \left(k \cdot \frac{k \cdot t}{\ell}\right)\right)}
\end{array}
Initial program 32.3%
Taylor expanded in k around 0
*-commutativeN/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
unpow2N/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-pow.f6468.6
Applied rewrites68.6%
Applied rewrites72.3%
Applied rewrites74.5%
Applied rewrites76.7%
(FPCore (t l k) :precision binary64 (/ 2.0 (/ (* (* k k) (* (* k k) t)) (* l l))))
double code(double t, double l, double k) {
return 2.0 / (((k * k) * ((k * k) * t)) / (l * l));
}
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 / (((k * k) * ((k * k) * t)) / (l * l))
end function
public static double code(double t, double l, double k) {
return 2.0 / (((k * k) * ((k * k) * t)) / (l * l));
}
def code(t, l, k): return 2.0 / (((k * k) * ((k * k) * t)) / (l * l))
function code(t, l, k) return Float64(2.0 / Float64(Float64(Float64(k * k) * Float64(Float64(k * k) * t)) / Float64(l * l))) end
function tmp = code(t, l, k) tmp = 2.0 / (((k * k) * ((k * k) * t)) / (l * l)); end
code[t_, l_, k_] := N[(2.0 / N[(N[(N[(k * k), $MachinePrecision] * N[(N[(k * k), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{2}{\frac{\left(k \cdot k\right) \cdot \left(\left(k \cdot k\right) \cdot t\right)}{\ell \cdot \ell}}
\end{array}
Initial program 32.3%
Taylor expanded in k around 0
*-commutativeN/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
unpow2N/A
associate-/r*N/A
lower-/.f64N/A
lower-/.f64N/A
lower-pow.f6468.6
Applied rewrites68.6%
Applied rewrites60.8%
Applied rewrites62.0%
herbie shell --seed 2024315
(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))))