\[2 \cdot \left(\left(x \cdot y + z \cdot t\right) - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)
\]
↓
\[\begin{array}{l}
t_1 := 2 \cdot \left(\left(x \cdot y + z \cdot t\right) - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)\\
\mathbf{if}\;i \leq -5 \cdot 10^{+20}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;i \leq 1.45 \cdot 10^{+50}:\\
\;\;\;\;2 \cdot \left(x \cdot y + \left(z \cdot t - c \cdot \left(i \cdot a + \frac{b \cdot \left(i \cdot \left(c + c\right)\right)}{2}\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\]
(FPCore (x y z t a b c i)
:precision binary64
(* 2.0 (- (+ (* x y) (* z t)) (* (* (+ a (* b c)) c) i))))
↓
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (* 2.0 (- (+ (* x y) (* z t)) (* (* (+ a (* b c)) c) i)))))
(if (<= i -5e+20)
t_1
(if (<= i 1.45e+50)
(*
2.0
(+ (* x y) (- (* z t) (* c (+ (* i a) (/ (* b (* i (+ c c))) 2.0))))))
t_1))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return 2.0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i));
}
↓
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = 2.0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i));
double tmp;
if (i <= -5e+20) {
tmp = t_1;
} else if (i <= 1.45e+50) {
tmp = 2.0 * ((x * y) + ((z * t) - (c * ((i * a) + ((b * (i * (c + c))) / 2.0)))));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
code = 2.0d0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i))
end function
↓
real(8) function code(x, y, z, t, a, b, c, i)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8) :: t_1
real(8) :: tmp
t_1 = 2.0d0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i))
if (i <= (-5d+20)) then
tmp = t_1
else if (i <= 1.45d+50) then
tmp = 2.0d0 * ((x * y) + ((z * t) - (c * ((i * a) + ((b * (i * (c + c))) / 2.0d0)))))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return 2.0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i));
}
↓
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = 2.0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i));
double tmp;
if (i <= -5e+20) {
tmp = t_1;
} else if (i <= 1.45e+50) {
tmp = 2.0 * ((x * y) + ((z * t) - (c * ((i * a) + ((b * (i * (c + c))) / 2.0)))));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i):
return 2.0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i))
↓
def code(x, y, z, t, a, b, c, i):
t_1 = 2.0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i))
tmp = 0
if i <= -5e+20:
tmp = t_1
elif i <= 1.45e+50:
tmp = 2.0 * ((x * y) + ((z * t) - (c * ((i * a) + ((b * (i * (c + c))) / 2.0)))))
else:
tmp = t_1
return tmp
function code(x, y, z, t, a, b, c, i)
return Float64(2.0 * Float64(Float64(Float64(x * y) + Float64(z * t)) - Float64(Float64(Float64(a + Float64(b * c)) * c) * i)))
end
↓
function code(x, y, z, t, a, b, c, i)
t_1 = Float64(2.0 * Float64(Float64(Float64(x * y) + Float64(z * t)) - Float64(Float64(Float64(a + Float64(b * c)) * c) * i)))
tmp = 0.0
if (i <= -5e+20)
tmp = t_1;
elseif (i <= 1.45e+50)
tmp = Float64(2.0 * Float64(Float64(x * y) + Float64(Float64(z * t) - Float64(c * Float64(Float64(i * a) + Float64(Float64(b * Float64(i * Float64(c + c))) / 2.0))))));
else
tmp = t_1;
end
return tmp
end
function tmp = code(x, y, z, t, a, b, c, i)
tmp = 2.0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i));
end
↓
function tmp_2 = code(x, y, z, t, a, b, c, i)
t_1 = 2.0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i));
tmp = 0.0;
if (i <= -5e+20)
tmp = t_1;
elseif (i <= 1.45e+50)
tmp = 2.0 * ((x * y) + ((z * t) - (c * ((i * a) + ((b * (i * (c + c))) / 2.0)))));
else
tmp = t_1;
end
tmp_2 = tmp;
end
herbie shell --seed 2023064
(FPCore (x y z t a b c i)
:name "Diagrams.ThreeD.Shapes:frustum from diagrams-lib-1.3.0.3, A"
:precision binary64
:herbie-target
(* 2.0 (- (+ (* x y) (* z t)) (* (+ a (* b c)) (* c i))))
(* 2.0 (- (+ (* x y) (* z t)) (* (* (+ a (* b c)) c) i))))