
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(+
(-
(+
(+
(-
(* (- (* x y) (* z t)) (- (* a b) (* c i)))
(* (- (* x j) (* z k)) (- (* y0 b) (* y1 i))))
(* (- (* x y2) (* z y3)) (- (* y0 c) (* y1 a))))
(* (- (* t j) (* y k)) (- (* y4 b) (* y5 i))))
(* (- (* t y2) (* y y3)) (- (* y4 c) (* y5 a))))
(* (- (* k y2) (* j y3)) (- (* y4 y1) (* y5 y0)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
return (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)));
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
code = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)))
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
return (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)));
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): return (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)))
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) return Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * y) - Float64(z * t)) * Float64(Float64(a * b) - Float64(c * i))) - Float64(Float64(Float64(x * j) - Float64(z * k)) * Float64(Float64(y0 * b) - Float64(y1 * i)))) + Float64(Float64(Float64(x * y2) - Float64(z * y3)) * Float64(Float64(y0 * c) - Float64(y1 * a)))) + Float64(Float64(Float64(t * j) - Float64(y * k)) * Float64(Float64(y4 * b) - Float64(y5 * i)))) - Float64(Float64(Float64(t * y2) - Float64(y * y3)) * Float64(Float64(y4 * c) - Float64(y5 * a)))) + Float64(Float64(Float64(k * y2) - Float64(j * y3)) * Float64(Float64(y4 * y1) - Float64(y5 * y0)))) end
function tmp = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0))); end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := N[(N[(N[(N[(N[(N[(N[(N[(x * y), $MachinePrecision] - N[(z * t), $MachinePrecision]), $MachinePrecision] * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(x * j), $MachinePrecision] - N[(z * k), $MachinePrecision]), $MachinePrecision] * N[(N[(y0 * b), $MachinePrecision] - N[(y1 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(x * y2), $MachinePrecision] - N[(z * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y0 * c), $MachinePrecision] - N[(y1 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(t * j), $MachinePrecision] - N[(y * k), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * b), $MachinePrecision] - N[(y5 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * c), $MachinePrecision] - N[(y5 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * y1), $MachinePrecision] - N[(y5 * y0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right)
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 36 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(+
(-
(+
(+
(-
(* (- (* x y) (* z t)) (- (* a b) (* c i)))
(* (- (* x j) (* z k)) (- (* y0 b) (* y1 i))))
(* (- (* x y2) (* z y3)) (- (* y0 c) (* y1 a))))
(* (- (* t j) (* y k)) (- (* y4 b) (* y5 i))))
(* (- (* t y2) (* y y3)) (- (* y4 c) (* y5 a))))
(* (- (* k y2) (* j y3)) (- (* y4 y1) (* y5 y0)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
return (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)));
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
code = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)))
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
return (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)));
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): return (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)))
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) return Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * y) - Float64(z * t)) * Float64(Float64(a * b) - Float64(c * i))) - Float64(Float64(Float64(x * j) - Float64(z * k)) * Float64(Float64(y0 * b) - Float64(y1 * i)))) + Float64(Float64(Float64(x * y2) - Float64(z * y3)) * Float64(Float64(y0 * c) - Float64(y1 * a)))) + Float64(Float64(Float64(t * j) - Float64(y * k)) * Float64(Float64(y4 * b) - Float64(y5 * i)))) - Float64(Float64(Float64(t * y2) - Float64(y * y3)) * Float64(Float64(y4 * c) - Float64(y5 * a)))) + Float64(Float64(Float64(k * y2) - Float64(j * y3)) * Float64(Float64(y4 * y1) - Float64(y5 * y0)))) end
function tmp = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0))); end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := N[(N[(N[(N[(N[(N[(N[(N[(x * y), $MachinePrecision] - N[(z * t), $MachinePrecision]), $MachinePrecision] * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(x * j), $MachinePrecision] - N[(z * k), $MachinePrecision]), $MachinePrecision] * N[(N[(y0 * b), $MachinePrecision] - N[(y1 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(x * y2), $MachinePrecision] - N[(z * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y0 * c), $MachinePrecision] - N[(y1 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(t * j), $MachinePrecision] - N[(y * k), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * b), $MachinePrecision] - N[(y5 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * c), $MachinePrecision] - N[(y5 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * y1), $MachinePrecision] - N[(y5 * y0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right)
\end{array}
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(let* ((t_1 (- (* y1 y4) (* y0 y5)))
(t_2 (- (* c y4) (* a y5)))
(t_3 (- (* x y) (* t z)))
(t_4 (- (* c y0) (* a y1)))
(t_5 (- (* a b) (* c i)))
(t_6 (- (* b y4) (* i y5))))
(if (<= z -5.6e+218)
(*
b
(- (fma a t_3 (* y4 (- (* j t) (* k y)))) (* y0 (- (* j x) (* k z)))))
(if (<= z -6.2e+39)
(* (- y3) (- (fma j t_1 (* z t_4)) (* y t_2)))
(if (<= z -6.5e-139)
(* j (fma x (- (* i y1) (* b y0)) (/ (* x (fma y t_5 (* y2 t_4))) j)))
(if (<= z 1.05e-235)
(+
(-
(* a (fma -1.0 (* y1 (- (* x y2) (* y3 z))) (* b t_3)))
(* (- (* t y2) (* y y3)) (- (* y4 c) (* y5 a))))
(* (- (* k y2) (* j y3)) (- (* y4 y1) (* y5 y0))))
(if (<= z 9e-34)
(* y2 (- (fma k t_1 (* x t_4)) (* t t_2)))
(if (<= z 2.9e+79)
(* t (- (fma -1.0 (* z t_5) (* j t_6)) (* y2 t_2)))
(if (<= z 2.5e+186)
(*
k
(+
(fma -1.0 (* y t_6) (* y2 t_1))
(* z (- (* b y0) (* i y1)))))
(* (- z) (fma t t_5 (* y3 t_4))))))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = (y1 * y4) - (y0 * y5);
double t_2 = (c * y4) - (a * y5);
double t_3 = (x * y) - (t * z);
double t_4 = (c * y0) - (a * y1);
double t_5 = (a * b) - (c * i);
double t_6 = (b * y4) - (i * y5);
double tmp;
if (z <= -5.6e+218) {
tmp = b * (fma(a, t_3, (y4 * ((j * t) - (k * y)))) - (y0 * ((j * x) - (k * z))));
} else if (z <= -6.2e+39) {
tmp = -y3 * (fma(j, t_1, (z * t_4)) - (y * t_2));
} else if (z <= -6.5e-139) {
tmp = j * fma(x, ((i * y1) - (b * y0)), ((x * fma(y, t_5, (y2 * t_4))) / j));
} else if (z <= 1.05e-235) {
tmp = ((a * fma(-1.0, (y1 * ((x * y2) - (y3 * z))), (b * t_3))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)));
} else if (z <= 9e-34) {
tmp = y2 * (fma(k, t_1, (x * t_4)) - (t * t_2));
} else if (z <= 2.9e+79) {
tmp = t * (fma(-1.0, (z * t_5), (j * t_6)) - (y2 * t_2));
} else if (z <= 2.5e+186) {
tmp = k * (fma(-1.0, (y * t_6), (y2 * t_1)) + (z * ((b * y0) - (i * y1))));
} else {
tmp = -z * fma(t, t_5, (y3 * t_4));
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = Float64(Float64(y1 * y4) - Float64(y0 * y5)) t_2 = Float64(Float64(c * y4) - Float64(a * y5)) t_3 = Float64(Float64(x * y) - Float64(t * z)) t_4 = Float64(Float64(c * y0) - Float64(a * y1)) t_5 = Float64(Float64(a * b) - Float64(c * i)) t_6 = Float64(Float64(b * y4) - Float64(i * y5)) tmp = 0.0 if (z <= -5.6e+218) tmp = Float64(b * Float64(fma(a, t_3, Float64(y4 * Float64(Float64(j * t) - Float64(k * y)))) - Float64(y0 * Float64(Float64(j * x) - Float64(k * z))))); elseif (z <= -6.2e+39) tmp = Float64(Float64(-y3) * Float64(fma(j, t_1, Float64(z * t_4)) - Float64(y * t_2))); elseif (z <= -6.5e-139) tmp = Float64(j * fma(x, Float64(Float64(i * y1) - Float64(b * y0)), Float64(Float64(x * fma(y, t_5, Float64(y2 * t_4))) / j))); elseif (z <= 1.05e-235) tmp = Float64(Float64(Float64(a * fma(-1.0, Float64(y1 * Float64(Float64(x * y2) - Float64(y3 * z))), Float64(b * t_3))) - Float64(Float64(Float64(t * y2) - Float64(y * y3)) * Float64(Float64(y4 * c) - Float64(y5 * a)))) + Float64(Float64(Float64(k * y2) - Float64(j * y3)) * Float64(Float64(y4 * y1) - Float64(y5 * y0)))); elseif (z <= 9e-34) tmp = Float64(y2 * Float64(fma(k, t_1, Float64(x * t_4)) - Float64(t * t_2))); elseif (z <= 2.9e+79) tmp = Float64(t * Float64(fma(-1.0, Float64(z * t_5), Float64(j * t_6)) - Float64(y2 * t_2))); elseif (z <= 2.5e+186) tmp = Float64(k * Float64(fma(-1.0, Float64(y * t_6), Float64(y2 * t_1)) + Float64(z * Float64(Float64(b * y0) - Float64(i * y1))))); else tmp = Float64(Float64(-z) * fma(t, t_5, Float64(y3 * t_4))); end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(y1 * y4), $MachinePrecision] - N[(y0 * y5), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(c * y4), $MachinePrecision] - N[(a * y5), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(x * y), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$6 = N[(N[(b * y4), $MachinePrecision] - N[(i * y5), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -5.6e+218], N[(b * N[(N[(a * t$95$3 + N[(y4 * N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y0 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -6.2e+39], N[((-y3) * N[(N[(j * t$95$1 + N[(z * t$95$4), $MachinePrecision]), $MachinePrecision] - N[(y * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -6.5e-139], N[(j * N[(x * N[(N[(i * y1), $MachinePrecision] - N[(b * y0), $MachinePrecision]), $MachinePrecision] + N[(N[(x * N[(y * t$95$5 + N[(y2 * t$95$4), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / j), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.05e-235], N[(N[(N[(a * N[(-1.0 * N[(y1 * N[(N[(x * y2), $MachinePrecision] - N[(y3 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(b * t$95$3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * c), $MachinePrecision] - N[(y5 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * y1), $MachinePrecision] - N[(y5 * y0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 9e-34], N[(y2 * N[(N[(k * t$95$1 + N[(x * t$95$4), $MachinePrecision]), $MachinePrecision] - N[(t * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.9e+79], N[(t * N[(N[(-1.0 * N[(z * t$95$5), $MachinePrecision] + N[(j * t$95$6), $MachinePrecision]), $MachinePrecision] - N[(y2 * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.5e+186], N[(k * N[(N[(-1.0 * N[(y * t$95$6), $MachinePrecision] + N[(y2 * t$95$1), $MachinePrecision]), $MachinePrecision] + N[(z * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[((-z) * N[(t * t$95$5 + N[(y3 * t$95$4), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y1 \cdot y4 - y0 \cdot y5\\
t_2 := c \cdot y4 - a \cdot y5\\
t_3 := x \cdot y - t \cdot z\\
t_4 := c \cdot y0 - a \cdot y1\\
t_5 := a \cdot b - c \cdot i\\
t_6 := b \cdot y4 - i \cdot y5\\
\mathbf{if}\;z \leq -5.6 \cdot 10^{+218}:\\
\;\;\;\;b \cdot \left(\mathsf{fma}\left(a, t\_3, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)\\
\mathbf{elif}\;z \leq -6.2 \cdot 10^{+39}:\\
\;\;\;\;\left(-y3\right) \cdot \left(\mathsf{fma}\left(j, t\_1, z \cdot t\_4\right) - y \cdot t\_2\right)\\
\mathbf{elif}\;z \leq -6.5 \cdot 10^{-139}:\\
\;\;\;\;j \cdot \mathsf{fma}\left(x, i \cdot y1 - b \cdot y0, \frac{x \cdot \mathsf{fma}\left(y, t\_5, y2 \cdot t\_4\right)}{j}\right)\\
\mathbf{elif}\;z \leq 1.05 \cdot 10^{-235}:\\
\;\;\;\;\left(a \cdot \mathsf{fma}\left(-1, y1 \cdot \left(x \cdot y2 - y3 \cdot z\right), b \cdot t\_3\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right)\\
\mathbf{elif}\;z \leq 9 \cdot 10^{-34}:\\
\;\;\;\;y2 \cdot \left(\mathsf{fma}\left(k, t\_1, x \cdot t\_4\right) - t \cdot t\_2\right)\\
\mathbf{elif}\;z \leq 2.9 \cdot 10^{+79}:\\
\;\;\;\;t \cdot \left(\mathsf{fma}\left(-1, z \cdot t\_5, j \cdot t\_6\right) - y2 \cdot t\_2\right)\\
\mathbf{elif}\;z \leq 2.5 \cdot 10^{+186}:\\
\;\;\;\;k \cdot \left(\mathsf{fma}\left(-1, y \cdot t\_6, y2 \cdot t\_1\right) + z \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\left(-z\right) \cdot \mathsf{fma}\left(t, t\_5, y3 \cdot t\_4\right)\\
\end{array}
\end{array}
if z < -5.5999999999999997e218Initial program 22.2%
Taylor expanded in b around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites67.1%
if -5.5999999999999997e218 < z < -6.2000000000000005e39Initial program 26.9%
Taylor expanded in y3 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites57.7%
if -6.2000000000000005e39 < z < -6.5e-139Initial program 29.8%
Taylor expanded in x around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites52.1%
Taylor expanded in j around inf
lower-*.f64N/A
lower-fma.f64N/A
lower--.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lower-/.f64N/A
Applied rewrites54.4%
if -6.5e-139 < z < 1.05e-235Initial program 40.5%
Taylor expanded in a around inf
lower-*.f64N/A
lower-fma.f64N/A
lower-*.f64N/A
lower--.f64N/A
lift-*.f64N/A
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lift-*.f64N/A
lower-*.f6459.6
Applied rewrites59.6%
if 1.05e-235 < z < 9.00000000000000085e-34Initial program 27.6%
Taylor expanded in y2 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites57.5%
if 9.00000000000000085e-34 < z < 2.89999999999999992e79Initial program 21.0%
Taylor expanded in t around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites62.6%
if 2.89999999999999992e79 < z < 2.49999999999999977e186Initial program 26.0%
Taylor expanded in k around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites74.4%
if 2.49999999999999977e186 < z Initial program 16.9%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites66.7%
Taylor expanded in k around 0
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f64N/A
lift-fma.f6466.9
Applied rewrites66.9%
Final simplification61.2%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(let* ((t_1 (* (- (* x y2) (* z y3)) (- (* y0 c) (* y1 a))))
(t_2 (- (* t y2) (* y y3)))
(t_3 (* t_2 (- (* y4 c) (* y5 a))))
(t_4 (- (* y1 y4) (* y0 y5)))
(t_5 (- (* k y2) (* j y3)))
(t_6 (- (* b y0) (* i y1)))
(t_7 (* (- (* t j) (* y k)) (- (* y4 b) (* y5 i))))
(t_8 (* t_5 (- (* y4 y1) (* y5 y0))))
(t_9
(+
(-
(+
(+
(-
(* (- (* x y) (* z t)) (- (* a b) (* c i)))
(* (- (* x j) (* z k)) (- (* y0 b) (* y1 i))))
t_1)
t_7)
t_3)
t_8)))
(if (<= t_9 5e+261)
(-
(fma
-1.0
(* a (* y1 (- (* x y2) (* y3 z))))
(fma
a
(* b (- (* x y) (* t z)))
(fma (- (* b y4) (* i y5)) (- (* j t) (* k y)) (* t_5 t_4))))
(fma -1.0 (* a (* y5 t_2)) (* t_6 (- (* j x) (* k z)))))
(if (<= t_9 INFINITY)
(+ (- (+ (+ (* k (* z t_6)) t_1) t_7) t_3) t_8)
(*
y2
(-
(fma k t_4 (* x (- (* c y0) (* a y1))))
(* t (- (* c y4) (* a y5)))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = ((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a));
double t_2 = (t * y2) - (y * y3);
double t_3 = t_2 * ((y4 * c) - (y5 * a));
double t_4 = (y1 * y4) - (y0 * y5);
double t_5 = (k * y2) - (j * y3);
double t_6 = (b * y0) - (i * y1);
double t_7 = ((t * j) - (y * k)) * ((y4 * b) - (y5 * i));
double t_8 = t_5 * ((y4 * y1) - (y5 * y0));
double t_9 = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + t_1) + t_7) - t_3) + t_8;
double tmp;
if (t_9 <= 5e+261) {
tmp = fma(-1.0, (a * (y1 * ((x * y2) - (y3 * z)))), fma(a, (b * ((x * y) - (t * z))), fma(((b * y4) - (i * y5)), ((j * t) - (k * y)), (t_5 * t_4)))) - fma(-1.0, (a * (y5 * t_2)), (t_6 * ((j * x) - (k * z))));
} else if (t_9 <= ((double) INFINITY)) {
tmp = ((((k * (z * t_6)) + t_1) + t_7) - t_3) + t_8;
} else {
tmp = y2 * (fma(k, t_4, (x * ((c * y0) - (a * y1)))) - (t * ((c * y4) - (a * y5))));
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = Float64(Float64(Float64(x * y2) - Float64(z * y3)) * Float64(Float64(y0 * c) - Float64(y1 * a))) t_2 = Float64(Float64(t * y2) - Float64(y * y3)) t_3 = Float64(t_2 * Float64(Float64(y4 * c) - Float64(y5 * a))) t_4 = Float64(Float64(y1 * y4) - Float64(y0 * y5)) t_5 = Float64(Float64(k * y2) - Float64(j * y3)) t_6 = Float64(Float64(b * y0) - Float64(i * y1)) t_7 = Float64(Float64(Float64(t * j) - Float64(y * k)) * Float64(Float64(y4 * b) - Float64(y5 * i))) t_8 = Float64(t_5 * Float64(Float64(y4 * y1) - Float64(y5 * y0))) t_9 = Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * y) - Float64(z * t)) * Float64(Float64(a * b) - Float64(c * i))) - Float64(Float64(Float64(x * j) - Float64(z * k)) * Float64(Float64(y0 * b) - Float64(y1 * i)))) + t_1) + t_7) - t_3) + t_8) tmp = 0.0 if (t_9 <= 5e+261) tmp = Float64(fma(-1.0, Float64(a * Float64(y1 * Float64(Float64(x * y2) - Float64(y3 * z)))), fma(a, Float64(b * Float64(Float64(x * y) - Float64(t * z))), fma(Float64(Float64(b * y4) - Float64(i * y5)), Float64(Float64(j * t) - Float64(k * y)), Float64(t_5 * t_4)))) - fma(-1.0, Float64(a * Float64(y5 * t_2)), Float64(t_6 * Float64(Float64(j * x) - Float64(k * z))))); elseif (t_9 <= Inf) tmp = Float64(Float64(Float64(Float64(Float64(k * Float64(z * t_6)) + t_1) + t_7) - t_3) + t_8); else tmp = Float64(y2 * Float64(fma(k, t_4, Float64(x * Float64(Float64(c * y0) - Float64(a * y1)))) - Float64(t * Float64(Float64(c * y4) - Float64(a * y5))))); end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(N[(x * y2), $MachinePrecision] - N[(z * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y0 * c), $MachinePrecision] - N[(y1 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(t$95$2 * N[(N[(y4 * c), $MachinePrecision] - N[(y5 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(N[(y1 * y4), $MachinePrecision] - N[(y0 * y5), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$6 = N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$7 = N[(N[(N[(t * j), $MachinePrecision] - N[(y * k), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * b), $MachinePrecision] - N[(y5 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$8 = N[(t$95$5 * N[(N[(y4 * y1), $MachinePrecision] - N[(y5 * y0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$9 = N[(N[(N[(N[(N[(N[(N[(N[(x * y), $MachinePrecision] - N[(z * t), $MachinePrecision]), $MachinePrecision] * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(x * j), $MachinePrecision] - N[(z * k), $MachinePrecision]), $MachinePrecision] * N[(N[(y0 * b), $MachinePrecision] - N[(y1 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$1), $MachinePrecision] + t$95$7), $MachinePrecision] - t$95$3), $MachinePrecision] + t$95$8), $MachinePrecision]}, If[LessEqual[t$95$9, 5e+261], N[(N[(-1.0 * N[(a * N[(y1 * N[(N[(x * y2), $MachinePrecision] - N[(y3 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(a * N[(b * N[(N[(x * y), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(b * y4), $MachinePrecision] - N[(i * y5), $MachinePrecision]), $MachinePrecision] * N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision] + N[(t$95$5 * t$95$4), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(-1.0 * N[(a * N[(y5 * t$95$2), $MachinePrecision]), $MachinePrecision] + N[(t$95$6 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$9, Infinity], N[(N[(N[(N[(N[(k * N[(z * t$95$6), $MachinePrecision]), $MachinePrecision] + t$95$1), $MachinePrecision] + t$95$7), $MachinePrecision] - t$95$3), $MachinePrecision] + t$95$8), $MachinePrecision], N[(y2 * N[(N[(k * t$95$4 + N[(x * N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(t * N[(N[(c * y4), $MachinePrecision] - N[(a * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\\
t_2 := t \cdot y2 - y \cdot y3\\
t_3 := t\_2 \cdot \left(y4 \cdot c - y5 \cdot a\right)\\
t_4 := y1 \cdot y4 - y0 \cdot y5\\
t_5 := k \cdot y2 - j \cdot y3\\
t_6 := b \cdot y0 - i \cdot y1\\
t_7 := \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\\
t_8 := t\_5 \cdot \left(y4 \cdot y1 - y5 \cdot y0\right)\\
t_9 := \left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + t\_1\right) + t\_7\right) - t\_3\right) + t\_8\\
\mathbf{if}\;t\_9 \leq 5 \cdot 10^{+261}:\\
\;\;\;\;\mathsf{fma}\left(-1, a \cdot \left(y1 \cdot \left(x \cdot y2 - y3 \cdot z\right)\right), \mathsf{fma}\left(a, b \cdot \left(x \cdot y - t \cdot z\right), \mathsf{fma}\left(b \cdot y4 - i \cdot y5, j \cdot t - k \cdot y, t\_5 \cdot t\_4\right)\right)\right) - \mathsf{fma}\left(-1, a \cdot \left(y5 \cdot t\_2\right), t\_6 \cdot \left(j \cdot x - k \cdot z\right)\right)\\
\mathbf{elif}\;t\_9 \leq \infty:\\
\;\;\;\;\left(\left(\left(k \cdot \left(z \cdot t\_6\right) + t\_1\right) + t\_7\right) - t\_3\right) + t\_8\\
\mathbf{else}:\\
\;\;\;\;y2 \cdot \left(\mathsf{fma}\left(k, t\_4, x \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - t \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\\
\end{array}
\end{array}
if (+.f64 (-.f64 (+.f64 (+.f64 (-.f64 (*.f64 (-.f64 (*.f64 x y) (*.f64 z t)) (-.f64 (*.f64 a b) (*.f64 c i))) (*.f64 (-.f64 (*.f64 x j) (*.f64 z k)) (-.f64 (*.f64 y0 b) (*.f64 y1 i)))) (*.f64 (-.f64 (*.f64 x y2) (*.f64 z y3)) (-.f64 (*.f64 y0 c) (*.f64 y1 a)))) (*.f64 (-.f64 (*.f64 t j) (*.f64 y k)) (-.f64 (*.f64 y4 b) (*.f64 y5 i)))) (*.f64 (-.f64 (*.f64 t y2) (*.f64 y y3)) (-.f64 (*.f64 y4 c) (*.f64 y5 a)))) (*.f64 (-.f64 (*.f64 k y2) (*.f64 j y3)) (-.f64 (*.f64 y4 y1) (*.f64 y5 y0)))) < 5.0000000000000001e261Initial program 90.8%
Taylor expanded in c around 0
Applied rewrites77.9%
if 5.0000000000000001e261 < (+.f64 (-.f64 (+.f64 (+.f64 (-.f64 (*.f64 (-.f64 (*.f64 x y) (*.f64 z t)) (-.f64 (*.f64 a b) (*.f64 c i))) (*.f64 (-.f64 (*.f64 x j) (*.f64 z k)) (-.f64 (*.f64 y0 b) (*.f64 y1 i)))) (*.f64 (-.f64 (*.f64 x y2) (*.f64 z y3)) (-.f64 (*.f64 y0 c) (*.f64 y1 a)))) (*.f64 (-.f64 (*.f64 t j) (*.f64 y k)) (-.f64 (*.f64 y4 b) (*.f64 y5 i)))) (*.f64 (-.f64 (*.f64 t y2) (*.f64 y y3)) (-.f64 (*.f64 y4 c) (*.f64 y5 a)))) (*.f64 (-.f64 (*.f64 k y2) (*.f64 j y3)) (-.f64 (*.f64 y4 y1) (*.f64 y5 y0)))) < +inf.0Initial program 81.3%
Taylor expanded in k around inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6481.2
Applied rewrites81.2%
if +inf.0 < (+.f64 (-.f64 (+.f64 (+.f64 (-.f64 (*.f64 (-.f64 (*.f64 x y) (*.f64 z t)) (-.f64 (*.f64 a b) (*.f64 c i))) (*.f64 (-.f64 (*.f64 x j) (*.f64 z k)) (-.f64 (*.f64 y0 b) (*.f64 y1 i)))) (*.f64 (-.f64 (*.f64 x y2) (*.f64 z y3)) (-.f64 (*.f64 y0 c) (*.f64 y1 a)))) (*.f64 (-.f64 (*.f64 t j) (*.f64 y k)) (-.f64 (*.f64 y4 b) (*.f64 y5 i)))) (*.f64 (-.f64 (*.f64 t y2) (*.f64 y y3)) (-.f64 (*.f64 y4 c) (*.f64 y5 a)))) (*.f64 (-.f64 (*.f64 k y2) (*.f64 j y3)) (-.f64 (*.f64 y4 y1) (*.f64 y5 y0)))) Initial program 0.0%
Taylor expanded in y2 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites41.7%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(let* ((t_1
(+
(-
(+
(+
(-
(* (- (* x y) (* z t)) (- (* a b) (* c i)))
(* (- (* x j) (* z k)) (- (* y0 b) (* y1 i))))
(* (- (* x y2) (* z y3)) (- (* y0 c) (* y1 a))))
(* (- (* t j) (* y k)) (- (* y4 b) (* y5 i))))
(* (- (* t y2) (* y y3)) (- (* y4 c) (* y5 a))))
(* (- (* k y2) (* j y3)) (- (* y4 y1) (* y5 y0))))))
(if (<= t_1 INFINITY)
t_1
(*
y2
(-
(fma k (- (* y1 y4) (* y0 y5)) (* x (- (* c y0) (* a y1))))
(* t (- (* c y4) (* a y5))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)));
double tmp;
if (t_1 <= ((double) INFINITY)) {
tmp = t_1;
} else {
tmp = y2 * (fma(k, ((y1 * y4) - (y0 * y5)), (x * ((c * y0) - (a * y1)))) - (t * ((c * y4) - (a * y5))));
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * y) - Float64(z * t)) * Float64(Float64(a * b) - Float64(c * i))) - Float64(Float64(Float64(x * j) - Float64(z * k)) * Float64(Float64(y0 * b) - Float64(y1 * i)))) + Float64(Float64(Float64(x * y2) - Float64(z * y3)) * Float64(Float64(y0 * c) - Float64(y1 * a)))) + Float64(Float64(Float64(t * j) - Float64(y * k)) * Float64(Float64(y4 * b) - Float64(y5 * i)))) - Float64(Float64(Float64(t * y2) - Float64(y * y3)) * Float64(Float64(y4 * c) - Float64(y5 * a)))) + Float64(Float64(Float64(k * y2) - Float64(j * y3)) * Float64(Float64(y4 * y1) - Float64(y5 * y0)))) tmp = 0.0 if (t_1 <= Inf) tmp = t_1; else tmp = Float64(y2 * Float64(fma(k, Float64(Float64(y1 * y4) - Float64(y0 * y5)), Float64(x * Float64(Float64(c * y0) - Float64(a * y1)))) - Float64(t * Float64(Float64(c * y4) - Float64(a * y5))))); end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(N[(N[(N[(N[(N[(N[(x * y), $MachinePrecision] - N[(z * t), $MachinePrecision]), $MachinePrecision] * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(x * j), $MachinePrecision] - N[(z * k), $MachinePrecision]), $MachinePrecision] * N[(N[(y0 * b), $MachinePrecision] - N[(y1 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(x * y2), $MachinePrecision] - N[(z * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y0 * c), $MachinePrecision] - N[(y1 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(t * j), $MachinePrecision] - N[(y * k), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * b), $MachinePrecision] - N[(y5 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * c), $MachinePrecision] - N[(y5 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * y1), $MachinePrecision] - N[(y5 * y0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, Infinity], t$95$1, N[(y2 * N[(N[(k * N[(N[(y1 * y4), $MachinePrecision] - N[(y0 * y5), $MachinePrecision]), $MachinePrecision] + N[(x * N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(t * N[(N[(c * y4), $MachinePrecision] - N[(a * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right)\\
\mathbf{if}\;t\_1 \leq \infty:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;y2 \cdot \left(\mathsf{fma}\left(k, y1 \cdot y4 - y0 \cdot y5, x \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - t \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\\
\end{array}
\end{array}
if (+.f64 (-.f64 (+.f64 (+.f64 (-.f64 (*.f64 (-.f64 (*.f64 x y) (*.f64 z t)) (-.f64 (*.f64 a b) (*.f64 c i))) (*.f64 (-.f64 (*.f64 x j) (*.f64 z k)) (-.f64 (*.f64 y0 b) (*.f64 y1 i)))) (*.f64 (-.f64 (*.f64 x y2) (*.f64 z y3)) (-.f64 (*.f64 y0 c) (*.f64 y1 a)))) (*.f64 (-.f64 (*.f64 t j) (*.f64 y k)) (-.f64 (*.f64 y4 b) (*.f64 y5 i)))) (*.f64 (-.f64 (*.f64 t y2) (*.f64 y y3)) (-.f64 (*.f64 y4 c) (*.f64 y5 a)))) (*.f64 (-.f64 (*.f64 k y2) (*.f64 j y3)) (-.f64 (*.f64 y4 y1) (*.f64 y5 y0)))) < +inf.0Initial program 86.1%
if +inf.0 < (+.f64 (-.f64 (+.f64 (+.f64 (-.f64 (*.f64 (-.f64 (*.f64 x y) (*.f64 z t)) (-.f64 (*.f64 a b) (*.f64 c i))) (*.f64 (-.f64 (*.f64 x j) (*.f64 z k)) (-.f64 (*.f64 y0 b) (*.f64 y1 i)))) (*.f64 (-.f64 (*.f64 x y2) (*.f64 z y3)) (-.f64 (*.f64 y0 c) (*.f64 y1 a)))) (*.f64 (-.f64 (*.f64 t j) (*.f64 y k)) (-.f64 (*.f64 y4 b) (*.f64 y5 i)))) (*.f64 (-.f64 (*.f64 t y2) (*.f64 y y3)) (-.f64 (*.f64 y4 c) (*.f64 y5 a)))) (*.f64 (-.f64 (*.f64 k y2) (*.f64 j y3)) (-.f64 (*.f64 y4 y1) (*.f64 y5 y0)))) Initial program 0.0%
Taylor expanded in y2 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites41.7%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(let* ((t_1 (* (- (* x y2) (* z y3)) (- (* y0 c) (* y1 a))))
(t_2 (* (- (* t y2) (* y y3)) (- (* y4 c) (* y5 a))))
(t_3 (* (- (* t j) (* y k)) (- (* y4 b) (* y5 i))))
(t_4 (* (- (* k y2) (* j y3)) (- (* y4 y1) (* y5 y0)))))
(if (<=
(+
(-
(+
(+
(-
(* (- (* x y) (* z t)) (- (* a b) (* c i)))
(* (- (* x j) (* z k)) (- (* y0 b) (* y1 i))))
t_1)
t_3)
t_2)
t_4)
INFINITY)
(+ (- (+ (+ (* k (* z (- (* b y0) (* i y1)))) t_1) t_3) t_2) t_4)
(*
y2
(-
(fma k (- (* y1 y4) (* y0 y5)) (* x (- (* c y0) (* a y1))))
(* t (- (* c y4) (* a y5))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = ((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a));
double t_2 = ((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a));
double t_3 = ((t * j) - (y * k)) * ((y4 * b) - (y5 * i));
double t_4 = ((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0));
double tmp;
if (((((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + t_1) + t_3) - t_2) + t_4) <= ((double) INFINITY)) {
tmp = ((((k * (z * ((b * y0) - (i * y1)))) + t_1) + t_3) - t_2) + t_4;
} else {
tmp = y2 * (fma(k, ((y1 * y4) - (y0 * y5)), (x * ((c * y0) - (a * y1)))) - (t * ((c * y4) - (a * y5))));
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = Float64(Float64(Float64(x * y2) - Float64(z * y3)) * Float64(Float64(y0 * c) - Float64(y1 * a))) t_2 = Float64(Float64(Float64(t * y2) - Float64(y * y3)) * Float64(Float64(y4 * c) - Float64(y5 * a))) t_3 = Float64(Float64(Float64(t * j) - Float64(y * k)) * Float64(Float64(y4 * b) - Float64(y5 * i))) t_4 = Float64(Float64(Float64(k * y2) - Float64(j * y3)) * Float64(Float64(y4 * y1) - Float64(y5 * y0))) tmp = 0.0 if (Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * y) - Float64(z * t)) * Float64(Float64(a * b) - Float64(c * i))) - Float64(Float64(Float64(x * j) - Float64(z * k)) * Float64(Float64(y0 * b) - Float64(y1 * i)))) + t_1) + t_3) - t_2) + t_4) <= Inf) tmp = Float64(Float64(Float64(Float64(Float64(k * Float64(z * Float64(Float64(b * y0) - Float64(i * y1)))) + t_1) + t_3) - t_2) + t_4); else tmp = Float64(y2 * Float64(fma(k, Float64(Float64(y1 * y4) - Float64(y0 * y5)), Float64(x * Float64(Float64(c * y0) - Float64(a * y1)))) - Float64(t * Float64(Float64(c * y4) - Float64(a * y5))))); end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(N[(x * y2), $MachinePrecision] - N[(z * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y0 * c), $MachinePrecision] - N[(y1 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * c), $MachinePrecision] - N[(y5 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(N[(t * j), $MachinePrecision] - N[(y * k), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * b), $MachinePrecision] - N[(y5 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * y1), $MachinePrecision] - N[(y5 * y0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(N[(N[(N[(N[(N[(N[(N[(x * y), $MachinePrecision] - N[(z * t), $MachinePrecision]), $MachinePrecision] * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(x * j), $MachinePrecision] - N[(z * k), $MachinePrecision]), $MachinePrecision] * N[(N[(y0 * b), $MachinePrecision] - N[(y1 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$1), $MachinePrecision] + t$95$3), $MachinePrecision] - t$95$2), $MachinePrecision] + t$95$4), $MachinePrecision], Infinity], N[(N[(N[(N[(N[(k * N[(z * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$1), $MachinePrecision] + t$95$3), $MachinePrecision] - t$95$2), $MachinePrecision] + t$95$4), $MachinePrecision], N[(y2 * N[(N[(k * N[(N[(y1 * y4), $MachinePrecision] - N[(y0 * y5), $MachinePrecision]), $MachinePrecision] + N[(x * N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(t * N[(N[(c * y4), $MachinePrecision] - N[(a * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\\
t_2 := \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\\
t_3 := \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\\
t_4 := \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right)\\
\mathbf{if}\;\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + t\_1\right) + t\_3\right) - t\_2\right) + t\_4 \leq \infty:\\
\;\;\;\;\left(\left(\left(k \cdot \left(z \cdot \left(b \cdot y0 - i \cdot y1\right)\right) + t\_1\right) + t\_3\right) - t\_2\right) + t\_4\\
\mathbf{else}:\\
\;\;\;\;y2 \cdot \left(\mathsf{fma}\left(k, y1 \cdot y4 - y0 \cdot y5, x \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - t \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\\
\end{array}
\end{array}
if (+.f64 (-.f64 (+.f64 (+.f64 (-.f64 (*.f64 (-.f64 (*.f64 x y) (*.f64 z t)) (-.f64 (*.f64 a b) (*.f64 c i))) (*.f64 (-.f64 (*.f64 x j) (*.f64 z k)) (-.f64 (*.f64 y0 b) (*.f64 y1 i)))) (*.f64 (-.f64 (*.f64 x y2) (*.f64 z y3)) (-.f64 (*.f64 y0 c) (*.f64 y1 a)))) (*.f64 (-.f64 (*.f64 t j) (*.f64 y k)) (-.f64 (*.f64 y4 b) (*.f64 y5 i)))) (*.f64 (-.f64 (*.f64 t y2) (*.f64 y y3)) (-.f64 (*.f64 y4 c) (*.f64 y5 a)))) (*.f64 (-.f64 (*.f64 k y2) (*.f64 j y3)) (-.f64 (*.f64 y4 y1) (*.f64 y5 y0)))) < +inf.0Initial program 86.1%
Taylor expanded in k around inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6473.3
Applied rewrites73.3%
if +inf.0 < (+.f64 (-.f64 (+.f64 (+.f64 (-.f64 (*.f64 (-.f64 (*.f64 x y) (*.f64 z t)) (-.f64 (*.f64 a b) (*.f64 c i))) (*.f64 (-.f64 (*.f64 x j) (*.f64 z k)) (-.f64 (*.f64 y0 b) (*.f64 y1 i)))) (*.f64 (-.f64 (*.f64 x y2) (*.f64 z y3)) (-.f64 (*.f64 y0 c) (*.f64 y1 a)))) (*.f64 (-.f64 (*.f64 t j) (*.f64 y k)) (-.f64 (*.f64 y4 b) (*.f64 y5 i)))) (*.f64 (-.f64 (*.f64 t y2) (*.f64 y y3)) (-.f64 (*.f64 y4 c) (*.f64 y5 a)))) (*.f64 (-.f64 (*.f64 k y2) (*.f64 j y3)) (-.f64 (*.f64 y4 y1) (*.f64 y5 y0)))) Initial program 0.0%
Taylor expanded in y2 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites41.7%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(let* ((t_1 (- (* x y2) (* y3 z)))
(t_2 (- (* x y) (* t z)))
(t_3 (- (* j x) (* k z)))
(t_4 (* b (- (fma a t_2 (* y4 (- (* j t) (* k y)))) (* y0 t_3))))
(t_5 (- (* k y2) (* j y3))))
(if (<= b -2.5e+113)
t_4
(if (<= b -2.4e+69)
(* c (- (fma -1.0 (* i t_2) (* y0 t_1)) (* y4 (- (* t y2) (* y y3)))))
(if (<= b -5e-128)
(* (- z) (fma t (- (* a b) (* c i)) (* y3 (- (* c y0) (* a y1)))))
(if (<= b -1.15e-304)
(*
k
(+
(fma
-1.0
(* y (- (* b y4) (* i y5)))
(* y2 (- (* y1 y4) (* y0 y5))))
(* z (- (* b y0) (* i y1)))))
(if (<= b 8.4e-187)
(* y1 (+ (fma -1.0 (* a t_1) (* y4 t_5)) (* i t_3)))
(if (<= b 4.8e+94)
(* y0 (- (fma -1.0 (* y5 t_5) (* c t_1)) (* b t_3)))
t_4))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = (x * y2) - (y3 * z);
double t_2 = (x * y) - (t * z);
double t_3 = (j * x) - (k * z);
double t_4 = b * (fma(a, t_2, (y4 * ((j * t) - (k * y)))) - (y0 * t_3));
double t_5 = (k * y2) - (j * y3);
double tmp;
if (b <= -2.5e+113) {
tmp = t_4;
} else if (b <= -2.4e+69) {
tmp = c * (fma(-1.0, (i * t_2), (y0 * t_1)) - (y4 * ((t * y2) - (y * y3))));
} else if (b <= -5e-128) {
tmp = -z * fma(t, ((a * b) - (c * i)), (y3 * ((c * y0) - (a * y1))));
} else if (b <= -1.15e-304) {
tmp = k * (fma(-1.0, (y * ((b * y4) - (i * y5))), (y2 * ((y1 * y4) - (y0 * y5)))) + (z * ((b * y0) - (i * y1))));
} else if (b <= 8.4e-187) {
tmp = y1 * (fma(-1.0, (a * t_1), (y4 * t_5)) + (i * t_3));
} else if (b <= 4.8e+94) {
tmp = y0 * (fma(-1.0, (y5 * t_5), (c * t_1)) - (b * t_3));
} else {
tmp = t_4;
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = Float64(Float64(x * y2) - Float64(y3 * z)) t_2 = Float64(Float64(x * y) - Float64(t * z)) t_3 = Float64(Float64(j * x) - Float64(k * z)) t_4 = Float64(b * Float64(fma(a, t_2, Float64(y4 * Float64(Float64(j * t) - Float64(k * y)))) - Float64(y0 * t_3))) t_5 = Float64(Float64(k * y2) - Float64(j * y3)) tmp = 0.0 if (b <= -2.5e+113) tmp = t_4; elseif (b <= -2.4e+69) tmp = Float64(c * Float64(fma(-1.0, Float64(i * t_2), Float64(y0 * t_1)) - Float64(y4 * Float64(Float64(t * y2) - Float64(y * y3))))); elseif (b <= -5e-128) tmp = Float64(Float64(-z) * fma(t, Float64(Float64(a * b) - Float64(c * i)), Float64(y3 * Float64(Float64(c * y0) - Float64(a * y1))))); elseif (b <= -1.15e-304) tmp = Float64(k * Float64(fma(-1.0, Float64(y * Float64(Float64(b * y4) - Float64(i * y5))), Float64(y2 * Float64(Float64(y1 * y4) - Float64(y0 * y5)))) + Float64(z * Float64(Float64(b * y0) - Float64(i * y1))))); elseif (b <= 8.4e-187) tmp = Float64(y1 * Float64(fma(-1.0, Float64(a * t_1), Float64(y4 * t_5)) + Float64(i * t_3))); elseif (b <= 4.8e+94) tmp = Float64(y0 * Float64(fma(-1.0, Float64(y5 * t_5), Float64(c * t_1)) - Float64(b * t_3))); else tmp = t_4; end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(x * y2), $MachinePrecision] - N[(y3 * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x * y), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(b * N[(N[(a * t$95$2 + N[(y4 * N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y0 * t$95$3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -2.5e+113], t$95$4, If[LessEqual[b, -2.4e+69], N[(c * N[(N[(-1.0 * N[(i * t$95$2), $MachinePrecision] + N[(y0 * t$95$1), $MachinePrecision]), $MachinePrecision] - N[(y4 * N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, -5e-128], N[((-z) * N[(t * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision] + N[(y3 * N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, -1.15e-304], N[(k * N[(N[(-1.0 * N[(y * N[(N[(b * y4), $MachinePrecision] - N[(i * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(y2 * N[(N[(y1 * y4), $MachinePrecision] - N[(y0 * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(z * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 8.4e-187], N[(y1 * N[(N[(-1.0 * N[(a * t$95$1), $MachinePrecision] + N[(y4 * t$95$5), $MachinePrecision]), $MachinePrecision] + N[(i * t$95$3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 4.8e+94], N[(y0 * N[(N[(-1.0 * N[(y5 * t$95$5), $MachinePrecision] + N[(c * t$95$1), $MachinePrecision]), $MachinePrecision] - N[(b * t$95$3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$4]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot y2 - y3 \cdot z\\
t_2 := x \cdot y - t \cdot z\\
t_3 := j \cdot x - k \cdot z\\
t_4 := b \cdot \left(\mathsf{fma}\left(a, t\_2, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot t\_3\right)\\
t_5 := k \cdot y2 - j \cdot y3\\
\mathbf{if}\;b \leq -2.5 \cdot 10^{+113}:\\
\;\;\;\;t\_4\\
\mathbf{elif}\;b \leq -2.4 \cdot 10^{+69}:\\
\;\;\;\;c \cdot \left(\mathsf{fma}\left(-1, i \cdot t\_2, y0 \cdot t\_1\right) - y4 \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\\
\mathbf{elif}\;b \leq -5 \cdot 10^{-128}:\\
\;\;\;\;\left(-z\right) \cdot \mathsf{fma}\left(t, a \cdot b - c \cdot i, y3 \cdot \left(c \cdot y0 - a \cdot y1\right)\right)\\
\mathbf{elif}\;b \leq -1.15 \cdot 10^{-304}:\\
\;\;\;\;k \cdot \left(\mathsf{fma}\left(-1, y \cdot \left(b \cdot y4 - i \cdot y5\right), y2 \cdot \left(y1 \cdot y4 - y0 \cdot y5\right)\right) + z \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\
\mathbf{elif}\;b \leq 8.4 \cdot 10^{-187}:\\
\;\;\;\;y1 \cdot \left(\mathsf{fma}\left(-1, a \cdot t\_1, y4 \cdot t\_5\right) + i \cdot t\_3\right)\\
\mathbf{elif}\;b \leq 4.8 \cdot 10^{+94}:\\
\;\;\;\;y0 \cdot \left(\mathsf{fma}\left(-1, y5 \cdot t\_5, c \cdot t\_1\right) - b \cdot t\_3\right)\\
\mathbf{else}:\\
\;\;\;\;t\_4\\
\end{array}
\end{array}
if b < -2.5e113 or 4.79999999999999965e94 < b Initial program 25.8%
Taylor expanded in b around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites60.0%
if -2.5e113 < b < -2.4000000000000002e69Initial program 12.7%
Taylor expanded in c around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites68.7%
if -2.4000000000000002e69 < b < -5.0000000000000001e-128Initial program 34.1%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites44.1%
Taylor expanded in k around 0
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f64N/A
lift-fma.f6450.7
Applied rewrites50.7%
if -5.0000000000000001e-128 < b < -1.15e-304Initial program 28.2%
Taylor expanded in k around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites70.2%
if -1.15e-304 < b < 8.3999999999999997e-187Initial program 32.9%
Taylor expanded in y1 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites56.7%
if 8.3999999999999997e-187 < b < 4.79999999999999965e94Initial program 26.5%
Taylor expanded in y0 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites57.0%
Final simplification59.4%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(let* ((t_1 (- (* a b) (* c i)))
(t_2 (- (* j t) (* k y)))
(t_3
(*
(- y5)
(-
(fma i t_2 (* y0 (- (* k y2) (* j y3))))
(* a (- (* t y2) (* y y3))))))
(t_4
(*
b
(-
(fma a (- (* x y) (* t z)) (* y4 t_2))
(* y0 (- (* j x) (* k z))))))
(t_5 (- (* c y0) (* a y1))))
(if (<= y5 -7.5e+136)
t_3
(if (<= y5 -1.15e-107)
(*
t
(-
(fma -1.0 (* z t_1) (* j (- (* b y4) (* i y5))))
(* y2 (- (* c y4) (* a y5)))))
(if (<= y5 -2.2e-277)
t_4
(if (<= y5 2e-197)
(- (fma k (* z (- (* i y1) (* b y0))) (* z (fma t t_1 (* y3 t_5)))))
(if (<= y5 2.7e+52)
t_4
(if (<= y5 5e+80) (* x (* y2 t_5)) t_3))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = (a * b) - (c * i);
double t_2 = (j * t) - (k * y);
double t_3 = -y5 * (fma(i, t_2, (y0 * ((k * y2) - (j * y3)))) - (a * ((t * y2) - (y * y3))));
double t_4 = b * (fma(a, ((x * y) - (t * z)), (y4 * t_2)) - (y0 * ((j * x) - (k * z))));
double t_5 = (c * y0) - (a * y1);
double tmp;
if (y5 <= -7.5e+136) {
tmp = t_3;
} else if (y5 <= -1.15e-107) {
tmp = t * (fma(-1.0, (z * t_1), (j * ((b * y4) - (i * y5)))) - (y2 * ((c * y4) - (a * y5))));
} else if (y5 <= -2.2e-277) {
tmp = t_4;
} else if (y5 <= 2e-197) {
tmp = -fma(k, (z * ((i * y1) - (b * y0))), (z * fma(t, t_1, (y3 * t_5))));
} else if (y5 <= 2.7e+52) {
tmp = t_4;
} else if (y5 <= 5e+80) {
tmp = x * (y2 * t_5);
} else {
tmp = t_3;
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = Float64(Float64(a * b) - Float64(c * i)) t_2 = Float64(Float64(j * t) - Float64(k * y)) t_3 = Float64(Float64(-y5) * Float64(fma(i, t_2, Float64(y0 * Float64(Float64(k * y2) - Float64(j * y3)))) - Float64(a * Float64(Float64(t * y2) - Float64(y * y3))))) t_4 = Float64(b * Float64(fma(a, Float64(Float64(x * y) - Float64(t * z)), Float64(y4 * t_2)) - Float64(y0 * Float64(Float64(j * x) - Float64(k * z))))) t_5 = Float64(Float64(c * y0) - Float64(a * y1)) tmp = 0.0 if (y5 <= -7.5e+136) tmp = t_3; elseif (y5 <= -1.15e-107) tmp = Float64(t * Float64(fma(-1.0, Float64(z * t_1), Float64(j * Float64(Float64(b * y4) - Float64(i * y5)))) - Float64(y2 * Float64(Float64(c * y4) - Float64(a * y5))))); elseif (y5 <= -2.2e-277) tmp = t_4; elseif (y5 <= 2e-197) tmp = Float64(-fma(k, Float64(z * Float64(Float64(i * y1) - Float64(b * y0))), Float64(z * fma(t, t_1, Float64(y3 * t_5))))); elseif (y5 <= 2.7e+52) tmp = t_4; elseif (y5 <= 5e+80) tmp = Float64(x * Float64(y2 * t_5)); else tmp = t_3; end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[((-y5) * N[(N[(i * t$95$2 + N[(y0 * N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(b * N[(N[(a * N[(N[(x * y), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision] + N[(y4 * t$95$2), $MachinePrecision]), $MachinePrecision] - N[(y0 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y5, -7.5e+136], t$95$3, If[LessEqual[y5, -1.15e-107], N[(t * N[(N[(-1.0 * N[(z * t$95$1), $MachinePrecision] + N[(j * N[(N[(b * y4), $MachinePrecision] - N[(i * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y2 * N[(N[(c * y4), $MachinePrecision] - N[(a * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y5, -2.2e-277], t$95$4, If[LessEqual[y5, 2e-197], (-N[(k * N[(z * N[(N[(i * y1), $MachinePrecision] - N[(b * y0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(z * N[(t * t$95$1 + N[(y3 * t$95$5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), If[LessEqual[y5, 2.7e+52], t$95$4, If[LessEqual[y5, 5e+80], N[(x * N[(y2 * t$95$5), $MachinePrecision]), $MachinePrecision], t$95$3]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := a \cdot b - c \cdot i\\
t_2 := j \cdot t - k \cdot y\\
t_3 := \left(-y5\right) \cdot \left(\mathsf{fma}\left(i, t\_2, y0 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - a \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\\
t_4 := b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot t\_2\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)\\
t_5 := c \cdot y0 - a \cdot y1\\
\mathbf{if}\;y5 \leq -7.5 \cdot 10^{+136}:\\
\;\;\;\;t\_3\\
\mathbf{elif}\;y5 \leq -1.15 \cdot 10^{-107}:\\
\;\;\;\;t \cdot \left(\mathsf{fma}\left(-1, z \cdot t\_1, j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\\
\mathbf{elif}\;y5 \leq -2.2 \cdot 10^{-277}:\\
\;\;\;\;t\_4\\
\mathbf{elif}\;y5 \leq 2 \cdot 10^{-197}:\\
\;\;\;\;-\mathsf{fma}\left(k, z \cdot \left(i \cdot y1 - b \cdot y0\right), z \cdot \mathsf{fma}\left(t, t\_1, y3 \cdot t\_5\right)\right)\\
\mathbf{elif}\;y5 \leq 2.7 \cdot 10^{+52}:\\
\;\;\;\;t\_4\\
\mathbf{elif}\;y5 \leq 5 \cdot 10^{+80}:\\
\;\;\;\;x \cdot \left(y2 \cdot t\_5\right)\\
\mathbf{else}:\\
\;\;\;\;t\_3\\
\end{array}
\end{array}
if y5 < -7.5000000000000002e136 or 4.99999999999999961e80 < y5 Initial program 28.4%
Taylor expanded in y5 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites70.6%
if -7.5000000000000002e136 < y5 < -1.15000000000000002e-107Initial program 21.2%
Taylor expanded in t around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites46.7%
if -1.15000000000000002e-107 < y5 < -2.19999999999999996e-277 or 2e-197 < y5 < 2.7e52Initial program 31.6%
Taylor expanded in b around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites53.4%
if -2.19999999999999996e-277 < y5 < 2e-197Initial program 33.1%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites56.3%
Taylor expanded in k around 0
lower-fma.f64N/A
lower-*.f64N/A
lower--.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f64N/A
lift-*.f64N/A
Applied rewrites59.4%
if 2.7e52 < y5 < 4.99999999999999961e80Initial program 8.3%
Taylor expanded in y2 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites50.0%
Taylor expanded in x around inf
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f6466.9
Applied rewrites66.9%
Final simplification58.7%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(let* ((t_1 (- (* a b) (* c i)))
(t_2 (- (* j t) (* k y)))
(t_3
(*
(- y5)
(-
(fma i t_2 (* y0 (- (* k y2) (* j y3))))
(* a (- (* t y2) (* y y3))))))
(t_4
(*
b
(-
(fma a (- (* x y) (* t z)) (* y4 t_2))
(* y0 (- (* j x) (* k z))))))
(t_5 (- (* c y0) (* a y1))))
(if (<= y5 -7.5e+136)
t_3
(if (<= y5 -1.15e-107)
(*
t
(-
(fma -1.0 (* z t_1) (* j (- (* b y4) (* i y5))))
(* y2 (- (* c y4) (* a y5)))))
(if (<= y5 -1.15e-226)
t_4
(if (<= y5 2e-197)
(* (- z) (- (fma t t_1 (* y3 t_5)) (* k (- (* b y0) (* i y1)))))
(if (<= y5 2.7e+52)
t_4
(if (<= y5 5e+80) (* x (* y2 t_5)) t_3))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = (a * b) - (c * i);
double t_2 = (j * t) - (k * y);
double t_3 = -y5 * (fma(i, t_2, (y0 * ((k * y2) - (j * y3)))) - (a * ((t * y2) - (y * y3))));
double t_4 = b * (fma(a, ((x * y) - (t * z)), (y4 * t_2)) - (y0 * ((j * x) - (k * z))));
double t_5 = (c * y0) - (a * y1);
double tmp;
if (y5 <= -7.5e+136) {
tmp = t_3;
} else if (y5 <= -1.15e-107) {
tmp = t * (fma(-1.0, (z * t_1), (j * ((b * y4) - (i * y5)))) - (y2 * ((c * y4) - (a * y5))));
} else if (y5 <= -1.15e-226) {
tmp = t_4;
} else if (y5 <= 2e-197) {
tmp = -z * (fma(t, t_1, (y3 * t_5)) - (k * ((b * y0) - (i * y1))));
} else if (y5 <= 2.7e+52) {
tmp = t_4;
} else if (y5 <= 5e+80) {
tmp = x * (y2 * t_5);
} else {
tmp = t_3;
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = Float64(Float64(a * b) - Float64(c * i)) t_2 = Float64(Float64(j * t) - Float64(k * y)) t_3 = Float64(Float64(-y5) * Float64(fma(i, t_2, Float64(y0 * Float64(Float64(k * y2) - Float64(j * y3)))) - Float64(a * Float64(Float64(t * y2) - Float64(y * y3))))) t_4 = Float64(b * Float64(fma(a, Float64(Float64(x * y) - Float64(t * z)), Float64(y4 * t_2)) - Float64(y0 * Float64(Float64(j * x) - Float64(k * z))))) t_5 = Float64(Float64(c * y0) - Float64(a * y1)) tmp = 0.0 if (y5 <= -7.5e+136) tmp = t_3; elseif (y5 <= -1.15e-107) tmp = Float64(t * Float64(fma(-1.0, Float64(z * t_1), Float64(j * Float64(Float64(b * y4) - Float64(i * y5)))) - Float64(y2 * Float64(Float64(c * y4) - Float64(a * y5))))); elseif (y5 <= -1.15e-226) tmp = t_4; elseif (y5 <= 2e-197) tmp = Float64(Float64(-z) * Float64(fma(t, t_1, Float64(y3 * t_5)) - Float64(k * Float64(Float64(b * y0) - Float64(i * y1))))); elseif (y5 <= 2.7e+52) tmp = t_4; elseif (y5 <= 5e+80) tmp = Float64(x * Float64(y2 * t_5)); else tmp = t_3; end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[((-y5) * N[(N[(i * t$95$2 + N[(y0 * N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(b * N[(N[(a * N[(N[(x * y), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision] + N[(y4 * t$95$2), $MachinePrecision]), $MachinePrecision] - N[(y0 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y5, -7.5e+136], t$95$3, If[LessEqual[y5, -1.15e-107], N[(t * N[(N[(-1.0 * N[(z * t$95$1), $MachinePrecision] + N[(j * N[(N[(b * y4), $MachinePrecision] - N[(i * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y2 * N[(N[(c * y4), $MachinePrecision] - N[(a * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y5, -1.15e-226], t$95$4, If[LessEqual[y5, 2e-197], N[((-z) * N[(N[(t * t$95$1 + N[(y3 * t$95$5), $MachinePrecision]), $MachinePrecision] - N[(k * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y5, 2.7e+52], t$95$4, If[LessEqual[y5, 5e+80], N[(x * N[(y2 * t$95$5), $MachinePrecision]), $MachinePrecision], t$95$3]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := a \cdot b - c \cdot i\\
t_2 := j \cdot t - k \cdot y\\
t_3 := \left(-y5\right) \cdot \left(\mathsf{fma}\left(i, t\_2, y0 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - a \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\\
t_4 := b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot t\_2\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)\\
t_5 := c \cdot y0 - a \cdot y1\\
\mathbf{if}\;y5 \leq -7.5 \cdot 10^{+136}:\\
\;\;\;\;t\_3\\
\mathbf{elif}\;y5 \leq -1.15 \cdot 10^{-107}:\\
\;\;\;\;t \cdot \left(\mathsf{fma}\left(-1, z \cdot t\_1, j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\\
\mathbf{elif}\;y5 \leq -1.15 \cdot 10^{-226}:\\
\;\;\;\;t\_4\\
\mathbf{elif}\;y5 \leq 2 \cdot 10^{-197}:\\
\;\;\;\;\left(-z\right) \cdot \left(\mathsf{fma}\left(t, t\_1, y3 \cdot t\_5\right) - k \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\
\mathbf{elif}\;y5 \leq 2.7 \cdot 10^{+52}:\\
\;\;\;\;t\_4\\
\mathbf{elif}\;y5 \leq 5 \cdot 10^{+80}:\\
\;\;\;\;x \cdot \left(y2 \cdot t\_5\right)\\
\mathbf{else}:\\
\;\;\;\;t\_3\\
\end{array}
\end{array}
if y5 < -7.5000000000000002e136 or 4.99999999999999961e80 < y5 Initial program 28.4%
Taylor expanded in y5 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites70.6%
if -7.5000000000000002e136 < y5 < -1.15000000000000002e-107Initial program 21.2%
Taylor expanded in t around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites46.7%
if -1.15000000000000002e-107 < y5 < -1.15e-226 or 2e-197 < y5 < 2.7e52Initial program 28.3%
Taylor expanded in b around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites56.2%
if -1.15e-226 < y5 < 2e-197Initial program 39.1%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites52.6%
if 2.7e52 < y5 < 4.99999999999999961e80Initial program 8.3%
Taylor expanded in y2 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites50.0%
Taylor expanded in x around inf
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f6466.9
Applied rewrites66.9%
Final simplification58.6%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(let* ((t_1 (- (* x y2) (* y3 z)))
(t_2 (- (* x y) (* t z)))
(t_3 (- (* j x) (* k z)))
(t_4 (* b (- (fma a t_2 (* y4 (- (* j t) (* k y)))) (* y0 t_3)))))
(if (<= b -2.5e+113)
t_4
(if (<= b -2.4e+69)
(* c (- (fma -1.0 (* i t_2) (* y0 t_1)) (* y4 (- (* t y2) (* y y3)))))
(if (<= b -5e-128)
(* (- z) (fma t (- (* a b) (* c i)) (* y3 (- (* c y0) (* a y1)))))
(if (<= b 5.9e-95)
(*
k
(+
(fma
-1.0
(* y (- (* b y4) (* i y5)))
(* y2 (- (* y1 y4) (* y0 y5))))
(* z (- (* b y0) (* i y1)))))
(if (<= b 4.8e+94)
(*
y0
(- (fma -1.0 (* y5 (- (* k y2) (* j y3))) (* c t_1)) (* b t_3)))
t_4)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = (x * y2) - (y3 * z);
double t_2 = (x * y) - (t * z);
double t_3 = (j * x) - (k * z);
double t_4 = b * (fma(a, t_2, (y4 * ((j * t) - (k * y)))) - (y0 * t_3));
double tmp;
if (b <= -2.5e+113) {
tmp = t_4;
} else if (b <= -2.4e+69) {
tmp = c * (fma(-1.0, (i * t_2), (y0 * t_1)) - (y4 * ((t * y2) - (y * y3))));
} else if (b <= -5e-128) {
tmp = -z * fma(t, ((a * b) - (c * i)), (y3 * ((c * y0) - (a * y1))));
} else if (b <= 5.9e-95) {
tmp = k * (fma(-1.0, (y * ((b * y4) - (i * y5))), (y2 * ((y1 * y4) - (y0 * y5)))) + (z * ((b * y0) - (i * y1))));
} else if (b <= 4.8e+94) {
tmp = y0 * (fma(-1.0, (y5 * ((k * y2) - (j * y3))), (c * t_1)) - (b * t_3));
} else {
tmp = t_4;
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = Float64(Float64(x * y2) - Float64(y3 * z)) t_2 = Float64(Float64(x * y) - Float64(t * z)) t_3 = Float64(Float64(j * x) - Float64(k * z)) t_4 = Float64(b * Float64(fma(a, t_2, Float64(y4 * Float64(Float64(j * t) - Float64(k * y)))) - Float64(y0 * t_3))) tmp = 0.0 if (b <= -2.5e+113) tmp = t_4; elseif (b <= -2.4e+69) tmp = Float64(c * Float64(fma(-1.0, Float64(i * t_2), Float64(y0 * t_1)) - Float64(y4 * Float64(Float64(t * y2) - Float64(y * y3))))); elseif (b <= -5e-128) tmp = Float64(Float64(-z) * fma(t, Float64(Float64(a * b) - Float64(c * i)), Float64(y3 * Float64(Float64(c * y0) - Float64(a * y1))))); elseif (b <= 5.9e-95) tmp = Float64(k * Float64(fma(-1.0, Float64(y * Float64(Float64(b * y4) - Float64(i * y5))), Float64(y2 * Float64(Float64(y1 * y4) - Float64(y0 * y5)))) + Float64(z * Float64(Float64(b * y0) - Float64(i * y1))))); elseif (b <= 4.8e+94) tmp = Float64(y0 * Float64(fma(-1.0, Float64(y5 * Float64(Float64(k * y2) - Float64(j * y3))), Float64(c * t_1)) - Float64(b * t_3))); else tmp = t_4; end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(x * y2), $MachinePrecision] - N[(y3 * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x * y), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(b * N[(N[(a * t$95$2 + N[(y4 * N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y0 * t$95$3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -2.5e+113], t$95$4, If[LessEqual[b, -2.4e+69], N[(c * N[(N[(-1.0 * N[(i * t$95$2), $MachinePrecision] + N[(y0 * t$95$1), $MachinePrecision]), $MachinePrecision] - N[(y4 * N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, -5e-128], N[((-z) * N[(t * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision] + N[(y3 * N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 5.9e-95], N[(k * N[(N[(-1.0 * N[(y * N[(N[(b * y4), $MachinePrecision] - N[(i * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(y2 * N[(N[(y1 * y4), $MachinePrecision] - N[(y0 * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(z * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 4.8e+94], N[(y0 * N[(N[(-1.0 * N[(y5 * N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(c * t$95$1), $MachinePrecision]), $MachinePrecision] - N[(b * t$95$3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$4]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot y2 - y3 \cdot z\\
t_2 := x \cdot y - t \cdot z\\
t_3 := j \cdot x - k \cdot z\\
t_4 := b \cdot \left(\mathsf{fma}\left(a, t\_2, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot t\_3\right)\\
\mathbf{if}\;b \leq -2.5 \cdot 10^{+113}:\\
\;\;\;\;t\_4\\
\mathbf{elif}\;b \leq -2.4 \cdot 10^{+69}:\\
\;\;\;\;c \cdot \left(\mathsf{fma}\left(-1, i \cdot t\_2, y0 \cdot t\_1\right) - y4 \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\\
\mathbf{elif}\;b \leq -5 \cdot 10^{-128}:\\
\;\;\;\;\left(-z\right) \cdot \mathsf{fma}\left(t, a \cdot b - c \cdot i, y3 \cdot \left(c \cdot y0 - a \cdot y1\right)\right)\\
\mathbf{elif}\;b \leq 5.9 \cdot 10^{-95}:\\
\;\;\;\;k \cdot \left(\mathsf{fma}\left(-1, y \cdot \left(b \cdot y4 - i \cdot y5\right), y2 \cdot \left(y1 \cdot y4 - y0 \cdot y5\right)\right) + z \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\
\mathbf{elif}\;b \leq 4.8 \cdot 10^{+94}:\\
\;\;\;\;y0 \cdot \left(\mathsf{fma}\left(-1, y5 \cdot \left(k \cdot y2 - j \cdot y3\right), c \cdot t\_1\right) - b \cdot t\_3\right)\\
\mathbf{else}:\\
\;\;\;\;t\_4\\
\end{array}
\end{array}
if b < -2.5e113 or 4.79999999999999965e94 < b Initial program 25.8%
Taylor expanded in b around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites60.0%
if -2.5e113 < b < -2.4000000000000002e69Initial program 12.7%
Taylor expanded in c around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites68.7%
if -2.4000000000000002e69 < b < -5.0000000000000001e-128Initial program 34.1%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites44.1%
Taylor expanded in k around 0
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f64N/A
lift-fma.f6450.7
Applied rewrites50.7%
if -5.0000000000000001e-128 < b < 5.8999999999999998e-95Initial program 29.0%
Taylor expanded in k around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites56.5%
if 5.8999999999999998e-95 < b < 4.79999999999999965e94Initial program 27.1%
Taylor expanded in y0 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites59.7%
Final simplification57.9%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(let* ((t_1 (- (* c y0) (* a y1)))
(t_2 (- (* t y2) (* y y3)))
(t_3
(*
(- y5)
(-
(fma i (- (* j t) (* k y)) (* y0 (- (* k y2) (* j y3))))
(* a t_2)))))
(if (<= y5 -3.7e+90)
t_3
(if (<= y5 -1.06e-79)
(* y4 (- (* k (fma -1.0 (* b y) (* y1 y2))) (* c t_2)))
(if (<= y5 -3.8e-294)
(*
x
(-
(fma y (- (* a b) (* c i)) (* y2 t_1))
(* j (- (* b y0) (* i y1)))))
(if (<= y5 1.1e-41)
(*
c
(-
(fma -1.0 (* i (- (* x y) (* t z))) (* y0 (- (* x y2) (* y3 z))))
(* y4 t_2)))
(if (<= y5 6.5e+80)
(*
(- y3)
(-
(fma j (- (* y1 y4) (* y0 y5)) (* z t_1))
(* y (- (* c y4) (* a y5)))))
t_3)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = (c * y0) - (a * y1);
double t_2 = (t * y2) - (y * y3);
double t_3 = -y5 * (fma(i, ((j * t) - (k * y)), (y0 * ((k * y2) - (j * y3)))) - (a * t_2));
double tmp;
if (y5 <= -3.7e+90) {
tmp = t_3;
} else if (y5 <= -1.06e-79) {
tmp = y4 * ((k * fma(-1.0, (b * y), (y1 * y2))) - (c * t_2));
} else if (y5 <= -3.8e-294) {
tmp = x * (fma(y, ((a * b) - (c * i)), (y2 * t_1)) - (j * ((b * y0) - (i * y1))));
} else if (y5 <= 1.1e-41) {
tmp = c * (fma(-1.0, (i * ((x * y) - (t * z))), (y0 * ((x * y2) - (y3 * z)))) - (y4 * t_2));
} else if (y5 <= 6.5e+80) {
tmp = -y3 * (fma(j, ((y1 * y4) - (y0 * y5)), (z * t_1)) - (y * ((c * y4) - (a * y5))));
} else {
tmp = t_3;
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = Float64(Float64(c * y0) - Float64(a * y1)) t_2 = Float64(Float64(t * y2) - Float64(y * y3)) t_3 = Float64(Float64(-y5) * Float64(fma(i, Float64(Float64(j * t) - Float64(k * y)), Float64(y0 * Float64(Float64(k * y2) - Float64(j * y3)))) - Float64(a * t_2))) tmp = 0.0 if (y5 <= -3.7e+90) tmp = t_3; elseif (y5 <= -1.06e-79) tmp = Float64(y4 * Float64(Float64(k * fma(-1.0, Float64(b * y), Float64(y1 * y2))) - Float64(c * t_2))); elseif (y5 <= -3.8e-294) tmp = Float64(x * Float64(fma(y, Float64(Float64(a * b) - Float64(c * i)), Float64(y2 * t_1)) - Float64(j * Float64(Float64(b * y0) - Float64(i * y1))))); elseif (y5 <= 1.1e-41) tmp = Float64(c * Float64(fma(-1.0, Float64(i * Float64(Float64(x * y) - Float64(t * z))), Float64(y0 * Float64(Float64(x * y2) - Float64(y3 * z)))) - Float64(y4 * t_2))); elseif (y5 <= 6.5e+80) tmp = Float64(Float64(-y3) * Float64(fma(j, Float64(Float64(y1 * y4) - Float64(y0 * y5)), Float64(z * t_1)) - Float64(y * Float64(Float64(c * y4) - Float64(a * y5))))); else tmp = t_3; end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[((-y5) * N[(N[(i * N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision] + N[(y0 * N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y5, -3.7e+90], t$95$3, If[LessEqual[y5, -1.06e-79], N[(y4 * N[(N[(k * N[(-1.0 * N[(b * y), $MachinePrecision] + N[(y1 * y2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(c * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y5, -3.8e-294], N[(x * N[(N[(y * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision] + N[(y2 * t$95$1), $MachinePrecision]), $MachinePrecision] - N[(j * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y5, 1.1e-41], N[(c * N[(N[(-1.0 * N[(i * N[(N[(x * y), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(y0 * N[(N[(x * y2), $MachinePrecision] - N[(y3 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y4 * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y5, 6.5e+80], N[((-y3) * N[(N[(j * N[(N[(y1 * y4), $MachinePrecision] - N[(y0 * y5), $MachinePrecision]), $MachinePrecision] + N[(z * t$95$1), $MachinePrecision]), $MachinePrecision] - N[(y * N[(N[(c * y4), $MachinePrecision] - N[(a * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$3]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := c \cdot y0 - a \cdot y1\\
t_2 := t \cdot y2 - y \cdot y3\\
t_3 := \left(-y5\right) \cdot \left(\mathsf{fma}\left(i, j \cdot t - k \cdot y, y0 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - a \cdot t\_2\right)\\
\mathbf{if}\;y5 \leq -3.7 \cdot 10^{+90}:\\
\;\;\;\;t\_3\\
\mathbf{elif}\;y5 \leq -1.06 \cdot 10^{-79}:\\
\;\;\;\;y4 \cdot \left(k \cdot \mathsf{fma}\left(-1, b \cdot y, y1 \cdot y2\right) - c \cdot t\_2\right)\\
\mathbf{elif}\;y5 \leq -3.8 \cdot 10^{-294}:\\
\;\;\;\;x \cdot \left(\mathsf{fma}\left(y, a \cdot b - c \cdot i, y2 \cdot t\_1\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\
\mathbf{elif}\;y5 \leq 1.1 \cdot 10^{-41}:\\
\;\;\;\;c \cdot \left(\mathsf{fma}\left(-1, i \cdot \left(x \cdot y - t \cdot z\right), y0 \cdot \left(x \cdot y2 - y3 \cdot z\right)\right) - y4 \cdot t\_2\right)\\
\mathbf{elif}\;y5 \leq 6.5 \cdot 10^{+80}:\\
\;\;\;\;\left(-y3\right) \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot t\_1\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_3\\
\end{array}
\end{array}
if y5 < -3.7e90 or 6.4999999999999998e80 < y5 Initial program 24.6%
Taylor expanded in y5 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites65.7%
if -3.7e90 < y5 < -1.06000000000000005e-79Initial program 30.3%
Taylor expanded in y4 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites48.9%
Taylor expanded in k around inf
lower-*.f64N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-*.f6449.2
Applied rewrites49.2%
if -1.06000000000000005e-79 < y5 < -3.8e-294Initial program 29.6%
Taylor expanded in x around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites49.7%
if -3.8e-294 < y5 < 1.1e-41Initial program 31.3%
Taylor expanded in c around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites50.6%
if 1.1e-41 < y5 < 6.4999999999999998e80Initial program 25.0%
Taylor expanded in y3 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites56.9%
Final simplification56.5%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(let* ((t_1 (* y2 (- (* c y0) (* a y1))))
(t_2 (- (* j t) (* k y)))
(t_3 (- (* t y2) (* y y3)))
(t_4
(* (- y5) (- (fma i t_2 (* y0 (- (* k y2) (* j y3)))) (* a t_3)))))
(if (<= y5 -3.7e+90)
t_4
(if (<= y5 -1.06e-79)
(* y4 (- (* k (fma -1.0 (* b y) (* y1 y2))) (* c t_3)))
(if (<= y5 6.2e-117)
(* x (- (fma y (- (* a b) (* c i)) t_1) (* j (- (* b y0) (* i y1)))))
(if (<= y5 2.7e+52)
(*
b
(-
(fma a (- (* x y) (* t z)) (* y4 t_2))
(* y0 (- (* j x) (* k z)))))
(if (<= y5 5e+80) (* x t_1) t_4)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = y2 * ((c * y0) - (a * y1));
double t_2 = (j * t) - (k * y);
double t_3 = (t * y2) - (y * y3);
double t_4 = -y5 * (fma(i, t_2, (y0 * ((k * y2) - (j * y3)))) - (a * t_3));
double tmp;
if (y5 <= -3.7e+90) {
tmp = t_4;
} else if (y5 <= -1.06e-79) {
tmp = y4 * ((k * fma(-1.0, (b * y), (y1 * y2))) - (c * t_3));
} else if (y5 <= 6.2e-117) {
tmp = x * (fma(y, ((a * b) - (c * i)), t_1) - (j * ((b * y0) - (i * y1))));
} else if (y5 <= 2.7e+52) {
tmp = b * (fma(a, ((x * y) - (t * z)), (y4 * t_2)) - (y0 * ((j * x) - (k * z))));
} else if (y5 <= 5e+80) {
tmp = x * t_1;
} else {
tmp = t_4;
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = Float64(y2 * Float64(Float64(c * y0) - Float64(a * y1))) t_2 = Float64(Float64(j * t) - Float64(k * y)) t_3 = Float64(Float64(t * y2) - Float64(y * y3)) t_4 = Float64(Float64(-y5) * Float64(fma(i, t_2, Float64(y0 * Float64(Float64(k * y2) - Float64(j * y3)))) - Float64(a * t_3))) tmp = 0.0 if (y5 <= -3.7e+90) tmp = t_4; elseif (y5 <= -1.06e-79) tmp = Float64(y4 * Float64(Float64(k * fma(-1.0, Float64(b * y), Float64(y1 * y2))) - Float64(c * t_3))); elseif (y5 <= 6.2e-117) tmp = Float64(x * Float64(fma(y, Float64(Float64(a * b) - Float64(c * i)), t_1) - Float64(j * Float64(Float64(b * y0) - Float64(i * y1))))); elseif (y5 <= 2.7e+52) tmp = Float64(b * Float64(fma(a, Float64(Float64(x * y) - Float64(t * z)), Float64(y4 * t_2)) - Float64(y0 * Float64(Float64(j * x) - Float64(k * z))))); elseif (y5 <= 5e+80) tmp = Float64(x * t_1); else tmp = t_4; end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(y2 * N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[((-y5) * N[(N[(i * t$95$2 + N[(y0 * N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * t$95$3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y5, -3.7e+90], t$95$4, If[LessEqual[y5, -1.06e-79], N[(y4 * N[(N[(k * N[(-1.0 * N[(b * y), $MachinePrecision] + N[(y1 * y2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(c * t$95$3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y5, 6.2e-117], N[(x * N[(N[(y * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision] + t$95$1), $MachinePrecision] - N[(j * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y5, 2.7e+52], N[(b * N[(N[(a * N[(N[(x * y), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision] + N[(y4 * t$95$2), $MachinePrecision]), $MachinePrecision] - N[(y0 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y5, 5e+80], N[(x * t$95$1), $MachinePrecision], t$95$4]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\\
t_2 := j \cdot t - k \cdot y\\
t_3 := t \cdot y2 - y \cdot y3\\
t_4 := \left(-y5\right) \cdot \left(\mathsf{fma}\left(i, t\_2, y0 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - a \cdot t\_3\right)\\
\mathbf{if}\;y5 \leq -3.7 \cdot 10^{+90}:\\
\;\;\;\;t\_4\\
\mathbf{elif}\;y5 \leq -1.06 \cdot 10^{-79}:\\
\;\;\;\;y4 \cdot \left(k \cdot \mathsf{fma}\left(-1, b \cdot y, y1 \cdot y2\right) - c \cdot t\_3\right)\\
\mathbf{elif}\;y5 \leq 6.2 \cdot 10^{-117}:\\
\;\;\;\;x \cdot \left(\mathsf{fma}\left(y, a \cdot b - c \cdot i, t\_1\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\
\mathbf{elif}\;y5 \leq 2.7 \cdot 10^{+52}:\\
\;\;\;\;b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot t\_2\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)\\
\mathbf{elif}\;y5 \leq 5 \cdot 10^{+80}:\\
\;\;\;\;x \cdot t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_4\\
\end{array}
\end{array}
if y5 < -3.7e90 or 4.99999999999999961e80 < y5 Initial program 24.6%
Taylor expanded in y5 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites65.7%
if -3.7e90 < y5 < -1.06000000000000005e-79Initial program 30.3%
Taylor expanded in y4 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites48.9%
Taylor expanded in k around inf
lower-*.f64N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-*.f6449.2
Applied rewrites49.2%
if -1.06000000000000005e-79 < y5 < 6.20000000000000022e-117Initial program 28.2%
Taylor expanded in x around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites45.3%
if 6.20000000000000022e-117 < y5 < 2.7e52Initial program 36.9%
Taylor expanded in b around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites61.1%
if 2.7e52 < y5 < 4.99999999999999961e80Initial program 8.3%
Taylor expanded in y2 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites50.0%
Taylor expanded in x around inf
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f6466.9
Applied rewrites66.9%
Final simplification56.4%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(let* ((t_1
(*
b
(-
(fma a (- (* x y) (* t z)) (* y4 (- (* j t) (* k y))))
(* y0 (- (* j x) (* k z))))))
(t_2
(* (- z) (fma t (- (* a b) (* c i)) (* y3 (- (* c y0) (* a y1)))))))
(if (<= z -9.5e+243)
t_1
(if (<= z -0.13)
t_2
(if (<= z -5.8e-172)
t_1
(if (<= z 2.05e-223)
(* (- y5) (- (* i (* j t)) (* a (- (* t y2) (* y y3)))))
(if (<= z 3.8e+90)
t_1
(if (<= z 2.5e+186) (* k (* z (- (* b y0) (* i y1)))) t_2))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = b * (fma(a, ((x * y) - (t * z)), (y4 * ((j * t) - (k * y)))) - (y0 * ((j * x) - (k * z))));
double t_2 = -z * fma(t, ((a * b) - (c * i)), (y3 * ((c * y0) - (a * y1))));
double tmp;
if (z <= -9.5e+243) {
tmp = t_1;
} else if (z <= -0.13) {
tmp = t_2;
} else if (z <= -5.8e-172) {
tmp = t_1;
} else if (z <= 2.05e-223) {
tmp = -y5 * ((i * (j * t)) - (a * ((t * y2) - (y * y3))));
} else if (z <= 3.8e+90) {
tmp = t_1;
} else if (z <= 2.5e+186) {
tmp = k * (z * ((b * y0) - (i * y1)));
} else {
tmp = t_2;
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = Float64(b * Float64(fma(a, Float64(Float64(x * y) - Float64(t * z)), Float64(y4 * Float64(Float64(j * t) - Float64(k * y)))) - Float64(y0 * Float64(Float64(j * x) - Float64(k * z))))) t_2 = Float64(Float64(-z) * fma(t, Float64(Float64(a * b) - Float64(c * i)), Float64(y3 * Float64(Float64(c * y0) - Float64(a * y1))))) tmp = 0.0 if (z <= -9.5e+243) tmp = t_1; elseif (z <= -0.13) tmp = t_2; elseif (z <= -5.8e-172) tmp = t_1; elseif (z <= 2.05e-223) tmp = Float64(Float64(-y5) * Float64(Float64(i * Float64(j * t)) - Float64(a * Float64(Float64(t * y2) - Float64(y * y3))))); elseif (z <= 3.8e+90) tmp = t_1; elseif (z <= 2.5e+186) tmp = Float64(k * Float64(z * Float64(Float64(b * y0) - Float64(i * y1)))); else tmp = t_2; end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(b * N[(N[(a * N[(N[(x * y), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision] + N[(y4 * N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y0 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[((-z) * N[(t * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision] + N[(y3 * N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -9.5e+243], t$95$1, If[LessEqual[z, -0.13], t$95$2, If[LessEqual[z, -5.8e-172], t$95$1, If[LessEqual[z, 2.05e-223], N[((-y5) * N[(N[(i * N[(j * t), $MachinePrecision]), $MachinePrecision] - N[(a * N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 3.8e+90], t$95$1, If[LessEqual[z, 2.5e+186], N[(k * N[(z * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$2]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)\\
t_2 := \left(-z\right) \cdot \mathsf{fma}\left(t, a \cdot b - c \cdot i, y3 \cdot \left(c \cdot y0 - a \cdot y1\right)\right)\\
\mathbf{if}\;z \leq -9.5 \cdot 10^{+243}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -0.13:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;z \leq -5.8 \cdot 10^{-172}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq 2.05 \cdot 10^{-223}:\\
\;\;\;\;\left(-y5\right) \cdot \left(i \cdot \left(j \cdot t\right) - a \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\\
\mathbf{elif}\;z \leq 3.8 \cdot 10^{+90}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq 2.5 \cdot 10^{+186}:\\
\;\;\;\;k \cdot \left(z \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if z < -9.49999999999999957e243 or -0.13 < z < -5.79999999999999995e-172 or 2.05000000000000007e-223 < z < 3.8000000000000001e90Initial program 28.6%
Taylor expanded in b around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites52.5%
if -9.49999999999999957e243 < z < -0.13 or 2.49999999999999977e186 < z Initial program 22.0%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites53.6%
Taylor expanded in k around 0
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f64N/A
lift-fma.f6454.7
Applied rewrites54.7%
if -5.79999999999999995e-172 < z < 2.05000000000000007e-223Initial program 39.4%
Taylor expanded in y5 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites48.0%
Taylor expanded in t around inf
lower-*.f64N/A
lift-*.f6451.1
Applied rewrites51.1%
if 3.8000000000000001e90 < z < 2.49999999999999977e186Initial program 23.7%
Taylor expanded in k around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites76.7%
Taylor expanded in z around inf
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f6467.4
Applied rewrites67.4%
Final simplification54.3%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(let* ((t_1 (- (* t y2) (* y y3)))
(t_2
(*
(- y5)
(-
(fma i (- (* j t) (* k y)) (* y0 (- (* k y2) (* j y3))))
(* a t_1))))
(t_3 (- (* y1 y4) (* y0 y5))))
(if (<= y5 -5e+87)
t_2
(if (<= y5 -1.2e-139)
(*
j
(-
(fma -1.0 (* y3 t_3) (* t (- (* b y4) (* i y5))))
(* x (- (* b y0) (* i y1)))))
(if (<= y5 1.1e-41)
(*
c
(-
(fma -1.0 (* i (- (* x y) (* t z))) (* y0 (- (* x y2) (* y3 z))))
(* y4 t_1)))
(if (<= y5 6.5e+80)
(*
(- y3)
(-
(fma j t_3 (* z (- (* c y0) (* a y1))))
(* y (- (* c y4) (* a y5)))))
t_2))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = (t * y2) - (y * y3);
double t_2 = -y5 * (fma(i, ((j * t) - (k * y)), (y0 * ((k * y2) - (j * y3)))) - (a * t_1));
double t_3 = (y1 * y4) - (y0 * y5);
double tmp;
if (y5 <= -5e+87) {
tmp = t_2;
} else if (y5 <= -1.2e-139) {
tmp = j * (fma(-1.0, (y3 * t_3), (t * ((b * y4) - (i * y5)))) - (x * ((b * y0) - (i * y1))));
} else if (y5 <= 1.1e-41) {
tmp = c * (fma(-1.0, (i * ((x * y) - (t * z))), (y0 * ((x * y2) - (y3 * z)))) - (y4 * t_1));
} else if (y5 <= 6.5e+80) {
tmp = -y3 * (fma(j, t_3, (z * ((c * y0) - (a * y1)))) - (y * ((c * y4) - (a * y5))));
} else {
tmp = t_2;
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = Float64(Float64(t * y2) - Float64(y * y3)) t_2 = Float64(Float64(-y5) * Float64(fma(i, Float64(Float64(j * t) - Float64(k * y)), Float64(y0 * Float64(Float64(k * y2) - Float64(j * y3)))) - Float64(a * t_1))) t_3 = Float64(Float64(y1 * y4) - Float64(y0 * y5)) tmp = 0.0 if (y5 <= -5e+87) tmp = t_2; elseif (y5 <= -1.2e-139) tmp = Float64(j * Float64(fma(-1.0, Float64(y3 * t_3), Float64(t * Float64(Float64(b * y4) - Float64(i * y5)))) - Float64(x * Float64(Float64(b * y0) - Float64(i * y1))))); elseif (y5 <= 1.1e-41) tmp = Float64(c * Float64(fma(-1.0, Float64(i * Float64(Float64(x * y) - Float64(t * z))), Float64(y0 * Float64(Float64(x * y2) - Float64(y3 * z)))) - Float64(y4 * t_1))); elseif (y5 <= 6.5e+80) tmp = Float64(Float64(-y3) * Float64(fma(j, t_3, Float64(z * Float64(Float64(c * y0) - Float64(a * y1)))) - Float64(y * Float64(Float64(c * y4) - Float64(a * y5))))); else tmp = t_2; end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[((-y5) * N[(N[(i * N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision] + N[(y0 * N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(y1 * y4), $MachinePrecision] - N[(y0 * y5), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y5, -5e+87], t$95$2, If[LessEqual[y5, -1.2e-139], N[(j * N[(N[(-1.0 * N[(y3 * t$95$3), $MachinePrecision] + N[(t * N[(N[(b * y4), $MachinePrecision] - N[(i * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(x * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y5, 1.1e-41], N[(c * N[(N[(-1.0 * N[(i * N[(N[(x * y), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(y0 * N[(N[(x * y2), $MachinePrecision] - N[(y3 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y4 * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y5, 6.5e+80], N[((-y3) * N[(N[(j * t$95$3 + N[(z * N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y * N[(N[(c * y4), $MachinePrecision] - N[(a * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$2]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := t \cdot y2 - y \cdot y3\\
t_2 := \left(-y5\right) \cdot \left(\mathsf{fma}\left(i, j \cdot t - k \cdot y, y0 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - a \cdot t\_1\right)\\
t_3 := y1 \cdot y4 - y0 \cdot y5\\
\mathbf{if}\;y5 \leq -5 \cdot 10^{+87}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y5 \leq -1.2 \cdot 10^{-139}:\\
\;\;\;\;j \cdot \left(\mathsf{fma}\left(-1, y3 \cdot t\_3, t \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - x \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\
\mathbf{elif}\;y5 \leq 1.1 \cdot 10^{-41}:\\
\;\;\;\;c \cdot \left(\mathsf{fma}\left(-1, i \cdot \left(x \cdot y - t \cdot z\right), y0 \cdot \left(x \cdot y2 - y3 \cdot z\right)\right) - y4 \cdot t\_1\right)\\
\mathbf{elif}\;y5 \leq 6.5 \cdot 10^{+80}:\\
\;\;\;\;\left(-y3\right) \cdot \left(\mathsf{fma}\left(j, t\_3, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if y5 < -4.9999999999999998e87 or 6.4999999999999998e80 < y5 Initial program 24.3%
Taylor expanded in y5 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites65.1%
if -4.9999999999999998e87 < y5 < -1.20000000000000007e-139Initial program 24.6%
Taylor expanded in j around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites47.3%
if -1.20000000000000007e-139 < y5 < 1.1e-41Initial program 33.8%
Taylor expanded in c around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites48.3%
if 1.1e-41 < y5 < 6.4999999999999998e80Initial program 25.0%
Taylor expanded in y3 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites56.9%
Final simplification55.3%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(let* ((t_1 (- (* a b) (* c i)))
(t_2
(*
b
(-
(fma a (- (* x y) (* t z)) (* y4 (- (* j t) (* k y))))
(* y0 (- (* j x) (* k z))))))
(t_3 (- (* b y0) (* i y1)))
(t_4 (- (* c y0) (* a y1)))
(t_5 (* (- z) (fma t t_1 (* y3 t_4)))))
(if (<= z -9.5e+243)
t_2
(if (<= z -5.8e+40)
t_5
(if (<= z 3.3e-230)
(* x (- (fma y t_1 (* y2 t_4)) (* j t_3)))
(if (<= z 3.8e+90) t_2 (if (<= z 2.5e+186) (* k (* z t_3)) t_5)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = (a * b) - (c * i);
double t_2 = b * (fma(a, ((x * y) - (t * z)), (y4 * ((j * t) - (k * y)))) - (y0 * ((j * x) - (k * z))));
double t_3 = (b * y0) - (i * y1);
double t_4 = (c * y0) - (a * y1);
double t_5 = -z * fma(t, t_1, (y3 * t_4));
double tmp;
if (z <= -9.5e+243) {
tmp = t_2;
} else if (z <= -5.8e+40) {
tmp = t_5;
} else if (z <= 3.3e-230) {
tmp = x * (fma(y, t_1, (y2 * t_4)) - (j * t_3));
} else if (z <= 3.8e+90) {
tmp = t_2;
} else if (z <= 2.5e+186) {
tmp = k * (z * t_3);
} else {
tmp = t_5;
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = Float64(Float64(a * b) - Float64(c * i)) t_2 = Float64(b * Float64(fma(a, Float64(Float64(x * y) - Float64(t * z)), Float64(y4 * Float64(Float64(j * t) - Float64(k * y)))) - Float64(y0 * Float64(Float64(j * x) - Float64(k * z))))) t_3 = Float64(Float64(b * y0) - Float64(i * y1)) t_4 = Float64(Float64(c * y0) - Float64(a * y1)) t_5 = Float64(Float64(-z) * fma(t, t_1, Float64(y3 * t_4))) tmp = 0.0 if (z <= -9.5e+243) tmp = t_2; elseif (z <= -5.8e+40) tmp = t_5; elseif (z <= 3.3e-230) tmp = Float64(x * Float64(fma(y, t_1, Float64(y2 * t_4)) - Float64(j * t_3))); elseif (z <= 3.8e+90) tmp = t_2; elseif (z <= 2.5e+186) tmp = Float64(k * Float64(z * t_3)); else tmp = t_5; end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(b * N[(N[(a * N[(N[(x * y), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision] + N[(y4 * N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y0 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[((-z) * N[(t * t$95$1 + N[(y3 * t$95$4), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -9.5e+243], t$95$2, If[LessEqual[z, -5.8e+40], t$95$5, If[LessEqual[z, 3.3e-230], N[(x * N[(N[(y * t$95$1 + N[(y2 * t$95$4), $MachinePrecision]), $MachinePrecision] - N[(j * t$95$3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 3.8e+90], t$95$2, If[LessEqual[z, 2.5e+186], N[(k * N[(z * t$95$3), $MachinePrecision]), $MachinePrecision], t$95$5]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := a \cdot b - c \cdot i\\
t_2 := b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)\\
t_3 := b \cdot y0 - i \cdot y1\\
t_4 := c \cdot y0 - a \cdot y1\\
t_5 := \left(-z\right) \cdot \mathsf{fma}\left(t, t\_1, y3 \cdot t\_4\right)\\
\mathbf{if}\;z \leq -9.5 \cdot 10^{+243}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;z \leq -5.8 \cdot 10^{+40}:\\
\;\;\;\;t\_5\\
\mathbf{elif}\;z \leq 3.3 \cdot 10^{-230}:\\
\;\;\;\;x \cdot \left(\mathsf{fma}\left(y, t\_1, y2 \cdot t\_4\right) - j \cdot t\_3\right)\\
\mathbf{elif}\;z \leq 3.8 \cdot 10^{+90}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;z \leq 2.5 \cdot 10^{+186}:\\
\;\;\;\;k \cdot \left(z \cdot t\_3\right)\\
\mathbf{else}:\\
\;\;\;\;t\_5\\
\end{array}
\end{array}
if z < -9.49999999999999957e243 or 3.29999999999999994e-230 < z < 3.8000000000000001e90Initial program 25.3%
Taylor expanded in b around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites53.0%
if -9.49999999999999957e243 < z < -5.80000000000000035e40 or 2.49999999999999977e186 < z Initial program 22.5%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites55.8%
Taylor expanded in k around 0
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f64N/A
lift-fma.f6455.9
Applied rewrites55.9%
if -5.80000000000000035e40 < z < 3.29999999999999994e-230Initial program 35.2%
Taylor expanded in x around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites48.0%
if 3.8000000000000001e90 < z < 2.49999999999999977e186Initial program 23.7%
Taylor expanded in k around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites76.7%
Taylor expanded in z around inf
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f6467.4
Applied rewrites67.4%
Final simplification53.4%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(let* ((t_1
(*
b
(-
(fma a (- (* x y) (* t z)) (* y4 (- (* j t) (* k y))))
(* y0 (- (* j x) (* k z))))))
(t_2 (- (* c y0) (* a y1))))
(if (<= b -3.6e+58)
t_1
(if (<= b -7e-142)
(* (- z) (fma t (- (* a b) (* c i)) (* y3 t_2)))
(if (<= b 1.55e-20)
(*
y2
(-
(fma k (- (* y1 y4) (* y0 y5)) (* x t_2))
(* t (- (* c y4) (* a y5)))))
t_1)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = b * (fma(a, ((x * y) - (t * z)), (y4 * ((j * t) - (k * y)))) - (y0 * ((j * x) - (k * z))));
double t_2 = (c * y0) - (a * y1);
double tmp;
if (b <= -3.6e+58) {
tmp = t_1;
} else if (b <= -7e-142) {
tmp = -z * fma(t, ((a * b) - (c * i)), (y3 * t_2));
} else if (b <= 1.55e-20) {
tmp = y2 * (fma(k, ((y1 * y4) - (y0 * y5)), (x * t_2)) - (t * ((c * y4) - (a * y5))));
} else {
tmp = t_1;
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = Float64(b * Float64(fma(a, Float64(Float64(x * y) - Float64(t * z)), Float64(y4 * Float64(Float64(j * t) - Float64(k * y)))) - Float64(y0 * Float64(Float64(j * x) - Float64(k * z))))) t_2 = Float64(Float64(c * y0) - Float64(a * y1)) tmp = 0.0 if (b <= -3.6e+58) tmp = t_1; elseif (b <= -7e-142) tmp = Float64(Float64(-z) * fma(t, Float64(Float64(a * b) - Float64(c * i)), Float64(y3 * t_2))); elseif (b <= 1.55e-20) tmp = Float64(y2 * Float64(fma(k, Float64(Float64(y1 * y4) - Float64(y0 * y5)), Float64(x * t_2)) - Float64(t * Float64(Float64(c * y4) - Float64(a * y5))))); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(b * N[(N[(a * N[(N[(x * y), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision] + N[(y4 * N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y0 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -3.6e+58], t$95$1, If[LessEqual[b, -7e-142], N[((-z) * N[(t * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision] + N[(y3 * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 1.55e-20], N[(y2 * N[(N[(k * N[(N[(y1 * y4), $MachinePrecision] - N[(y0 * y5), $MachinePrecision]), $MachinePrecision] + N[(x * t$95$2), $MachinePrecision]), $MachinePrecision] - N[(t * N[(N[(c * y4), $MachinePrecision] - N[(a * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)\\
t_2 := c \cdot y0 - a \cdot y1\\
\mathbf{if}\;b \leq -3.6 \cdot 10^{+58}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \leq -7 \cdot 10^{-142}:\\
\;\;\;\;\left(-z\right) \cdot \mathsf{fma}\left(t, a \cdot b - c \cdot i, y3 \cdot t\_2\right)\\
\mathbf{elif}\;b \leq 1.55 \cdot 10^{-20}:\\
\;\;\;\;y2 \cdot \left(\mathsf{fma}\left(k, y1 \cdot y4 - y0 \cdot y5, x \cdot t\_2\right) - t \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if b < -3.59999999999999996e58 or 1.55e-20 < b Initial program 23.0%
Taylor expanded in b around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites56.3%
if -3.59999999999999996e58 < b < -7.00000000000000029e-142Initial program 37.3%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites45.1%
Taylor expanded in k around 0
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f64N/A
lift-fma.f6451.9
Applied rewrites51.9%
if -7.00000000000000029e-142 < b < 1.55e-20Initial program 28.7%
Taylor expanded in y2 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites47.0%
Final simplification52.0%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(let* ((t_1
(* (- z) (fma t (- (* a b) (* c i)) (* y3 (- (* c y0) (* a y1))))))
(t_2 (- (* t y2) (* y y3))))
(if (<= z -4.3e+273)
(* b (* y0 (- (* k z) (* j x))))
(if (<= z -5e+15)
t_1
(if (<= z -3.1e-203)
(* y4 (- (* k (fma -1.0 (* b y) (* y1 y2))) (* c t_2)))
(if (<= z 1.25e+42)
(* (- y5) (- (* i (* j t)) (* a t_2)))
(if (<= z 2.5e+186) (* k (* z (- (* b y0) (* i y1)))) t_1)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = -z * fma(t, ((a * b) - (c * i)), (y3 * ((c * y0) - (a * y1))));
double t_2 = (t * y2) - (y * y3);
double tmp;
if (z <= -4.3e+273) {
tmp = b * (y0 * ((k * z) - (j * x)));
} else if (z <= -5e+15) {
tmp = t_1;
} else if (z <= -3.1e-203) {
tmp = y4 * ((k * fma(-1.0, (b * y), (y1 * y2))) - (c * t_2));
} else if (z <= 1.25e+42) {
tmp = -y5 * ((i * (j * t)) - (a * t_2));
} else if (z <= 2.5e+186) {
tmp = k * (z * ((b * y0) - (i * y1)));
} else {
tmp = t_1;
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = Float64(Float64(-z) * fma(t, Float64(Float64(a * b) - Float64(c * i)), Float64(y3 * Float64(Float64(c * y0) - Float64(a * y1))))) t_2 = Float64(Float64(t * y2) - Float64(y * y3)) tmp = 0.0 if (z <= -4.3e+273) tmp = Float64(b * Float64(y0 * Float64(Float64(k * z) - Float64(j * x)))); elseif (z <= -5e+15) tmp = t_1; elseif (z <= -3.1e-203) tmp = Float64(y4 * Float64(Float64(k * fma(-1.0, Float64(b * y), Float64(y1 * y2))) - Float64(c * t_2))); elseif (z <= 1.25e+42) tmp = Float64(Float64(-y5) * Float64(Float64(i * Float64(j * t)) - Float64(a * t_2))); elseif (z <= 2.5e+186) tmp = Float64(k * Float64(z * Float64(Float64(b * y0) - Float64(i * y1)))); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[((-z) * N[(t * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision] + N[(y3 * N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -4.3e+273], N[(b * N[(y0 * N[(N[(k * z), $MachinePrecision] - N[(j * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -5e+15], t$95$1, If[LessEqual[z, -3.1e-203], N[(y4 * N[(N[(k * N[(-1.0 * N[(b * y), $MachinePrecision] + N[(y1 * y2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(c * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.25e+42], N[((-y5) * N[(N[(i * N[(j * t), $MachinePrecision]), $MachinePrecision] - N[(a * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.5e+186], N[(k * N[(z * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(-z\right) \cdot \mathsf{fma}\left(t, a \cdot b - c \cdot i, y3 \cdot \left(c \cdot y0 - a \cdot y1\right)\right)\\
t_2 := t \cdot y2 - y \cdot y3\\
\mathbf{if}\;z \leq -4.3 \cdot 10^{+273}:\\
\;\;\;\;b \cdot \left(y0 \cdot \left(k \cdot z - j \cdot x\right)\right)\\
\mathbf{elif}\;z \leq -5 \cdot 10^{+15}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -3.1 \cdot 10^{-203}:\\
\;\;\;\;y4 \cdot \left(k \cdot \mathsf{fma}\left(-1, b \cdot y, y1 \cdot y2\right) - c \cdot t\_2\right)\\
\mathbf{elif}\;z \leq 1.25 \cdot 10^{+42}:\\
\;\;\;\;\left(-y5\right) \cdot \left(i \cdot \left(j \cdot t\right) - a \cdot t\_2\right)\\
\mathbf{elif}\;z \leq 2.5 \cdot 10^{+186}:\\
\;\;\;\;k \cdot \left(z \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -4.30000000000000016e273Initial program 25.0%
Taylor expanded in b around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites75.0%
Taylor expanded in y0 around inf
lower-*.f64N/A
lower--.f64N/A
lift-*.f64N/A
lift-*.f6487.5
Applied rewrites87.5%
if -4.30000000000000016e273 < z < -5e15 or 2.49999999999999977e186 < z Initial program 22.9%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites54.0%
Taylor expanded in k around 0
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f64N/A
lift-fma.f6456.2
Applied rewrites56.2%
if -5e15 < z < -3.09999999999999977e-203Initial program 32.4%
Taylor expanded in y4 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites31.0%
Taylor expanded in k around inf
lower-*.f64N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-*.f6441.4
Applied rewrites41.4%
if -3.09999999999999977e-203 < z < 1.25000000000000002e42Initial program 29.8%
Taylor expanded in y5 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites45.7%
Taylor expanded in t around inf
lower-*.f64N/A
lift-*.f6444.7
Applied rewrites44.7%
if 1.25000000000000002e42 < z < 2.49999999999999977e186Initial program 28.5%
Taylor expanded in k around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites54.9%
Taylor expanded in z around inf
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f6452.3
Applied rewrites52.3%
Final simplification50.4%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(let* ((t_1 (- (* c y0) (* a y1)))
(t_2 (* (- z) (fma t (- (* a b) (* c i)) (* y3 t_1)))))
(if (<= y1 -3.4e+125)
(* i (* (- x) (- (* c y) (* j y1))))
(if (<= y1 -1.08e-193)
t_2
(if (<= y1 3.7e-69)
(* k (* (- y0) (- (* y2 y5) (* b z))))
(if (<= y1 2.6e+71) t_2 (* x (* y2 t_1))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = (c * y0) - (a * y1);
double t_2 = -z * fma(t, ((a * b) - (c * i)), (y3 * t_1));
double tmp;
if (y1 <= -3.4e+125) {
tmp = i * (-x * ((c * y) - (j * y1)));
} else if (y1 <= -1.08e-193) {
tmp = t_2;
} else if (y1 <= 3.7e-69) {
tmp = k * (-y0 * ((y2 * y5) - (b * z)));
} else if (y1 <= 2.6e+71) {
tmp = t_2;
} else {
tmp = x * (y2 * t_1);
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = Float64(Float64(c * y0) - Float64(a * y1)) t_2 = Float64(Float64(-z) * fma(t, Float64(Float64(a * b) - Float64(c * i)), Float64(y3 * t_1))) tmp = 0.0 if (y1 <= -3.4e+125) tmp = Float64(i * Float64(Float64(-x) * Float64(Float64(c * y) - Float64(j * y1)))); elseif (y1 <= -1.08e-193) tmp = t_2; elseif (y1 <= 3.7e-69) tmp = Float64(k * Float64(Float64(-y0) * Float64(Float64(y2 * y5) - Float64(b * z)))); elseif (y1 <= 2.6e+71) tmp = t_2; else tmp = Float64(x * Float64(y2 * t_1)); end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[((-z) * N[(t * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision] + N[(y3 * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y1, -3.4e+125], N[(i * N[((-x) * N[(N[(c * y), $MachinePrecision] - N[(j * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y1, -1.08e-193], t$95$2, If[LessEqual[y1, 3.7e-69], N[(k * N[((-y0) * N[(N[(y2 * y5), $MachinePrecision] - N[(b * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y1, 2.6e+71], t$95$2, N[(x * N[(y2 * t$95$1), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := c \cdot y0 - a \cdot y1\\
t_2 := \left(-z\right) \cdot \mathsf{fma}\left(t, a \cdot b - c \cdot i, y3 \cdot t\_1\right)\\
\mathbf{if}\;y1 \leq -3.4 \cdot 10^{+125}:\\
\;\;\;\;i \cdot \left(\left(-x\right) \cdot \left(c \cdot y - j \cdot y1\right)\right)\\
\mathbf{elif}\;y1 \leq -1.08 \cdot 10^{-193}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y1 \leq 3.7 \cdot 10^{-69}:\\
\;\;\;\;k \cdot \left(\left(-y0\right) \cdot \left(y2 \cdot y5 - b \cdot z\right)\right)\\
\mathbf{elif}\;y1 \leq 2.6 \cdot 10^{+71}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(y2 \cdot t\_1\right)\\
\end{array}
\end{array}
if y1 < -3.3999999999999999e125Initial program 19.7%
Taylor expanded in x around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites36.9%
Taylor expanded in i around -inf
lower-*.f64N/A
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6456.5
Applied rewrites56.5%
if -3.3999999999999999e125 < y1 < -1.08e-193 or 3.7000000000000002e-69 < y1 < 2.59999999999999991e71Initial program 32.3%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites44.3%
Taylor expanded in k around 0
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f64N/A
lift-fma.f6445.4
Applied rewrites45.4%
if -1.08e-193 < y1 < 3.7000000000000002e-69Initial program 26.6%
Taylor expanded in k around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites47.2%
Taylor expanded in y0 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6448.9
Applied rewrites48.9%
if 2.59999999999999991e71 < y1 Initial program 25.1%
Taylor expanded in y2 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites38.0%
Taylor expanded in x around inf
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f6449.6
Applied rewrites49.6%
Final simplification48.7%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(if (<= z -2.5e-83)
(* b (* y0 (- (* k z) (* j x))))
(if (<= z 2.2e+84)
(* (- y5) (- (* i (* j t)) (* a (- (* t y2) (* y y3)))))
(if (<= z 8.5e+219)
(* (- z) (- (* c (* y0 y3)) (* k (- (* b y0) (* i y1)))))
(* c (* z (fma -1.0 (* y0 y3) (* i t))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -2.5e-83) {
tmp = b * (y0 * ((k * z) - (j * x)));
} else if (z <= 2.2e+84) {
tmp = -y5 * ((i * (j * t)) - (a * ((t * y2) - (y * y3))));
} else if (z <= 8.5e+219) {
tmp = -z * ((c * (y0 * y3)) - (k * ((b * y0) - (i * y1))));
} else {
tmp = c * (z * fma(-1.0, (y0 * y3), (i * t)));
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0 if (z <= -2.5e-83) tmp = Float64(b * Float64(y0 * Float64(Float64(k * z) - Float64(j * x)))); elseif (z <= 2.2e+84) tmp = Float64(Float64(-y5) * Float64(Float64(i * Float64(j * t)) - Float64(a * Float64(Float64(t * y2) - Float64(y * y3))))); elseif (z <= 8.5e+219) tmp = Float64(Float64(-z) * Float64(Float64(c * Float64(y0 * y3)) - Float64(k * Float64(Float64(b * y0) - Float64(i * y1))))); else tmp = Float64(c * Float64(z * fma(-1.0, Float64(y0 * y3), Float64(i * t)))); end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[z, -2.5e-83], N[(b * N[(y0 * N[(N[(k * z), $MachinePrecision] - N[(j * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.2e+84], N[((-y5) * N[(N[(i * N[(j * t), $MachinePrecision]), $MachinePrecision] - N[(a * N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 8.5e+219], N[((-z) * N[(N[(c * N[(y0 * y3), $MachinePrecision]), $MachinePrecision] - N[(k * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(c * N[(z * N[(-1.0 * N[(y0 * y3), $MachinePrecision] + N[(i * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.5 \cdot 10^{-83}:\\
\;\;\;\;b \cdot \left(y0 \cdot \left(k \cdot z - j \cdot x\right)\right)\\
\mathbf{elif}\;z \leq 2.2 \cdot 10^{+84}:\\
\;\;\;\;\left(-y5\right) \cdot \left(i \cdot \left(j \cdot t\right) - a \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\\
\mathbf{elif}\;z \leq 8.5 \cdot 10^{+219}:\\
\;\;\;\;\left(-z\right) \cdot \left(c \cdot \left(y0 \cdot y3\right) - k \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\
\mathbf{else}:\\
\;\;\;\;c \cdot \left(z \cdot \mathsf{fma}\left(-1, y0 \cdot y3, i \cdot t\right)\right)\\
\end{array}
\end{array}
if z < -2.5e-83Initial program 23.2%
Taylor expanded in b around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites43.0%
Taylor expanded in y0 around inf
lower-*.f64N/A
lower--.f64N/A
lift-*.f64N/A
lift-*.f6443.3
Applied rewrites43.3%
if -2.5e-83 < z < 2.1999999999999998e84Initial program 34.5%
Taylor expanded in y5 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites43.5%
Taylor expanded in t around inf
lower-*.f64N/A
lift-*.f6440.6
Applied rewrites40.6%
if 2.1999999999999998e84 < z < 8.5000000000000001e219Initial program 18.9%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites53.1%
Taylor expanded in y0 around inf
lower-*.f64N/A
lower-*.f6462.9
Applied rewrites62.9%
if 8.5000000000000001e219 < z Initial program 20.0%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites70.0%
Taylor expanded in c around -inf
lower-*.f64N/A
lower-*.f64N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-*.f6465.1
Applied rewrites65.1%
Final simplification46.2%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(if (<= z -2.5e-83)
(* b (* y0 (- (* k z) (* j x))))
(if (<= z 1.25e+42)
(* (- y5) (- (* i (* j t)) (* a (- (* t y2) (* y y3)))))
(if (<= z 2.5e+186)
(* k (* z (- (* b y0) (* i y1))))
(* c (* z (fma -1.0 (* y0 y3) (* i t))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -2.5e-83) {
tmp = b * (y0 * ((k * z) - (j * x)));
} else if (z <= 1.25e+42) {
tmp = -y5 * ((i * (j * t)) - (a * ((t * y2) - (y * y3))));
} else if (z <= 2.5e+186) {
tmp = k * (z * ((b * y0) - (i * y1)));
} else {
tmp = c * (z * fma(-1.0, (y0 * y3), (i * t)));
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0 if (z <= -2.5e-83) tmp = Float64(b * Float64(y0 * Float64(Float64(k * z) - Float64(j * x)))); elseif (z <= 1.25e+42) tmp = Float64(Float64(-y5) * Float64(Float64(i * Float64(j * t)) - Float64(a * Float64(Float64(t * y2) - Float64(y * y3))))); elseif (z <= 2.5e+186) tmp = Float64(k * Float64(z * Float64(Float64(b * y0) - Float64(i * y1)))); else tmp = Float64(c * Float64(z * fma(-1.0, Float64(y0 * y3), Float64(i * t)))); end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[z, -2.5e-83], N[(b * N[(y0 * N[(N[(k * z), $MachinePrecision] - N[(j * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.25e+42], N[((-y5) * N[(N[(i * N[(j * t), $MachinePrecision]), $MachinePrecision] - N[(a * N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.5e+186], N[(k * N[(z * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(c * N[(z * N[(-1.0 * N[(y0 * y3), $MachinePrecision] + N[(i * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.5 \cdot 10^{-83}:\\
\;\;\;\;b \cdot \left(y0 \cdot \left(k \cdot z - j \cdot x\right)\right)\\
\mathbf{elif}\;z \leq 1.25 \cdot 10^{+42}:\\
\;\;\;\;\left(-y5\right) \cdot \left(i \cdot \left(j \cdot t\right) - a \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\\
\mathbf{elif}\;z \leq 2.5 \cdot 10^{+186}:\\
\;\;\;\;k \cdot \left(z \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\
\mathbf{else}:\\
\;\;\;\;c \cdot \left(z \cdot \mathsf{fma}\left(-1, y0 \cdot y3, i \cdot t\right)\right)\\
\end{array}
\end{array}
if z < -2.5e-83Initial program 23.2%
Taylor expanded in b around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites43.0%
Taylor expanded in y0 around inf
lower-*.f64N/A
lower--.f64N/A
lift-*.f64N/A
lift-*.f6443.3
Applied rewrites43.3%
if -2.5e-83 < z < 1.25000000000000002e42Initial program 34.0%
Taylor expanded in y5 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites45.0%
Taylor expanded in t around inf
lower-*.f64N/A
lift-*.f6441.7
Applied rewrites41.7%
if 1.25000000000000002e42 < z < 2.49999999999999977e186Initial program 28.5%
Taylor expanded in k around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites54.9%
Taylor expanded in z around inf
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f6452.3
Applied rewrites52.3%
if 2.49999999999999977e186 < z Initial program 16.9%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites66.7%
Taylor expanded in c around -inf
lower-*.f64N/A
lower-*.f64N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-*.f6460.6
Applied rewrites60.6%
Final simplification45.9%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(let* ((t_1 (* y1 (* z (- (* a y3) (* i k))))))
(if (<= z -3.4e+152)
t_1
(if (<= z -2.3e+37)
(* (- z) (* y3 (* c y0)))
(if (<= z -3.7e-90)
(* c (* y2 (- (* x y0) (* t y4))))
(if (<= z 9e+41) (* a (* y5 (- (* t y2) (* y y3)))) t_1))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = y1 * (z * ((a * y3) - (i * k)));
double tmp;
if (z <= -3.4e+152) {
tmp = t_1;
} else if (z <= -2.3e+37) {
tmp = -z * (y3 * (c * y0));
} else if (z <= -3.7e-90) {
tmp = c * (y2 * ((x * y0) - (t * y4)));
} else if (z <= 9e+41) {
tmp = a * (y5 * ((t * y2) - (y * y3)));
} else {
tmp = t_1;
}
return tmp;
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
real(8) :: t_1
real(8) :: tmp
t_1 = y1 * (z * ((a * y3) - (i * k)))
if (z <= (-3.4d+152)) then
tmp = t_1
else if (z <= (-2.3d+37)) then
tmp = -z * (y3 * (c * y0))
else if (z <= (-3.7d-90)) then
tmp = c * (y2 * ((x * y0) - (t * y4)))
else if (z <= 9d+41) then
tmp = a * (y5 * ((t * y2) - (y * y3)))
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, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = y1 * (z * ((a * y3) - (i * k)));
double tmp;
if (z <= -3.4e+152) {
tmp = t_1;
} else if (z <= -2.3e+37) {
tmp = -z * (y3 * (c * y0));
} else if (z <= -3.7e-90) {
tmp = c * (y2 * ((x * y0) - (t * y4)));
} else if (z <= 9e+41) {
tmp = a * (y5 * ((t * y2) - (y * y3)));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): t_1 = y1 * (z * ((a * y3) - (i * k))) tmp = 0 if z <= -3.4e+152: tmp = t_1 elif z <= -2.3e+37: tmp = -z * (y3 * (c * y0)) elif z <= -3.7e-90: tmp = c * (y2 * ((x * y0) - (t * y4))) elif z <= 9e+41: tmp = a * (y5 * ((t * y2) - (y * y3))) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = Float64(y1 * Float64(z * Float64(Float64(a * y3) - Float64(i * k)))) tmp = 0.0 if (z <= -3.4e+152) tmp = t_1; elseif (z <= -2.3e+37) tmp = Float64(Float64(-z) * Float64(y3 * Float64(c * y0))); elseif (z <= -3.7e-90) tmp = Float64(c * Float64(y2 * Float64(Float64(x * y0) - Float64(t * y4)))); elseif (z <= 9e+41) tmp = Float64(a * Float64(y5 * Float64(Float64(t * y2) - Float64(y * y3)))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = y1 * (z * ((a * y3) - (i * k))); tmp = 0.0; if (z <= -3.4e+152) tmp = t_1; elseif (z <= -2.3e+37) tmp = -z * (y3 * (c * y0)); elseif (z <= -3.7e-90) tmp = c * (y2 * ((x * y0) - (t * y4))); elseif (z <= 9e+41) tmp = a * (y5 * ((t * y2) - (y * y3))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(y1 * N[(z * N[(N[(a * y3), $MachinePrecision] - N[(i * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -3.4e+152], t$95$1, If[LessEqual[z, -2.3e+37], N[((-z) * N[(y3 * N[(c * y0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -3.7e-90], N[(c * N[(y2 * N[(N[(x * y0), $MachinePrecision] - N[(t * y4), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 9e+41], N[(a * N[(y5 * N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y1 \cdot \left(z \cdot \left(a \cdot y3 - i \cdot k\right)\right)\\
\mathbf{if}\;z \leq -3.4 \cdot 10^{+152}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -2.3 \cdot 10^{+37}:\\
\;\;\;\;\left(-z\right) \cdot \left(y3 \cdot \left(c \cdot y0\right)\right)\\
\mathbf{elif}\;z \leq -3.7 \cdot 10^{-90}:\\
\;\;\;\;c \cdot \left(y2 \cdot \left(x \cdot y0 - t \cdot y4\right)\right)\\
\mathbf{elif}\;z \leq 9 \cdot 10^{+41}:\\
\;\;\;\;a \cdot \left(y5 \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -3.4000000000000002e152 or 9.0000000000000002e41 < z Initial program 22.0%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites52.7%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6444.6
Applied rewrites44.6%
if -3.4000000000000002e152 < z < -2.30000000000000002e37Initial program 34.9%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites36.4%
Taylor expanded in y3 around inf
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f6450.8
Applied rewrites50.8%
Taylor expanded in a around 0
lift-*.f6451.0
Applied rewrites51.0%
if -2.30000000000000002e37 < z < -3.70000000000000018e-90Initial program 24.1%
Taylor expanded in y2 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites43.9%
Taylor expanded in y1 around inf
lower-*.f64N/A
lower-*.f64N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-*.f6431.0
Applied rewrites31.0%
Taylor expanded in c around inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6444.2
Applied rewrites44.2%
if -3.70000000000000018e-90 < z < 9.0000000000000002e41Initial program 33.0%
Taylor expanded in y5 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites45.3%
Taylor expanded in a around -inf
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f6440.0
Applied rewrites40.0%
Final simplification43.3%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(if (<= z -2.4e-98)
(* b (* y0 (- (* k z) (* j x))))
(if (<= z 1.4e+42)
(* a (* y5 (- (* t y2) (* y y3))))
(if (<= z 2.5e+186)
(* k (* z (- (* b y0) (* i y1))))
(* c (* z (fma -1.0 (* y0 y3) (* i t))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -2.4e-98) {
tmp = b * (y0 * ((k * z) - (j * x)));
} else if (z <= 1.4e+42) {
tmp = a * (y5 * ((t * y2) - (y * y3)));
} else if (z <= 2.5e+186) {
tmp = k * (z * ((b * y0) - (i * y1)));
} else {
tmp = c * (z * fma(-1.0, (y0 * y3), (i * t)));
}
return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0 if (z <= -2.4e-98) tmp = Float64(b * Float64(y0 * Float64(Float64(k * z) - Float64(j * x)))); elseif (z <= 1.4e+42) tmp = Float64(a * Float64(y5 * Float64(Float64(t * y2) - Float64(y * y3)))); elseif (z <= 2.5e+186) tmp = Float64(k * Float64(z * Float64(Float64(b * y0) - Float64(i * y1)))); else tmp = Float64(c * Float64(z * fma(-1.0, Float64(y0 * y3), Float64(i * t)))); end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[z, -2.4e-98], N[(b * N[(y0 * N[(N[(k * z), $MachinePrecision] - N[(j * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.4e+42], N[(a * N[(y5 * N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.5e+186], N[(k * N[(z * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(c * N[(z * N[(-1.0 * N[(y0 * y3), $MachinePrecision] + N[(i * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.4 \cdot 10^{-98}:\\
\;\;\;\;b \cdot \left(y0 \cdot \left(k \cdot z - j \cdot x\right)\right)\\
\mathbf{elif}\;z \leq 1.4 \cdot 10^{+42}:\\
\;\;\;\;a \cdot \left(y5 \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\\
\mathbf{elif}\;z \leq 2.5 \cdot 10^{+186}:\\
\;\;\;\;k \cdot \left(z \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\
\mathbf{else}:\\
\;\;\;\;c \cdot \left(z \cdot \mathsf{fma}\left(-1, y0 \cdot y3, i \cdot t\right)\right)\\
\end{array}
\end{array}
if z < -2.40000000000000005e-98Initial program 25.6%
Taylor expanded in b around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites42.4%
Taylor expanded in y0 around inf
lower-*.f64N/A
lower--.f64N/A
lift-*.f64N/A
lift-*.f6442.6
Applied rewrites42.6%
if -2.40000000000000005e-98 < z < 1.4e42Initial program 32.3%
Taylor expanded in y5 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites45.8%
Taylor expanded in a around -inf
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f6440.4
Applied rewrites40.4%
if 1.4e42 < z < 2.49999999999999977e186Initial program 28.5%
Taylor expanded in k around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites54.9%
Taylor expanded in z around inf
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f6452.3
Applied rewrites52.3%
if 2.49999999999999977e186 < z Initial program 16.9%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites66.7%
Taylor expanded in c around -inf
lower-*.f64N/A
lower-*.f64N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-*.f6460.6
Applied rewrites60.6%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(if (<= x -1.1e+61)
(* x (* y2 (- (* c y0) (* a y1))))
(if (<= x 6.2e-292)
(* i (* k (- (* y y5) (* y1 z))))
(if (<= x 7.5e+84)
(* y1 (* z (- (* a y3) (* i k))))
(* c (* y2 (- (* x y0) (* t y4))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (x <= -1.1e+61) {
tmp = x * (y2 * ((c * y0) - (a * y1)));
} else if (x <= 6.2e-292) {
tmp = i * (k * ((y * y5) - (y1 * z)));
} else if (x <= 7.5e+84) {
tmp = y1 * (z * ((a * y3) - (i * k)));
} else {
tmp = c * (y2 * ((x * y0) - (t * y4)));
}
return tmp;
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
real(8) :: tmp
if (x <= (-1.1d+61)) then
tmp = x * (y2 * ((c * y0) - (a * y1)))
else if (x <= 6.2d-292) then
tmp = i * (k * ((y * y5) - (y1 * z)))
else if (x <= 7.5d+84) then
tmp = y1 * (z * ((a * y3) - (i * k)))
else
tmp = c * (y2 * ((x * y0) - (t * y4)))
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, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (x <= -1.1e+61) {
tmp = x * (y2 * ((c * y0) - (a * y1)));
} else if (x <= 6.2e-292) {
tmp = i * (k * ((y * y5) - (y1 * z)));
} else if (x <= 7.5e+84) {
tmp = y1 * (z * ((a * y3) - (i * k)));
} else {
tmp = c * (y2 * ((x * y0) - (t * y4)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): tmp = 0 if x <= -1.1e+61: tmp = x * (y2 * ((c * y0) - (a * y1))) elif x <= 6.2e-292: tmp = i * (k * ((y * y5) - (y1 * z))) elif x <= 7.5e+84: tmp = y1 * (z * ((a * y3) - (i * k))) else: tmp = c * (y2 * ((x * y0) - (t * y4))) return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0 if (x <= -1.1e+61) tmp = Float64(x * Float64(y2 * Float64(Float64(c * y0) - Float64(a * y1)))); elseif (x <= 6.2e-292) tmp = Float64(i * Float64(k * Float64(Float64(y * y5) - Float64(y1 * z)))); elseif (x <= 7.5e+84) tmp = Float64(y1 * Float64(z * Float64(Float64(a * y3) - Float64(i * k)))); else tmp = Float64(c * Float64(y2 * Float64(Float64(x * y0) - Float64(t * y4)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0; if (x <= -1.1e+61) tmp = x * (y2 * ((c * y0) - (a * y1))); elseif (x <= 6.2e-292) tmp = i * (k * ((y * y5) - (y1 * z))); elseif (x <= 7.5e+84) tmp = y1 * (z * ((a * y3) - (i * k))); else tmp = c * (y2 * ((x * y0) - (t * y4))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[x, -1.1e+61], N[(x * N[(y2 * N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 6.2e-292], N[(i * N[(k * N[(N[(y * y5), $MachinePrecision] - N[(y1 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 7.5e+84], N[(y1 * N[(z * N[(N[(a * y3), $MachinePrecision] - N[(i * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(c * N[(y2 * N[(N[(x * y0), $MachinePrecision] - N[(t * y4), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.1 \cdot 10^{+61}:\\
\;\;\;\;x \cdot \left(y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right)\\
\mathbf{elif}\;x \leq 6.2 \cdot 10^{-292}:\\
\;\;\;\;i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right)\\
\mathbf{elif}\;x \leq 7.5 \cdot 10^{+84}:\\
\;\;\;\;y1 \cdot \left(z \cdot \left(a \cdot y3 - i \cdot k\right)\right)\\
\mathbf{else}:\\
\;\;\;\;c \cdot \left(y2 \cdot \left(x \cdot y0 - t \cdot y4\right)\right)\\
\end{array}
\end{array}
if x < -1.1e61Initial program 17.6%
Taylor expanded in y2 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites50.1%
Taylor expanded in x around inf
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f6455.8
Applied rewrites55.8%
if -1.1e61 < x < 6.1999999999999999e-292Initial program 38.5%
Taylor expanded in k around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites49.8%
Taylor expanded in i around inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6440.8
Applied rewrites40.8%
if 6.1999999999999999e-292 < x < 7.5000000000000001e84Initial program 30.1%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites43.5%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6432.6
Applied rewrites32.6%
if 7.5000000000000001e84 < x Initial program 13.7%
Taylor expanded in y2 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites45.3%
Taylor expanded in y1 around inf
lower-*.f64N/A
lower-*.f64N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-*.f6438.5
Applied rewrites38.5%
Taylor expanded in c around inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6445.3
Applied rewrites45.3%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(let* ((t_1 (* y1 (* z (- (* a y3) (* i k))))))
(if (<= z -3.4e+152)
t_1
(if (<= z -7.5e-46)
(* (- z) (* y3 (* c y0)))
(if (<= z 9e+41) (* a (* y5 (- (* t y2) (* y y3)))) t_1)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = y1 * (z * ((a * y3) - (i * k)));
double tmp;
if (z <= -3.4e+152) {
tmp = t_1;
} else if (z <= -7.5e-46) {
tmp = -z * (y3 * (c * y0));
} else if (z <= 9e+41) {
tmp = a * (y5 * ((t * y2) - (y * y3)));
} else {
tmp = t_1;
}
return tmp;
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
real(8) :: t_1
real(8) :: tmp
t_1 = y1 * (z * ((a * y3) - (i * k)))
if (z <= (-3.4d+152)) then
tmp = t_1
else if (z <= (-7.5d-46)) then
tmp = -z * (y3 * (c * y0))
else if (z <= 9d+41) then
tmp = a * (y5 * ((t * y2) - (y * y3)))
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, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = y1 * (z * ((a * y3) - (i * k)));
double tmp;
if (z <= -3.4e+152) {
tmp = t_1;
} else if (z <= -7.5e-46) {
tmp = -z * (y3 * (c * y0));
} else if (z <= 9e+41) {
tmp = a * (y5 * ((t * y2) - (y * y3)));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): t_1 = y1 * (z * ((a * y3) - (i * k))) tmp = 0 if z <= -3.4e+152: tmp = t_1 elif z <= -7.5e-46: tmp = -z * (y3 * (c * y0)) elif z <= 9e+41: tmp = a * (y5 * ((t * y2) - (y * y3))) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = Float64(y1 * Float64(z * Float64(Float64(a * y3) - Float64(i * k)))) tmp = 0.0 if (z <= -3.4e+152) tmp = t_1; elseif (z <= -7.5e-46) tmp = Float64(Float64(-z) * Float64(y3 * Float64(c * y0))); elseif (z <= 9e+41) tmp = Float64(a * Float64(y5 * Float64(Float64(t * y2) - Float64(y * y3)))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = y1 * (z * ((a * y3) - (i * k))); tmp = 0.0; if (z <= -3.4e+152) tmp = t_1; elseif (z <= -7.5e-46) tmp = -z * (y3 * (c * y0)); elseif (z <= 9e+41) tmp = a * (y5 * ((t * y2) - (y * y3))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(y1 * N[(z * N[(N[(a * y3), $MachinePrecision] - N[(i * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -3.4e+152], t$95$1, If[LessEqual[z, -7.5e-46], N[((-z) * N[(y3 * N[(c * y0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 9e+41], N[(a * N[(y5 * N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y1 \cdot \left(z \cdot \left(a \cdot y3 - i \cdot k\right)\right)\\
\mathbf{if}\;z \leq -3.4 \cdot 10^{+152}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -7.5 \cdot 10^{-46}:\\
\;\;\;\;\left(-z\right) \cdot \left(y3 \cdot \left(c \cdot y0\right)\right)\\
\mathbf{elif}\;z \leq 9 \cdot 10^{+41}:\\
\;\;\;\;a \cdot \left(y5 \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -3.4000000000000002e152 or 9.0000000000000002e41 < z Initial program 22.0%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites52.7%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6444.6
Applied rewrites44.6%
if -3.4000000000000002e152 < z < -7.50000000000000027e-46Initial program 25.3%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites32.2%
Taylor expanded in y3 around inf
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f6440.3
Applied rewrites40.3%
Taylor expanded in a around 0
lift-*.f6435.0
Applied rewrites35.0%
if -7.50000000000000027e-46 < z < 9.0000000000000002e41Initial program 33.4%
Taylor expanded in y5 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites44.2%
Taylor expanded in a around -inf
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f6438.8
Applied rewrites38.8%
Final simplification40.7%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(if (<= z -1.35e+209)
(* a (* y1 (* y3 z)))
(if (<= z -7.5e-46)
(* (- z) (* y3 (* c y0)))
(if (<= z 3e+93)
(* a (* y5 (- (* t y2) (* y y3))))
(* i (* z (- (* c t) (* k y1))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -1.35e+209) {
tmp = a * (y1 * (y3 * z));
} else if (z <= -7.5e-46) {
tmp = -z * (y3 * (c * y0));
} else if (z <= 3e+93) {
tmp = a * (y5 * ((t * y2) - (y * y3)));
} else {
tmp = i * (z * ((c * t) - (k * y1)));
}
return tmp;
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
real(8) :: tmp
if (z <= (-1.35d+209)) then
tmp = a * (y1 * (y3 * z))
else if (z <= (-7.5d-46)) then
tmp = -z * (y3 * (c * y0))
else if (z <= 3d+93) then
tmp = a * (y5 * ((t * y2) - (y * y3)))
else
tmp = i * (z * ((c * t) - (k * y1)))
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, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -1.35e+209) {
tmp = a * (y1 * (y3 * z));
} else if (z <= -7.5e-46) {
tmp = -z * (y3 * (c * y0));
} else if (z <= 3e+93) {
tmp = a * (y5 * ((t * y2) - (y * y3)));
} else {
tmp = i * (z * ((c * t) - (k * y1)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): tmp = 0 if z <= -1.35e+209: tmp = a * (y1 * (y3 * z)) elif z <= -7.5e-46: tmp = -z * (y3 * (c * y0)) elif z <= 3e+93: tmp = a * (y5 * ((t * y2) - (y * y3))) else: tmp = i * (z * ((c * t) - (k * y1))) return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0 if (z <= -1.35e+209) tmp = Float64(a * Float64(y1 * Float64(y3 * z))); elseif (z <= -7.5e-46) tmp = Float64(Float64(-z) * Float64(y3 * Float64(c * y0))); elseif (z <= 3e+93) tmp = Float64(a * Float64(y5 * Float64(Float64(t * y2) - Float64(y * y3)))); else tmp = Float64(i * Float64(z * Float64(Float64(c * t) - Float64(k * y1)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0; if (z <= -1.35e+209) tmp = a * (y1 * (y3 * z)); elseif (z <= -7.5e-46) tmp = -z * (y3 * (c * y0)); elseif (z <= 3e+93) tmp = a * (y5 * ((t * y2) - (y * y3))); else tmp = i * (z * ((c * t) - (k * y1))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[z, -1.35e+209], N[(a * N[(y1 * N[(y3 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -7.5e-46], N[((-z) * N[(y3 * N[(c * y0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 3e+93], N[(a * N[(y5 * N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(i * N[(z * N[(N[(c * t), $MachinePrecision] - N[(k * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.35 \cdot 10^{+209}:\\
\;\;\;\;a \cdot \left(y1 \cdot \left(y3 \cdot z\right)\right)\\
\mathbf{elif}\;z \leq -7.5 \cdot 10^{-46}:\\
\;\;\;\;\left(-z\right) \cdot \left(y3 \cdot \left(c \cdot y0\right)\right)\\
\mathbf{elif}\;z \leq 3 \cdot 10^{+93}:\\
\;\;\;\;a \cdot \left(y5 \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\\
\mathbf{else}:\\
\;\;\;\;i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)\\
\end{array}
\end{array}
if z < -1.35e209Initial program 21.7%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites48.3%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6448.3
Applied rewrites48.3%
Taylor expanded in a around inf
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6453.0
Applied rewrites53.0%
if -1.35e209 < z < -7.50000000000000027e-46Initial program 23.0%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites39.1%
Taylor expanded in y3 around inf
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f6439.9
Applied rewrites39.9%
Taylor expanded in a around 0
lift-*.f6432.5
Applied rewrites32.5%
if -7.50000000000000027e-46 < z < 2.99999999999999978e93Initial program 33.9%
Taylor expanded in y5 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites42.7%
Taylor expanded in a around -inf
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f6437.2
Applied rewrites37.2%
if 2.99999999999999978e93 < z Initial program 18.5%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites59.2%
Taylor expanded in i around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6444.5
Applied rewrites44.5%
Final simplification39.1%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(if (<= z -1.35e+209)
(* a (* y1 (* y3 z)))
(if (<= z -7.5e-46)
(* (- z) (* y3 (* c y0)))
(if (<= z 1.08e+94)
(* a (* y5 (- (* t y2) (* y y3))))
(* y1 (* (- i) (* k z)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -1.35e+209) {
tmp = a * (y1 * (y3 * z));
} else if (z <= -7.5e-46) {
tmp = -z * (y3 * (c * y0));
} else if (z <= 1.08e+94) {
tmp = a * (y5 * ((t * y2) - (y * y3)));
} else {
tmp = y1 * (-i * (k * z));
}
return tmp;
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
real(8) :: tmp
if (z <= (-1.35d+209)) then
tmp = a * (y1 * (y3 * z))
else if (z <= (-7.5d-46)) then
tmp = -z * (y3 * (c * y0))
else if (z <= 1.08d+94) then
tmp = a * (y5 * ((t * y2) - (y * y3)))
else
tmp = y1 * (-i * (k * z))
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, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -1.35e+209) {
tmp = a * (y1 * (y3 * z));
} else if (z <= -7.5e-46) {
tmp = -z * (y3 * (c * y0));
} else if (z <= 1.08e+94) {
tmp = a * (y5 * ((t * y2) - (y * y3)));
} else {
tmp = y1 * (-i * (k * z));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): tmp = 0 if z <= -1.35e+209: tmp = a * (y1 * (y3 * z)) elif z <= -7.5e-46: tmp = -z * (y3 * (c * y0)) elif z <= 1.08e+94: tmp = a * (y5 * ((t * y2) - (y * y3))) else: tmp = y1 * (-i * (k * z)) return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0 if (z <= -1.35e+209) tmp = Float64(a * Float64(y1 * Float64(y3 * z))); elseif (z <= -7.5e-46) tmp = Float64(Float64(-z) * Float64(y3 * Float64(c * y0))); elseif (z <= 1.08e+94) tmp = Float64(a * Float64(y5 * Float64(Float64(t * y2) - Float64(y * y3)))); else tmp = Float64(y1 * Float64(Float64(-i) * Float64(k * z))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0; if (z <= -1.35e+209) tmp = a * (y1 * (y3 * z)); elseif (z <= -7.5e-46) tmp = -z * (y3 * (c * y0)); elseif (z <= 1.08e+94) tmp = a * (y5 * ((t * y2) - (y * y3))); else tmp = y1 * (-i * (k * z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[z, -1.35e+209], N[(a * N[(y1 * N[(y3 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -7.5e-46], N[((-z) * N[(y3 * N[(c * y0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.08e+94], N[(a * N[(y5 * N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y1 * N[((-i) * N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.35 \cdot 10^{+209}:\\
\;\;\;\;a \cdot \left(y1 \cdot \left(y3 \cdot z\right)\right)\\
\mathbf{elif}\;z \leq -7.5 \cdot 10^{-46}:\\
\;\;\;\;\left(-z\right) \cdot \left(y3 \cdot \left(c \cdot y0\right)\right)\\
\mathbf{elif}\;z \leq 1.08 \cdot 10^{+94}:\\
\;\;\;\;a \cdot \left(y5 \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\\
\mathbf{else}:\\
\;\;\;\;y1 \cdot \left(\left(-i\right) \cdot \left(k \cdot z\right)\right)\\
\end{array}
\end{array}
if z < -1.35e209Initial program 21.7%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites48.3%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6448.3
Applied rewrites48.3%
Taylor expanded in a around inf
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6453.0
Applied rewrites53.0%
if -1.35e209 < z < -7.50000000000000027e-46Initial program 23.0%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites39.1%
Taylor expanded in y3 around inf
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f6439.9
Applied rewrites39.9%
Taylor expanded in a around 0
lift-*.f6432.5
Applied rewrites32.5%
if -7.50000000000000027e-46 < z < 1.08e94Initial program 33.9%
Taylor expanded in y5 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites42.7%
Taylor expanded in a around -inf
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f6437.2
Applied rewrites37.2%
if 1.08e94 < z Initial program 18.5%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites59.2%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6451.9
Applied rewrites51.9%
Taylor expanded in a around 0
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6442.1
Applied rewrites42.1%
Final simplification38.6%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(if (<= z -1.35e+209)
(* a (* y1 (* y3 z)))
(if (<= z -7.4e+15)
(* (- z) (* y3 (* c y0)))
(if (<= z 1.08e+94) (* y1 (* y2 (* (- a) x))) (* y1 (* (- i) (* k z)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -1.35e+209) {
tmp = a * (y1 * (y3 * z));
} else if (z <= -7.4e+15) {
tmp = -z * (y3 * (c * y0));
} else if (z <= 1.08e+94) {
tmp = y1 * (y2 * (-a * x));
} else {
tmp = y1 * (-i * (k * z));
}
return tmp;
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
real(8) :: tmp
if (z <= (-1.35d+209)) then
tmp = a * (y1 * (y3 * z))
else if (z <= (-7.4d+15)) then
tmp = -z * (y3 * (c * y0))
else if (z <= 1.08d+94) then
tmp = y1 * (y2 * (-a * x))
else
tmp = y1 * (-i * (k * z))
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, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -1.35e+209) {
tmp = a * (y1 * (y3 * z));
} else if (z <= -7.4e+15) {
tmp = -z * (y3 * (c * y0));
} else if (z <= 1.08e+94) {
tmp = y1 * (y2 * (-a * x));
} else {
tmp = y1 * (-i * (k * z));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): tmp = 0 if z <= -1.35e+209: tmp = a * (y1 * (y3 * z)) elif z <= -7.4e+15: tmp = -z * (y3 * (c * y0)) elif z <= 1.08e+94: tmp = y1 * (y2 * (-a * x)) else: tmp = y1 * (-i * (k * z)) return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0 if (z <= -1.35e+209) tmp = Float64(a * Float64(y1 * Float64(y3 * z))); elseif (z <= -7.4e+15) tmp = Float64(Float64(-z) * Float64(y3 * Float64(c * y0))); elseif (z <= 1.08e+94) tmp = Float64(y1 * Float64(y2 * Float64(Float64(-a) * x))); else tmp = Float64(y1 * Float64(Float64(-i) * Float64(k * z))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0; if (z <= -1.35e+209) tmp = a * (y1 * (y3 * z)); elseif (z <= -7.4e+15) tmp = -z * (y3 * (c * y0)); elseif (z <= 1.08e+94) tmp = y1 * (y2 * (-a * x)); else tmp = y1 * (-i * (k * z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[z, -1.35e+209], N[(a * N[(y1 * N[(y3 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -7.4e+15], N[((-z) * N[(y3 * N[(c * y0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.08e+94], N[(y1 * N[(y2 * N[((-a) * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y1 * N[((-i) * N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.35 \cdot 10^{+209}:\\
\;\;\;\;a \cdot \left(y1 \cdot \left(y3 \cdot z\right)\right)\\
\mathbf{elif}\;z \leq -7.4 \cdot 10^{+15}:\\
\;\;\;\;\left(-z\right) \cdot \left(y3 \cdot \left(c \cdot y0\right)\right)\\
\mathbf{elif}\;z \leq 1.08 \cdot 10^{+94}:\\
\;\;\;\;y1 \cdot \left(y2 \cdot \left(\left(-a\right) \cdot x\right)\right)\\
\mathbf{else}:\\
\;\;\;\;y1 \cdot \left(\left(-i\right) \cdot \left(k \cdot z\right)\right)\\
\end{array}
\end{array}
if z < -1.35e209Initial program 21.7%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites48.3%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6448.3
Applied rewrites48.3%
Taylor expanded in a around inf
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6453.0
Applied rewrites53.0%
if -1.35e209 < z < -7.4e15Initial program 28.1%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites45.4%
Taylor expanded in y3 around inf
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f6443.9
Applied rewrites43.9%
Taylor expanded in a around 0
lift-*.f6437.0
Applied rewrites37.0%
if -7.4e15 < z < 1.08e94Initial program 31.5%
Taylor expanded in y2 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites41.0%
Taylor expanded in y1 around inf
lower-*.f64N/A
lower-*.f64N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-*.f6432.1
Applied rewrites32.1%
Taylor expanded in x around inf
lower-*.f64N/A
lift-*.f6421.7
Applied rewrites21.7%
if 1.08e94 < z Initial program 18.5%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites59.2%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6451.9
Applied rewrites51.9%
Taylor expanded in a around 0
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6442.1
Applied rewrites42.1%
Final simplification31.0%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(if (<= z -2.3e+209)
(* a (* y1 (* y3 z)))
(if (<= z -7.4e+15)
(* (- z) (* c (* y0 y3)))
(if (<= z 1.08e+94) (* y1 (* y2 (* (- a) x))) (* y1 (* (- i) (* k z)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -2.3e+209) {
tmp = a * (y1 * (y3 * z));
} else if (z <= -7.4e+15) {
tmp = -z * (c * (y0 * y3));
} else if (z <= 1.08e+94) {
tmp = y1 * (y2 * (-a * x));
} else {
tmp = y1 * (-i * (k * z));
}
return tmp;
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
real(8) :: tmp
if (z <= (-2.3d+209)) then
tmp = a * (y1 * (y3 * z))
else if (z <= (-7.4d+15)) then
tmp = -z * (c * (y0 * y3))
else if (z <= 1.08d+94) then
tmp = y1 * (y2 * (-a * x))
else
tmp = y1 * (-i * (k * z))
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, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -2.3e+209) {
tmp = a * (y1 * (y3 * z));
} else if (z <= -7.4e+15) {
tmp = -z * (c * (y0 * y3));
} else if (z <= 1.08e+94) {
tmp = y1 * (y2 * (-a * x));
} else {
tmp = y1 * (-i * (k * z));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): tmp = 0 if z <= -2.3e+209: tmp = a * (y1 * (y3 * z)) elif z <= -7.4e+15: tmp = -z * (c * (y0 * y3)) elif z <= 1.08e+94: tmp = y1 * (y2 * (-a * x)) else: tmp = y1 * (-i * (k * z)) return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0 if (z <= -2.3e+209) tmp = Float64(a * Float64(y1 * Float64(y3 * z))); elseif (z <= -7.4e+15) tmp = Float64(Float64(-z) * Float64(c * Float64(y0 * y3))); elseif (z <= 1.08e+94) tmp = Float64(y1 * Float64(y2 * Float64(Float64(-a) * x))); else tmp = Float64(y1 * Float64(Float64(-i) * Float64(k * z))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0; if (z <= -2.3e+209) tmp = a * (y1 * (y3 * z)); elseif (z <= -7.4e+15) tmp = -z * (c * (y0 * y3)); elseif (z <= 1.08e+94) tmp = y1 * (y2 * (-a * x)); else tmp = y1 * (-i * (k * z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[z, -2.3e+209], N[(a * N[(y1 * N[(y3 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -7.4e+15], N[((-z) * N[(c * N[(y0 * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.08e+94], N[(y1 * N[(y2 * N[((-a) * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y1 * N[((-i) * N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.3 \cdot 10^{+209}:\\
\;\;\;\;a \cdot \left(y1 \cdot \left(y3 \cdot z\right)\right)\\
\mathbf{elif}\;z \leq -7.4 \cdot 10^{+15}:\\
\;\;\;\;\left(-z\right) \cdot \left(c \cdot \left(y0 \cdot y3\right)\right)\\
\mathbf{elif}\;z \leq 1.08 \cdot 10^{+94}:\\
\;\;\;\;y1 \cdot \left(y2 \cdot \left(\left(-a\right) \cdot x\right)\right)\\
\mathbf{else}:\\
\;\;\;\;y1 \cdot \left(\left(-i\right) \cdot \left(k \cdot z\right)\right)\\
\end{array}
\end{array}
if z < -2.3000000000000001e209Initial program 21.7%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites48.3%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6448.3
Applied rewrites48.3%
Taylor expanded in a around inf
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6453.0
Applied rewrites53.0%
if -2.3000000000000001e209 < z < -7.4e15Initial program 28.1%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites45.4%
Taylor expanded in y3 around inf
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f6443.9
Applied rewrites43.9%
Taylor expanded in a around 0
lower-*.f64N/A
lower-*.f6435.0
Applied rewrites35.0%
if -7.4e15 < z < 1.08e94Initial program 31.5%
Taylor expanded in y2 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites41.0%
Taylor expanded in y1 around inf
lower-*.f64N/A
lower-*.f64N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-*.f6432.1
Applied rewrites32.1%
Taylor expanded in x around inf
lower-*.f64N/A
lift-*.f6421.7
Applied rewrites21.7%
if 1.08e94 < z Initial program 18.5%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites59.2%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6451.9
Applied rewrites51.9%
Taylor expanded in a around 0
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6442.1
Applied rewrites42.1%
Final simplification30.7%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(if (<= z -2.6e+126)
(* a (* y1 (* y3 z)))
(if (<= z 5.2e+111)
(* y1 (* k (* y2 y4)))
(if (<= z 5.8e+187) (* i (* (- k) (* y1 z))) (* c (* i (* t z)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -2.6e+126) {
tmp = a * (y1 * (y3 * z));
} else if (z <= 5.2e+111) {
tmp = y1 * (k * (y2 * y4));
} else if (z <= 5.8e+187) {
tmp = i * (-k * (y1 * z));
} else {
tmp = c * (i * (t * z));
}
return tmp;
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
real(8) :: tmp
if (z <= (-2.6d+126)) then
tmp = a * (y1 * (y3 * z))
else if (z <= 5.2d+111) then
tmp = y1 * (k * (y2 * y4))
else if (z <= 5.8d+187) then
tmp = i * (-k * (y1 * z))
else
tmp = c * (i * (t * z))
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, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -2.6e+126) {
tmp = a * (y1 * (y3 * z));
} else if (z <= 5.2e+111) {
tmp = y1 * (k * (y2 * y4));
} else if (z <= 5.8e+187) {
tmp = i * (-k * (y1 * z));
} else {
tmp = c * (i * (t * z));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): tmp = 0 if z <= -2.6e+126: tmp = a * (y1 * (y3 * z)) elif z <= 5.2e+111: tmp = y1 * (k * (y2 * y4)) elif z <= 5.8e+187: tmp = i * (-k * (y1 * z)) else: tmp = c * (i * (t * z)) return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0 if (z <= -2.6e+126) tmp = Float64(a * Float64(y1 * Float64(y3 * z))); elseif (z <= 5.2e+111) tmp = Float64(y1 * Float64(k * Float64(y2 * y4))); elseif (z <= 5.8e+187) tmp = Float64(i * Float64(Float64(-k) * Float64(y1 * z))); else tmp = Float64(c * Float64(i * Float64(t * z))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0; if (z <= -2.6e+126) tmp = a * (y1 * (y3 * z)); elseif (z <= 5.2e+111) tmp = y1 * (k * (y2 * y4)); elseif (z <= 5.8e+187) tmp = i * (-k * (y1 * z)); else tmp = c * (i * (t * z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[z, -2.6e+126], N[(a * N[(y1 * N[(y3 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5.2e+111], N[(y1 * N[(k * N[(y2 * y4), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5.8e+187], N[(i * N[((-k) * N[(y1 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(c * N[(i * N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.6 \cdot 10^{+126}:\\
\;\;\;\;a \cdot \left(y1 \cdot \left(y3 \cdot z\right)\right)\\
\mathbf{elif}\;z \leq 5.2 \cdot 10^{+111}:\\
\;\;\;\;y1 \cdot \left(k \cdot \left(y2 \cdot y4\right)\right)\\
\mathbf{elif}\;z \leq 5.8 \cdot 10^{+187}:\\
\;\;\;\;i \cdot \left(\left(-k\right) \cdot \left(y1 \cdot z\right)\right)\\
\mathbf{else}:\\
\;\;\;\;c \cdot \left(i \cdot \left(t \cdot z\right)\right)\\
\end{array}
\end{array}
if z < -2.6e126Initial program 24.6%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites49.7%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6440.9
Applied rewrites40.9%
Taylor expanded in a around inf
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6443.3
Applied rewrites43.3%
if -2.6e126 < z < 5.1999999999999997e111Initial program 30.4%
Taylor expanded in y2 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites40.4%
Taylor expanded in y1 around inf
lower-*.f64N/A
lower-*.f64N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-*.f6431.7
Applied rewrites31.7%
Taylor expanded in x around 0
lower-*.f64N/A
lower-*.f6420.6
Applied rewrites20.6%
if 5.1999999999999997e111 < z < 5.8000000000000002e187Initial program 31.2%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites62.4%
Taylor expanded in i around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6445.3
Applied rewrites45.3%
Taylor expanded in t around 0
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6464.1
Applied rewrites64.1%
if 5.8000000000000002e187 < z Initial program 14.0%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites65.6%
Taylor expanded in i around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6446.7
Applied rewrites46.7%
Taylor expanded in t around inf
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6438.8
Applied rewrites38.8%
Final simplification29.4%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(if (<= z -2.4e-98)
(* b (* y0 (- (* k z) (* j x))))
(if (<= z 1.4e+42)
(* a (* y5 (- (* t y2) (* y y3))))
(* k (* z (- (* b y0) (* i y1)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -2.4e-98) {
tmp = b * (y0 * ((k * z) - (j * x)));
} else if (z <= 1.4e+42) {
tmp = a * (y5 * ((t * y2) - (y * y3)));
} else {
tmp = k * (z * ((b * y0) - (i * y1)));
}
return tmp;
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
real(8) :: tmp
if (z <= (-2.4d-98)) then
tmp = b * (y0 * ((k * z) - (j * x)))
else if (z <= 1.4d+42) then
tmp = a * (y5 * ((t * y2) - (y * y3)))
else
tmp = k * (z * ((b * y0) - (i * y1)))
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, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -2.4e-98) {
tmp = b * (y0 * ((k * z) - (j * x)));
} else if (z <= 1.4e+42) {
tmp = a * (y5 * ((t * y2) - (y * y3)));
} else {
tmp = k * (z * ((b * y0) - (i * y1)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): tmp = 0 if z <= -2.4e-98: tmp = b * (y0 * ((k * z) - (j * x))) elif z <= 1.4e+42: tmp = a * (y5 * ((t * y2) - (y * y3))) else: tmp = k * (z * ((b * y0) - (i * y1))) return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0 if (z <= -2.4e-98) tmp = Float64(b * Float64(y0 * Float64(Float64(k * z) - Float64(j * x)))); elseif (z <= 1.4e+42) tmp = Float64(a * Float64(y5 * Float64(Float64(t * y2) - Float64(y * y3)))); else tmp = Float64(k * Float64(z * Float64(Float64(b * y0) - Float64(i * y1)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0; if (z <= -2.4e-98) tmp = b * (y0 * ((k * z) - (j * x))); elseif (z <= 1.4e+42) tmp = a * (y5 * ((t * y2) - (y * y3))); else tmp = k * (z * ((b * y0) - (i * y1))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[z, -2.4e-98], N[(b * N[(y0 * N[(N[(k * z), $MachinePrecision] - N[(j * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.4e+42], N[(a * N[(y5 * N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(k * N[(z * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.4 \cdot 10^{-98}:\\
\;\;\;\;b \cdot \left(y0 \cdot \left(k \cdot z - j \cdot x\right)\right)\\
\mathbf{elif}\;z \leq 1.4 \cdot 10^{+42}:\\
\;\;\;\;a \cdot \left(y5 \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\\
\mathbf{else}:\\
\;\;\;\;k \cdot \left(z \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\
\end{array}
\end{array}
if z < -2.40000000000000005e-98Initial program 25.6%
Taylor expanded in b around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites42.4%
Taylor expanded in y0 around inf
lower-*.f64N/A
lower--.f64N/A
lift-*.f64N/A
lift-*.f6442.6
Applied rewrites42.6%
if -2.40000000000000005e-98 < z < 1.4e42Initial program 32.3%
Taylor expanded in y5 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites45.8%
Taylor expanded in a around -inf
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f6440.4
Applied rewrites40.4%
if 1.4e42 < z Initial program 23.1%
Taylor expanded in k around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites49.8%
Taylor expanded in z around inf
lift-*.f64N/A
lift-*.f64N/A
lift--.f64N/A
lift-*.f6448.6
Applied rewrites48.6%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(if (<= z -2.4e-98)
(* b (* y0 (- (* k z) (* j x))))
(if (<= z 9e+41)
(* a (* y5 (- (* t y2) (* y y3))))
(* y1 (* z (- (* a y3) (* i k)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -2.4e-98) {
tmp = b * (y0 * ((k * z) - (j * x)));
} else if (z <= 9e+41) {
tmp = a * (y5 * ((t * y2) - (y * y3)));
} else {
tmp = y1 * (z * ((a * y3) - (i * k)));
}
return tmp;
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
real(8) :: tmp
if (z <= (-2.4d-98)) then
tmp = b * (y0 * ((k * z) - (j * x)))
else if (z <= 9d+41) then
tmp = a * (y5 * ((t * y2) - (y * y3)))
else
tmp = y1 * (z * ((a * y3) - (i * k)))
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, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -2.4e-98) {
tmp = b * (y0 * ((k * z) - (j * x)));
} else if (z <= 9e+41) {
tmp = a * (y5 * ((t * y2) - (y * y3)));
} else {
tmp = y1 * (z * ((a * y3) - (i * k)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): tmp = 0 if z <= -2.4e-98: tmp = b * (y0 * ((k * z) - (j * x))) elif z <= 9e+41: tmp = a * (y5 * ((t * y2) - (y * y3))) else: tmp = y1 * (z * ((a * y3) - (i * k))) return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0 if (z <= -2.4e-98) tmp = Float64(b * Float64(y0 * Float64(Float64(k * z) - Float64(j * x)))); elseif (z <= 9e+41) tmp = Float64(a * Float64(y5 * Float64(Float64(t * y2) - Float64(y * y3)))); else tmp = Float64(y1 * Float64(z * Float64(Float64(a * y3) - Float64(i * k)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0; if (z <= -2.4e-98) tmp = b * (y0 * ((k * z) - (j * x))); elseif (z <= 9e+41) tmp = a * (y5 * ((t * y2) - (y * y3))); else tmp = y1 * (z * ((a * y3) - (i * k))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[z, -2.4e-98], N[(b * N[(y0 * N[(N[(k * z), $MachinePrecision] - N[(j * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 9e+41], N[(a * N[(y5 * N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y1 * N[(z * N[(N[(a * y3), $MachinePrecision] - N[(i * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.4 \cdot 10^{-98}:\\
\;\;\;\;b \cdot \left(y0 \cdot \left(k \cdot z - j \cdot x\right)\right)\\
\mathbf{elif}\;z \leq 9 \cdot 10^{+41}:\\
\;\;\;\;a \cdot \left(y5 \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\\
\mathbf{else}:\\
\;\;\;\;y1 \cdot \left(z \cdot \left(a \cdot y3 - i \cdot k\right)\right)\\
\end{array}
\end{array}
if z < -2.40000000000000005e-98Initial program 25.6%
Taylor expanded in b around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites42.4%
Taylor expanded in y0 around inf
lower-*.f64N/A
lower--.f64N/A
lift-*.f64N/A
lift-*.f6442.6
Applied rewrites42.6%
if -2.40000000000000005e-98 < z < 9.0000000000000002e41Initial program 32.3%
Taylor expanded in y5 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites45.8%
Taylor expanded in a around -inf
lower-*.f64N/A
lower-*.f64N/A
lift-*.f64N/A
lift-*.f64N/A
lift--.f6440.4
Applied rewrites40.4%
if 9.0000000000000002e41 < z Initial program 23.1%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites53.9%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6445.6
Applied rewrites45.6%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5) :precision binary64 (if (<= z -4.5e+16) (* a (* y1 (* y3 z))) (if (<= z 1.08e+94) (* y1 (* y2 (* (- a) x))) (* y1 (* (- i) (* k z))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -4.5e+16) {
tmp = a * (y1 * (y3 * z));
} else if (z <= 1.08e+94) {
tmp = y1 * (y2 * (-a * x));
} else {
tmp = y1 * (-i * (k * z));
}
return tmp;
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
real(8) :: tmp
if (z <= (-4.5d+16)) then
tmp = a * (y1 * (y3 * z))
else if (z <= 1.08d+94) then
tmp = y1 * (y2 * (-a * x))
else
tmp = y1 * (-i * (k * z))
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, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -4.5e+16) {
tmp = a * (y1 * (y3 * z));
} else if (z <= 1.08e+94) {
tmp = y1 * (y2 * (-a * x));
} else {
tmp = y1 * (-i * (k * z));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): tmp = 0 if z <= -4.5e+16: tmp = a * (y1 * (y3 * z)) elif z <= 1.08e+94: tmp = y1 * (y2 * (-a * x)) else: tmp = y1 * (-i * (k * z)) return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0 if (z <= -4.5e+16) tmp = Float64(a * Float64(y1 * Float64(y3 * z))); elseif (z <= 1.08e+94) tmp = Float64(y1 * Float64(y2 * Float64(Float64(-a) * x))); else tmp = Float64(y1 * Float64(Float64(-i) * Float64(k * z))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0; if (z <= -4.5e+16) tmp = a * (y1 * (y3 * z)); elseif (z <= 1.08e+94) tmp = y1 * (y2 * (-a * x)); else tmp = y1 * (-i * (k * z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[z, -4.5e+16], N[(a * N[(y1 * N[(y3 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.08e+94], N[(y1 * N[(y2 * N[((-a) * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y1 * N[((-i) * N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -4.5 \cdot 10^{+16}:\\
\;\;\;\;a \cdot \left(y1 \cdot \left(y3 \cdot z\right)\right)\\
\mathbf{elif}\;z \leq 1.08 \cdot 10^{+94}:\\
\;\;\;\;y1 \cdot \left(y2 \cdot \left(\left(-a\right) \cdot x\right)\right)\\
\mathbf{else}:\\
\;\;\;\;y1 \cdot \left(\left(-i\right) \cdot \left(k \cdot z\right)\right)\\
\end{array}
\end{array}
if z < -4.5e16Initial program 25.9%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites46.4%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6434.3
Applied rewrites34.3%
Taylor expanded in a around inf
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6434.5
Applied rewrites34.5%
if -4.5e16 < z < 1.08e94Initial program 31.5%
Taylor expanded in y2 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites41.0%
Taylor expanded in y1 around inf
lower-*.f64N/A
lower-*.f64N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-*.f6432.1
Applied rewrites32.1%
Taylor expanded in x around inf
lower-*.f64N/A
lift-*.f6421.7
Applied rewrites21.7%
if 1.08e94 < z Initial program 18.5%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites59.2%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6451.9
Applied rewrites51.9%
Taylor expanded in a around 0
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6442.1
Applied rewrites42.1%
Final simplification28.9%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5) :precision binary64 (if (<= z -2.6e+126) (* a (* y1 (* y3 z))) (if (<= z 1.35e+112) (* y1 (* k (* y2 y4))) (* y1 (* (- i) (* k z))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -2.6e+126) {
tmp = a * (y1 * (y3 * z));
} else if (z <= 1.35e+112) {
tmp = y1 * (k * (y2 * y4));
} else {
tmp = y1 * (-i * (k * z));
}
return tmp;
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
real(8) :: tmp
if (z <= (-2.6d+126)) then
tmp = a * (y1 * (y3 * z))
else if (z <= 1.35d+112) then
tmp = y1 * (k * (y2 * y4))
else
tmp = y1 * (-i * (k * z))
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, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -2.6e+126) {
tmp = a * (y1 * (y3 * z));
} else if (z <= 1.35e+112) {
tmp = y1 * (k * (y2 * y4));
} else {
tmp = y1 * (-i * (k * z));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): tmp = 0 if z <= -2.6e+126: tmp = a * (y1 * (y3 * z)) elif z <= 1.35e+112: tmp = y1 * (k * (y2 * y4)) else: tmp = y1 * (-i * (k * z)) return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0 if (z <= -2.6e+126) tmp = Float64(a * Float64(y1 * Float64(y3 * z))); elseif (z <= 1.35e+112) tmp = Float64(y1 * Float64(k * Float64(y2 * y4))); else tmp = Float64(y1 * Float64(Float64(-i) * Float64(k * z))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0; if (z <= -2.6e+126) tmp = a * (y1 * (y3 * z)); elseif (z <= 1.35e+112) tmp = y1 * (k * (y2 * y4)); else tmp = y1 * (-i * (k * z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[z, -2.6e+126], N[(a * N[(y1 * N[(y3 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.35e+112], N[(y1 * N[(k * N[(y2 * y4), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y1 * N[((-i) * N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.6 \cdot 10^{+126}:\\
\;\;\;\;a \cdot \left(y1 \cdot \left(y3 \cdot z\right)\right)\\
\mathbf{elif}\;z \leq 1.35 \cdot 10^{+112}:\\
\;\;\;\;y1 \cdot \left(k \cdot \left(y2 \cdot y4\right)\right)\\
\mathbf{else}:\\
\;\;\;\;y1 \cdot \left(\left(-i\right) \cdot \left(k \cdot z\right)\right)\\
\end{array}
\end{array}
if z < -2.6e126Initial program 24.6%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites49.7%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6440.9
Applied rewrites40.9%
Taylor expanded in a around inf
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6443.3
Applied rewrites43.3%
if -2.6e126 < z < 1.3500000000000001e112Initial program 30.4%
Taylor expanded in y2 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites40.4%
Taylor expanded in y1 around inf
lower-*.f64N/A
lower-*.f64N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-*.f6431.7
Applied rewrites31.7%
Taylor expanded in x around 0
lower-*.f64N/A
lower-*.f6420.6
Applied rewrites20.6%
if 1.3500000000000001e112 < z Initial program 20.1%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites64.4%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6454.2
Applied rewrites54.2%
Taylor expanded in a around 0
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6443.6
Applied rewrites43.6%
Final simplification28.6%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5) :precision binary64 (if (or (<= t -4e+66) (not (<= t 1.05e-5))) (* c (* i (* t z))) (* a (* y1 (* y3 z)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if ((t <= -4e+66) || !(t <= 1.05e-5)) {
tmp = c * (i * (t * z));
} else {
tmp = a * (y1 * (y3 * z));
}
return tmp;
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
real(8) :: tmp
if ((t <= (-4d+66)) .or. (.not. (t <= 1.05d-5))) then
tmp = c * (i * (t * z))
else
tmp = a * (y1 * (y3 * z))
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, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if ((t <= -4e+66) || !(t <= 1.05e-5)) {
tmp = c * (i * (t * z));
} else {
tmp = a * (y1 * (y3 * z));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): tmp = 0 if (t <= -4e+66) or not (t <= 1.05e-5): tmp = c * (i * (t * z)) else: tmp = a * (y1 * (y3 * z)) return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0 if ((t <= -4e+66) || !(t <= 1.05e-5)) tmp = Float64(c * Float64(i * Float64(t * z))); else tmp = Float64(a * Float64(y1 * Float64(y3 * z))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0; if ((t <= -4e+66) || ~((t <= 1.05e-5))) tmp = c * (i * (t * z)); else tmp = a * (y1 * (y3 * z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[Or[LessEqual[t, -4e+66], N[Not[LessEqual[t, 1.05e-5]], $MachinePrecision]], N[(c * N[(i * N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(a * N[(y1 * N[(y3 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -4 \cdot 10^{+66} \lor \neg \left(t \leq 1.05 \cdot 10^{-5}\right):\\
\;\;\;\;c \cdot \left(i \cdot \left(t \cdot z\right)\right)\\
\mathbf{else}:\\
\;\;\;\;a \cdot \left(y1 \cdot \left(y3 \cdot z\right)\right)\\
\end{array}
\end{array}
if t < -3.99999999999999978e66 or 1.04999999999999994e-5 < t Initial program 21.2%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites36.3%
Taylor expanded in i around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6427.0
Applied rewrites27.0%
Taylor expanded in t around inf
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6424.2
Applied rewrites24.2%
if -3.99999999999999978e66 < t < 1.04999999999999994e-5Initial program 31.9%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites34.5%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6427.7
Applied rewrites27.7%
Taylor expanded in a around inf
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6421.2
Applied rewrites21.2%
Final simplification22.4%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5) :precision binary64 (if (<= z -2.6e+126) (* a (* y1 (* y3 z))) (if (<= z 1.1e+186) (* y1 (* k (* y2 y4))) (* c (* i (* t z))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -2.6e+126) {
tmp = a * (y1 * (y3 * z));
} else if (z <= 1.1e+186) {
tmp = y1 * (k * (y2 * y4));
} else {
tmp = c * (i * (t * z));
}
return tmp;
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
real(8) :: tmp
if (z <= (-2.6d+126)) then
tmp = a * (y1 * (y3 * z))
else if (z <= 1.1d+186) then
tmp = y1 * (k * (y2 * y4))
else
tmp = c * (i * (t * z))
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, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (z <= -2.6e+126) {
tmp = a * (y1 * (y3 * z));
} else if (z <= 1.1e+186) {
tmp = y1 * (k * (y2 * y4));
} else {
tmp = c * (i * (t * z));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): tmp = 0 if z <= -2.6e+126: tmp = a * (y1 * (y3 * z)) elif z <= 1.1e+186: tmp = y1 * (k * (y2 * y4)) else: tmp = c * (i * (t * z)) return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0 if (z <= -2.6e+126) tmp = Float64(a * Float64(y1 * Float64(y3 * z))); elseif (z <= 1.1e+186) tmp = Float64(y1 * Float64(k * Float64(y2 * y4))); else tmp = Float64(c * Float64(i * Float64(t * z))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0; if (z <= -2.6e+126) tmp = a * (y1 * (y3 * z)); elseif (z <= 1.1e+186) tmp = y1 * (k * (y2 * y4)); else tmp = c * (i * (t * z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[z, -2.6e+126], N[(a * N[(y1 * N[(y3 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.1e+186], N[(y1 * N[(k * N[(y2 * y4), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(c * N[(i * N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.6 \cdot 10^{+126}:\\
\;\;\;\;a \cdot \left(y1 \cdot \left(y3 \cdot z\right)\right)\\
\mathbf{elif}\;z \leq 1.1 \cdot 10^{+186}:\\
\;\;\;\;y1 \cdot \left(k \cdot \left(y2 \cdot y4\right)\right)\\
\mathbf{else}:\\
\;\;\;\;c \cdot \left(i \cdot \left(t \cdot z\right)\right)\\
\end{array}
\end{array}
if z < -2.6e126Initial program 24.6%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites49.7%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6440.9
Applied rewrites40.9%
Taylor expanded in a around inf
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6443.3
Applied rewrites43.3%
if -2.6e126 < z < 1.0999999999999999e186Initial program 29.7%
Taylor expanded in y2 around inf
lower-*.f64N/A
lower--.f64N/A
Applied rewrites41.2%
Taylor expanded in y1 around inf
lower-*.f64N/A
lower-*.f64N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-*.f6431.6
Applied rewrites31.6%
Taylor expanded in x around 0
lower-*.f64N/A
lower-*.f6419.7
Applied rewrites19.7%
if 1.0999999999999999e186 < z Initial program 19.6%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites67.8%
Taylor expanded in i around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6447.1
Applied rewrites47.1%
Taylor expanded in t around inf
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6436.7
Applied rewrites36.7%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5) :precision binary64 (if (<= t -4e+66) (* i (* c (* t z))) (if (<= t 1.05e-5) (* a (* y1 (* y3 z))) (* i (* z (* c t))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (t <= -4e+66) {
tmp = i * (c * (t * z));
} else if (t <= 1.05e-5) {
tmp = a * (y1 * (y3 * z));
} else {
tmp = i * (z * (c * t));
}
return tmp;
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
real(8) :: tmp
if (t <= (-4d+66)) then
tmp = i * (c * (t * z))
else if (t <= 1.05d-5) then
tmp = a * (y1 * (y3 * z))
else
tmp = i * (z * (c * t))
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, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (t <= -4e+66) {
tmp = i * (c * (t * z));
} else if (t <= 1.05e-5) {
tmp = a * (y1 * (y3 * z));
} else {
tmp = i * (z * (c * t));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): tmp = 0 if t <= -4e+66: tmp = i * (c * (t * z)) elif t <= 1.05e-5: tmp = a * (y1 * (y3 * z)) else: tmp = i * (z * (c * t)) return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0 if (t <= -4e+66) tmp = Float64(i * Float64(c * Float64(t * z))); elseif (t <= 1.05e-5) tmp = Float64(a * Float64(y1 * Float64(y3 * z))); else tmp = Float64(i * Float64(z * Float64(c * t))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0; if (t <= -4e+66) tmp = i * (c * (t * z)); elseif (t <= 1.05e-5) tmp = a * (y1 * (y3 * z)); else tmp = i * (z * (c * t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[t, -4e+66], N[(i * N[(c * N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.05e-5], N[(a * N[(y1 * N[(y3 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(i * N[(z * N[(c * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -4 \cdot 10^{+66}:\\
\;\;\;\;i \cdot \left(c \cdot \left(t \cdot z\right)\right)\\
\mathbf{elif}\;t \leq 1.05 \cdot 10^{-5}:\\
\;\;\;\;a \cdot \left(y1 \cdot \left(y3 \cdot z\right)\right)\\
\mathbf{else}:\\
\;\;\;\;i \cdot \left(z \cdot \left(c \cdot t\right)\right)\\
\end{array}
\end{array}
if t < -3.99999999999999978e66Initial program 25.5%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites36.9%
Taylor expanded in i around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6428.8
Applied rewrites28.8%
Taylor expanded in t around inf
lower-*.f64N/A
lower-*.f6428.7
Applied rewrites28.7%
if -3.99999999999999978e66 < t < 1.04999999999999994e-5Initial program 31.9%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites34.5%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6427.7
Applied rewrites27.7%
Taylor expanded in a around inf
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6421.2
Applied rewrites21.2%
if 1.04999999999999994e-5 < t Initial program 17.6%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites35.7%
Taylor expanded in i around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6425.4
Applied rewrites25.4%
Taylor expanded in t around inf
lift-*.f6423.8
Applied rewrites23.8%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5) :precision binary64 (if (<= t -4e+66) (* i (* c (* t z))) (if (<= t 1.05e-5) (* a (* y1 (* y3 z))) (* c (* i (* t z))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (t <= -4e+66) {
tmp = i * (c * (t * z));
} else if (t <= 1.05e-5) {
tmp = a * (y1 * (y3 * z));
} else {
tmp = c * (i * (t * z));
}
return tmp;
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
real(8) :: tmp
if (t <= (-4d+66)) then
tmp = i * (c * (t * z))
else if (t <= 1.05d-5) then
tmp = a * (y1 * (y3 * z))
else
tmp = c * (i * (t * z))
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, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double tmp;
if (t <= -4e+66) {
tmp = i * (c * (t * z));
} else if (t <= 1.05e-5) {
tmp = a * (y1 * (y3 * z));
} else {
tmp = c * (i * (t * z));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): tmp = 0 if t <= -4e+66: tmp = i * (c * (t * z)) elif t <= 1.05e-5: tmp = a * (y1 * (y3 * z)) else: tmp = c * (i * (t * z)) return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0 if (t <= -4e+66) tmp = Float64(i * Float64(c * Float64(t * z))); elseif (t <= 1.05e-5) tmp = Float64(a * Float64(y1 * Float64(y3 * z))); else tmp = Float64(c * Float64(i * Float64(t * z))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = 0.0; if (t <= -4e+66) tmp = i * (c * (t * z)); elseif (t <= 1.05e-5) tmp = a * (y1 * (y3 * z)); else tmp = c * (i * (t * z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[t, -4e+66], N[(i * N[(c * N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.05e-5], N[(a * N[(y1 * N[(y3 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(c * N[(i * N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -4 \cdot 10^{+66}:\\
\;\;\;\;i \cdot \left(c \cdot \left(t \cdot z\right)\right)\\
\mathbf{elif}\;t \leq 1.05 \cdot 10^{-5}:\\
\;\;\;\;a \cdot \left(y1 \cdot \left(y3 \cdot z\right)\right)\\
\mathbf{else}:\\
\;\;\;\;c \cdot \left(i \cdot \left(t \cdot z\right)\right)\\
\end{array}
\end{array}
if t < -3.99999999999999978e66Initial program 25.5%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites36.9%
Taylor expanded in i around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6428.8
Applied rewrites28.8%
Taylor expanded in t around inf
lower-*.f64N/A
lower-*.f6428.7
Applied rewrites28.7%
if -3.99999999999999978e66 < t < 1.04999999999999994e-5Initial program 31.9%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites34.5%
Taylor expanded in y1 around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6427.7
Applied rewrites27.7%
Taylor expanded in a around inf
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6421.2
Applied rewrites21.2%
if 1.04999999999999994e-5 < t Initial program 17.6%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites35.7%
Taylor expanded in i around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6425.4
Applied rewrites25.4%
Taylor expanded in t around inf
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6423.7
Applied rewrites23.7%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5) :precision binary64 (* c (* i (* t z))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
return c * (i * (t * z));
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
code = c * (i * (t * z))
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
return c * (i * (t * z));
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): return c * (i * (t * z))
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) return Float64(c * Float64(i * Float64(t * z))) end
function tmp = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) tmp = c * (i * (t * z)); end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := N[(c * N[(i * N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
c \cdot \left(i \cdot \left(t \cdot z\right)\right)
\end{array}
Initial program 27.6%
Taylor expanded in z around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
Applied rewrites35.2%
Taylor expanded in i around -inf
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f6419.1
Applied rewrites19.1%
Taylor expanded in t around inf
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6412.1
Applied rewrites12.1%
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:precision binary64
(let* ((t_1 (- (* y4 c) (* y5 a)))
(t_2 (- (* x y2) (* z y3)))
(t_3 (- (* y2 t) (* y3 y)))
(t_4 (- (* k y2) (* j y3)))
(t_5 (- (* y4 b) (* y5 i)))
(t_6 (* (- (* j t) (* k y)) t_5))
(t_7 (- (* b a) (* i c)))
(t_8 (* t_7 (- (* y x) (* t z))))
(t_9 (- (* j x) (* k z)))
(t_10 (* (- (* b y0) (* i y1)) t_9))
(t_11 (* t_9 (- (* y0 b) (* i y1))))
(t_12 (- (* y4 y1) (* y5 y0)))
(t_13 (* t_4 t_12))
(t_14 (* (- (* y2 k) (* y3 j)) t_12))
(t_15
(+
(-
(-
(- (* (* k y) (* y5 i)) (* (* y b) (* y4 k)))
(* (* y5 t) (* i j)))
(- (* t_3 t_1) t_14))
(- t_8 (- t_11 (* (- (* y2 x) (* y3 z)) (- (* c y0) (* y1 a)))))))
(t_16
(+
(+
(- t_6 (* (* y3 y) (- (* y5 a) (* y4 c))))
(+ (* (* y5 a) (* t y2)) t_13))
(-
(* t_2 (- (* c y0) (* a y1)))
(- t_10 (* (- (* y x) (* z t)) t_7)))))
(t_17 (- (* t y2) (* y y3))))
(if (< y4 -7.206256231996481e+60)
(- (- t_8 (- t_11 t_6)) (- (/ t_3 (/ 1.0 t_1)) t_14))
(if (< y4 -3.364603505246317e-66)
(+
(-
(- (- (* (* t c) (* i z)) (* (* a t) (* b z))) (* (* y c) (* i x)))
t_10)
(-
(* (- (* y0 c) (* a y1)) t_2)
(- (* t_17 (- (* y4 c) (* a y5))) (* (- (* y1 y4) (* y5 y0)) t_4))))
(if (< y4 -1.2000065055686116e-105)
t_16
(if (< y4 6.718963124057495e-279)
t_15
(if (< y4 4.77962681403792e-222)
t_16
(if (< y4 2.2852241541266835e-175)
t_15
(+
(-
(+
(+
(-
(* (- (* x y) (* z t)) (- (* a b) (* c i)))
(-
(* k (* i (* z y1)))
(+ (* j (* i (* x y1))) (* y0 (* k (* z b))))))
(-
(* z (* y3 (* a y1)))
(+ (* y2 (* x (* a y1))) (* y0 (* z (* c y3))))))
(* (- (* t j) (* y k)) t_5))
(* t_17 t_1))
t_13)))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = (y4 * c) - (y5 * a);
double t_2 = (x * y2) - (z * y3);
double t_3 = (y2 * t) - (y3 * y);
double t_4 = (k * y2) - (j * y3);
double t_5 = (y4 * b) - (y5 * i);
double t_6 = ((j * t) - (k * y)) * t_5;
double t_7 = (b * a) - (i * c);
double t_8 = t_7 * ((y * x) - (t * z));
double t_9 = (j * x) - (k * z);
double t_10 = ((b * y0) - (i * y1)) * t_9;
double t_11 = t_9 * ((y0 * b) - (i * y1));
double t_12 = (y4 * y1) - (y5 * y0);
double t_13 = t_4 * t_12;
double t_14 = ((y2 * k) - (y3 * j)) * t_12;
double t_15 = (((((k * y) * (y5 * i)) - ((y * b) * (y4 * k))) - ((y5 * t) * (i * j))) - ((t_3 * t_1) - t_14)) + (t_8 - (t_11 - (((y2 * x) - (y3 * z)) * ((c * y0) - (y1 * a)))));
double t_16 = ((t_6 - ((y3 * y) * ((y5 * a) - (y4 * c)))) + (((y5 * a) * (t * y2)) + t_13)) + ((t_2 * ((c * y0) - (a * y1))) - (t_10 - (((y * x) - (z * t)) * t_7)));
double t_17 = (t * y2) - (y * y3);
double tmp;
if (y4 < -7.206256231996481e+60) {
tmp = (t_8 - (t_11 - t_6)) - ((t_3 / (1.0 / t_1)) - t_14);
} else if (y4 < -3.364603505246317e-66) {
tmp = (((((t * c) * (i * z)) - ((a * t) * (b * z))) - ((y * c) * (i * x))) - t_10) + ((((y0 * c) - (a * y1)) * t_2) - ((t_17 * ((y4 * c) - (a * y5))) - (((y1 * y4) - (y5 * y0)) * t_4)));
} else if (y4 < -1.2000065055686116e-105) {
tmp = t_16;
} else if (y4 < 6.718963124057495e-279) {
tmp = t_15;
} else if (y4 < 4.77962681403792e-222) {
tmp = t_16;
} else if (y4 < 2.2852241541266835e-175) {
tmp = t_15;
} else {
tmp = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - ((k * (i * (z * y1))) - ((j * (i * (x * y1))) + (y0 * (k * (z * b)))))) + ((z * (y3 * (a * y1))) - ((y2 * (x * (a * y1))) + (y0 * (z * (c * y3)))))) + (((t * j) - (y * k)) * t_5)) - (t_17 * t_1)) + t_13;
}
return tmp;
}
module fmin_fmax_functions
implicit none
private
public fmax
public fmin
interface fmax
module procedure fmax88
module procedure fmax44
module procedure fmax84
module procedure fmax48
end interface
interface fmin
module procedure fmin88
module procedure fmin44
module procedure fmin84
module procedure fmin48
end interface
contains
real(8) function fmax88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(4) function fmax44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, max(x, y), y /= y), x /= x)
end function
real(8) function fmax84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmax48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
end function
real(8) function fmin88(x, y) result (res)
real(8), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(4) function fmin44(x, y) result (res)
real(4), intent (in) :: x
real(4), intent (in) :: y
res = merge(y, merge(x, min(x, y), y /= y), x /= x)
end function
real(8) function fmin84(x, y) result(res)
real(8), intent (in) :: x
real(4), intent (in) :: y
res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
end function
real(8) function fmin48(x, y) result(res)
real(4), intent (in) :: x
real(8), intent (in) :: y
res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
end function
end module
real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
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), intent (in) :: j
real(8), intent (in) :: k
real(8), intent (in) :: y0
real(8), intent (in) :: y1
real(8), intent (in) :: y2
real(8), intent (in) :: y3
real(8), intent (in) :: y4
real(8), intent (in) :: y5
real(8) :: t_1
real(8) :: t_10
real(8) :: t_11
real(8) :: t_12
real(8) :: t_13
real(8) :: t_14
real(8) :: t_15
real(8) :: t_16
real(8) :: t_17
real(8) :: t_2
real(8) :: t_3
real(8) :: t_4
real(8) :: t_5
real(8) :: t_6
real(8) :: t_7
real(8) :: t_8
real(8) :: t_9
real(8) :: tmp
t_1 = (y4 * c) - (y5 * a)
t_2 = (x * y2) - (z * y3)
t_3 = (y2 * t) - (y3 * y)
t_4 = (k * y2) - (j * y3)
t_5 = (y4 * b) - (y5 * i)
t_6 = ((j * t) - (k * y)) * t_5
t_7 = (b * a) - (i * c)
t_8 = t_7 * ((y * x) - (t * z))
t_9 = (j * x) - (k * z)
t_10 = ((b * y0) - (i * y1)) * t_9
t_11 = t_9 * ((y0 * b) - (i * y1))
t_12 = (y4 * y1) - (y5 * y0)
t_13 = t_4 * t_12
t_14 = ((y2 * k) - (y3 * j)) * t_12
t_15 = (((((k * y) * (y5 * i)) - ((y * b) * (y4 * k))) - ((y5 * t) * (i * j))) - ((t_3 * t_1) - t_14)) + (t_8 - (t_11 - (((y2 * x) - (y3 * z)) * ((c * y0) - (y1 * a)))))
t_16 = ((t_6 - ((y3 * y) * ((y5 * a) - (y4 * c)))) + (((y5 * a) * (t * y2)) + t_13)) + ((t_2 * ((c * y0) - (a * y1))) - (t_10 - (((y * x) - (z * t)) * t_7)))
t_17 = (t * y2) - (y * y3)
if (y4 < (-7.206256231996481d+60)) then
tmp = (t_8 - (t_11 - t_6)) - ((t_3 / (1.0d0 / t_1)) - t_14)
else if (y4 < (-3.364603505246317d-66)) then
tmp = (((((t * c) * (i * z)) - ((a * t) * (b * z))) - ((y * c) * (i * x))) - t_10) + ((((y0 * c) - (a * y1)) * t_2) - ((t_17 * ((y4 * c) - (a * y5))) - (((y1 * y4) - (y5 * y0)) * t_4)))
else if (y4 < (-1.2000065055686116d-105)) then
tmp = t_16
else if (y4 < 6.718963124057495d-279) then
tmp = t_15
else if (y4 < 4.77962681403792d-222) then
tmp = t_16
else if (y4 < 2.2852241541266835d-175) then
tmp = t_15
else
tmp = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - ((k * (i * (z * y1))) - ((j * (i * (x * y1))) + (y0 * (k * (z * b)))))) + ((z * (y3 * (a * y1))) - ((y2 * (x * (a * y1))) + (y0 * (z * (c * y3)))))) + (((t * j) - (y * k)) * t_5)) - (t_17 * t_1)) + t_13
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, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
double t_1 = (y4 * c) - (y5 * a);
double t_2 = (x * y2) - (z * y3);
double t_3 = (y2 * t) - (y3 * y);
double t_4 = (k * y2) - (j * y3);
double t_5 = (y4 * b) - (y5 * i);
double t_6 = ((j * t) - (k * y)) * t_5;
double t_7 = (b * a) - (i * c);
double t_8 = t_7 * ((y * x) - (t * z));
double t_9 = (j * x) - (k * z);
double t_10 = ((b * y0) - (i * y1)) * t_9;
double t_11 = t_9 * ((y0 * b) - (i * y1));
double t_12 = (y4 * y1) - (y5 * y0);
double t_13 = t_4 * t_12;
double t_14 = ((y2 * k) - (y3 * j)) * t_12;
double t_15 = (((((k * y) * (y5 * i)) - ((y * b) * (y4 * k))) - ((y5 * t) * (i * j))) - ((t_3 * t_1) - t_14)) + (t_8 - (t_11 - (((y2 * x) - (y3 * z)) * ((c * y0) - (y1 * a)))));
double t_16 = ((t_6 - ((y3 * y) * ((y5 * a) - (y4 * c)))) + (((y5 * a) * (t * y2)) + t_13)) + ((t_2 * ((c * y0) - (a * y1))) - (t_10 - (((y * x) - (z * t)) * t_7)));
double t_17 = (t * y2) - (y * y3);
double tmp;
if (y4 < -7.206256231996481e+60) {
tmp = (t_8 - (t_11 - t_6)) - ((t_3 / (1.0 / t_1)) - t_14);
} else if (y4 < -3.364603505246317e-66) {
tmp = (((((t * c) * (i * z)) - ((a * t) * (b * z))) - ((y * c) * (i * x))) - t_10) + ((((y0 * c) - (a * y1)) * t_2) - ((t_17 * ((y4 * c) - (a * y5))) - (((y1 * y4) - (y5 * y0)) * t_4)));
} else if (y4 < -1.2000065055686116e-105) {
tmp = t_16;
} else if (y4 < 6.718963124057495e-279) {
tmp = t_15;
} else if (y4 < 4.77962681403792e-222) {
tmp = t_16;
} else if (y4 < 2.2852241541266835e-175) {
tmp = t_15;
} else {
tmp = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - ((k * (i * (z * y1))) - ((j * (i * (x * y1))) + (y0 * (k * (z * b)))))) + ((z * (y3 * (a * y1))) - ((y2 * (x * (a * y1))) + (y0 * (z * (c * y3)))))) + (((t * j) - (y * k)) * t_5)) - (t_17 * t_1)) + t_13;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5): t_1 = (y4 * c) - (y5 * a) t_2 = (x * y2) - (z * y3) t_3 = (y2 * t) - (y3 * y) t_4 = (k * y2) - (j * y3) t_5 = (y4 * b) - (y5 * i) t_6 = ((j * t) - (k * y)) * t_5 t_7 = (b * a) - (i * c) t_8 = t_7 * ((y * x) - (t * z)) t_9 = (j * x) - (k * z) t_10 = ((b * y0) - (i * y1)) * t_9 t_11 = t_9 * ((y0 * b) - (i * y1)) t_12 = (y4 * y1) - (y5 * y0) t_13 = t_4 * t_12 t_14 = ((y2 * k) - (y3 * j)) * t_12 t_15 = (((((k * y) * (y5 * i)) - ((y * b) * (y4 * k))) - ((y5 * t) * (i * j))) - ((t_3 * t_1) - t_14)) + (t_8 - (t_11 - (((y2 * x) - (y3 * z)) * ((c * y0) - (y1 * a))))) t_16 = ((t_6 - ((y3 * y) * ((y5 * a) - (y4 * c)))) + (((y5 * a) * (t * y2)) + t_13)) + ((t_2 * ((c * y0) - (a * y1))) - (t_10 - (((y * x) - (z * t)) * t_7))) t_17 = (t * y2) - (y * y3) tmp = 0 if y4 < -7.206256231996481e+60: tmp = (t_8 - (t_11 - t_6)) - ((t_3 / (1.0 / t_1)) - t_14) elif y4 < -3.364603505246317e-66: tmp = (((((t * c) * (i * z)) - ((a * t) * (b * z))) - ((y * c) * (i * x))) - t_10) + ((((y0 * c) - (a * y1)) * t_2) - ((t_17 * ((y4 * c) - (a * y5))) - (((y1 * y4) - (y5 * y0)) * t_4))) elif y4 < -1.2000065055686116e-105: tmp = t_16 elif y4 < 6.718963124057495e-279: tmp = t_15 elif y4 < 4.77962681403792e-222: tmp = t_16 elif y4 < 2.2852241541266835e-175: tmp = t_15 else: tmp = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - ((k * (i * (z * y1))) - ((j * (i * (x * y1))) + (y0 * (k * (z * b)))))) + ((z * (y3 * (a * y1))) - ((y2 * (x * (a * y1))) + (y0 * (z * (c * y3)))))) + (((t * j) - (y * k)) * t_5)) - (t_17 * t_1)) + t_13 return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = Float64(Float64(y4 * c) - Float64(y5 * a)) t_2 = Float64(Float64(x * y2) - Float64(z * y3)) t_3 = Float64(Float64(y2 * t) - Float64(y3 * y)) t_4 = Float64(Float64(k * y2) - Float64(j * y3)) t_5 = Float64(Float64(y4 * b) - Float64(y5 * i)) t_6 = Float64(Float64(Float64(j * t) - Float64(k * y)) * t_5) t_7 = Float64(Float64(b * a) - Float64(i * c)) t_8 = Float64(t_7 * Float64(Float64(y * x) - Float64(t * z))) t_9 = Float64(Float64(j * x) - Float64(k * z)) t_10 = Float64(Float64(Float64(b * y0) - Float64(i * y1)) * t_9) t_11 = Float64(t_9 * Float64(Float64(y0 * b) - Float64(i * y1))) t_12 = Float64(Float64(y4 * y1) - Float64(y5 * y0)) t_13 = Float64(t_4 * t_12) t_14 = Float64(Float64(Float64(y2 * k) - Float64(y3 * j)) * t_12) t_15 = Float64(Float64(Float64(Float64(Float64(Float64(k * y) * Float64(y5 * i)) - Float64(Float64(y * b) * Float64(y4 * k))) - Float64(Float64(y5 * t) * Float64(i * j))) - Float64(Float64(t_3 * t_1) - t_14)) + Float64(t_8 - Float64(t_11 - Float64(Float64(Float64(y2 * x) - Float64(y3 * z)) * Float64(Float64(c * y0) - Float64(y1 * a)))))) t_16 = Float64(Float64(Float64(t_6 - Float64(Float64(y3 * y) * Float64(Float64(y5 * a) - Float64(y4 * c)))) + Float64(Float64(Float64(y5 * a) * Float64(t * y2)) + t_13)) + Float64(Float64(t_2 * Float64(Float64(c * y0) - Float64(a * y1))) - Float64(t_10 - Float64(Float64(Float64(y * x) - Float64(z * t)) * t_7)))) t_17 = Float64(Float64(t * y2) - Float64(y * y3)) tmp = 0.0 if (y4 < -7.206256231996481e+60) tmp = Float64(Float64(t_8 - Float64(t_11 - t_6)) - Float64(Float64(t_3 / Float64(1.0 / t_1)) - t_14)); elseif (y4 < -3.364603505246317e-66) tmp = Float64(Float64(Float64(Float64(Float64(Float64(t * c) * Float64(i * z)) - Float64(Float64(a * t) * Float64(b * z))) - Float64(Float64(y * c) * Float64(i * x))) - t_10) + Float64(Float64(Float64(Float64(y0 * c) - Float64(a * y1)) * t_2) - Float64(Float64(t_17 * Float64(Float64(y4 * c) - Float64(a * y5))) - Float64(Float64(Float64(y1 * y4) - Float64(y5 * y0)) * t_4)))); elseif (y4 < -1.2000065055686116e-105) tmp = t_16; elseif (y4 < 6.718963124057495e-279) tmp = t_15; elseif (y4 < 4.77962681403792e-222) tmp = t_16; elseif (y4 < 2.2852241541266835e-175) tmp = t_15; else tmp = Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * y) - Float64(z * t)) * Float64(Float64(a * b) - Float64(c * i))) - Float64(Float64(k * Float64(i * Float64(z * y1))) - Float64(Float64(j * Float64(i * Float64(x * y1))) + Float64(y0 * Float64(k * Float64(z * b)))))) + Float64(Float64(z * Float64(y3 * Float64(a * y1))) - Float64(Float64(y2 * Float64(x * Float64(a * y1))) + Float64(y0 * Float64(z * Float64(c * y3)))))) + Float64(Float64(Float64(t * j) - Float64(y * k)) * t_5)) - Float64(t_17 * t_1)) + t_13); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5) t_1 = (y4 * c) - (y5 * a); t_2 = (x * y2) - (z * y3); t_3 = (y2 * t) - (y3 * y); t_4 = (k * y2) - (j * y3); t_5 = (y4 * b) - (y5 * i); t_6 = ((j * t) - (k * y)) * t_5; t_7 = (b * a) - (i * c); t_8 = t_7 * ((y * x) - (t * z)); t_9 = (j * x) - (k * z); t_10 = ((b * y0) - (i * y1)) * t_9; t_11 = t_9 * ((y0 * b) - (i * y1)); t_12 = (y4 * y1) - (y5 * y0); t_13 = t_4 * t_12; t_14 = ((y2 * k) - (y3 * j)) * t_12; t_15 = (((((k * y) * (y5 * i)) - ((y * b) * (y4 * k))) - ((y5 * t) * (i * j))) - ((t_3 * t_1) - t_14)) + (t_8 - (t_11 - (((y2 * x) - (y3 * z)) * ((c * y0) - (y1 * a))))); t_16 = ((t_6 - ((y3 * y) * ((y5 * a) - (y4 * c)))) + (((y5 * a) * (t * y2)) + t_13)) + ((t_2 * ((c * y0) - (a * y1))) - (t_10 - (((y * x) - (z * t)) * t_7))); t_17 = (t * y2) - (y * y3); tmp = 0.0; if (y4 < -7.206256231996481e+60) tmp = (t_8 - (t_11 - t_6)) - ((t_3 / (1.0 / t_1)) - t_14); elseif (y4 < -3.364603505246317e-66) tmp = (((((t * c) * (i * z)) - ((a * t) * (b * z))) - ((y * c) * (i * x))) - t_10) + ((((y0 * c) - (a * y1)) * t_2) - ((t_17 * ((y4 * c) - (a * y5))) - (((y1 * y4) - (y5 * y0)) * t_4))); elseif (y4 < -1.2000065055686116e-105) tmp = t_16; elseif (y4 < 6.718963124057495e-279) tmp = t_15; elseif (y4 < 4.77962681403792e-222) tmp = t_16; elseif (y4 < 2.2852241541266835e-175) tmp = t_15; else tmp = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - ((k * (i * (z * y1))) - ((j * (i * (x * y1))) + (y0 * (k * (z * b)))))) + ((z * (y3 * (a * y1))) - ((y2 * (x * (a * y1))) + (y0 * (z * (c * y3)))))) + (((t * j) - (y * k)) * t_5)) - (t_17 * t_1)) + t_13; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(y4 * c), $MachinePrecision] - N[(y5 * a), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x * y2), $MachinePrecision] - N[(z * y3), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(y2 * t), $MachinePrecision] - N[(y3 * y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[(N[(y4 * b), $MachinePrecision] - N[(y5 * i), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$6 = N[(N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision] * t$95$5), $MachinePrecision]}, Block[{t$95$7 = N[(N[(b * a), $MachinePrecision] - N[(i * c), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$8 = N[(t$95$7 * N[(N[(y * x), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$9 = N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$10 = N[(N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision] * t$95$9), $MachinePrecision]}, Block[{t$95$11 = N[(t$95$9 * N[(N[(y0 * b), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$12 = N[(N[(y4 * y1), $MachinePrecision] - N[(y5 * y0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$13 = N[(t$95$4 * t$95$12), $MachinePrecision]}, Block[{t$95$14 = N[(N[(N[(y2 * k), $MachinePrecision] - N[(y3 * j), $MachinePrecision]), $MachinePrecision] * t$95$12), $MachinePrecision]}, Block[{t$95$15 = N[(N[(N[(N[(N[(N[(k * y), $MachinePrecision] * N[(y5 * i), $MachinePrecision]), $MachinePrecision] - N[(N[(y * b), $MachinePrecision] * N[(y4 * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(y5 * t), $MachinePrecision] * N[(i * j), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(t$95$3 * t$95$1), $MachinePrecision] - t$95$14), $MachinePrecision]), $MachinePrecision] + N[(t$95$8 - N[(t$95$11 - N[(N[(N[(y2 * x), $MachinePrecision] - N[(y3 * z), $MachinePrecision]), $MachinePrecision] * N[(N[(c * y0), $MachinePrecision] - N[(y1 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$16 = N[(N[(N[(t$95$6 - N[(N[(y3 * y), $MachinePrecision] * N[(N[(y5 * a), $MachinePrecision] - N[(y4 * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(y5 * a), $MachinePrecision] * N[(t * y2), $MachinePrecision]), $MachinePrecision] + t$95$13), $MachinePrecision]), $MachinePrecision] + N[(N[(t$95$2 * N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(t$95$10 - N[(N[(N[(y * x), $MachinePrecision] - N[(z * t), $MachinePrecision]), $MachinePrecision] * t$95$7), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$17 = N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]}, If[Less[y4, -7.206256231996481e+60], N[(N[(t$95$8 - N[(t$95$11 - t$95$6), $MachinePrecision]), $MachinePrecision] - N[(N[(t$95$3 / N[(1.0 / t$95$1), $MachinePrecision]), $MachinePrecision] - t$95$14), $MachinePrecision]), $MachinePrecision], If[Less[y4, -3.364603505246317e-66], N[(N[(N[(N[(N[(N[(t * c), $MachinePrecision] * N[(i * z), $MachinePrecision]), $MachinePrecision] - N[(N[(a * t), $MachinePrecision] * N[(b * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(y * c), $MachinePrecision] * N[(i * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$10), $MachinePrecision] + N[(N[(N[(N[(y0 * c), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision] * t$95$2), $MachinePrecision] - N[(N[(t$95$17 * N[(N[(y4 * c), $MachinePrecision] - N[(a * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(y1 * y4), $MachinePrecision] - N[(y5 * y0), $MachinePrecision]), $MachinePrecision] * t$95$4), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Less[y4, -1.2000065055686116e-105], t$95$16, If[Less[y4, 6.718963124057495e-279], t$95$15, If[Less[y4, 4.77962681403792e-222], t$95$16, If[Less[y4, 2.2852241541266835e-175], t$95$15, N[(N[(N[(N[(N[(N[(N[(N[(x * y), $MachinePrecision] - N[(z * t), $MachinePrecision]), $MachinePrecision] * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(k * N[(i * N[(z * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(j * N[(i * N[(x * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(y0 * N[(k * N[(z * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(z * N[(y3 * N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(y2 * N[(x * N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(y0 * N[(z * N[(c * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(t * j), $MachinePrecision] - N[(y * k), $MachinePrecision]), $MachinePrecision] * t$95$5), $MachinePrecision]), $MachinePrecision] - N[(t$95$17 * t$95$1), $MachinePrecision]), $MachinePrecision] + t$95$13), $MachinePrecision]]]]]]]]]]]]]]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y4 \cdot c - y5 \cdot a\\
t_2 := x \cdot y2 - z \cdot y3\\
t_3 := y2 \cdot t - y3 \cdot y\\
t_4 := k \cdot y2 - j \cdot y3\\
t_5 := y4 \cdot b - y5 \cdot i\\
t_6 := \left(j \cdot t - k \cdot y\right) \cdot t\_5\\
t_7 := b \cdot a - i \cdot c\\
t_8 := t\_7 \cdot \left(y \cdot x - t \cdot z\right)\\
t_9 := j \cdot x - k \cdot z\\
t_10 := \left(b \cdot y0 - i \cdot y1\right) \cdot t\_9\\
t_11 := t\_9 \cdot \left(y0 \cdot b - i \cdot y1\right)\\
t_12 := y4 \cdot y1 - y5 \cdot y0\\
t_13 := t\_4 \cdot t\_12\\
t_14 := \left(y2 \cdot k - y3 \cdot j\right) \cdot t\_12\\
t_15 := \left(\left(\left(\left(k \cdot y\right) \cdot \left(y5 \cdot i\right) - \left(y \cdot b\right) \cdot \left(y4 \cdot k\right)\right) - \left(y5 \cdot t\right) \cdot \left(i \cdot j\right)\right) - \left(t\_3 \cdot t\_1 - t\_14\right)\right) + \left(t\_8 - \left(t\_11 - \left(y2 \cdot x - y3 \cdot z\right) \cdot \left(c \cdot y0 - y1 \cdot a\right)\right)\right)\\
t_16 := \left(\left(t\_6 - \left(y3 \cdot y\right) \cdot \left(y5 \cdot a - y4 \cdot c\right)\right) + \left(\left(y5 \cdot a\right) \cdot \left(t \cdot y2\right) + t\_13\right)\right) + \left(t\_2 \cdot \left(c \cdot y0 - a \cdot y1\right) - \left(t\_10 - \left(y \cdot x - z \cdot t\right) \cdot t\_7\right)\right)\\
t_17 := t \cdot y2 - y \cdot y3\\
\mathbf{if}\;y4 < -7.206256231996481 \cdot 10^{+60}:\\
\;\;\;\;\left(t\_8 - \left(t\_11 - t\_6\right)\right) - \left(\frac{t\_3}{\frac{1}{t\_1}} - t\_14\right)\\
\mathbf{elif}\;y4 < -3.364603505246317 \cdot 10^{-66}:\\
\;\;\;\;\left(\left(\left(\left(t \cdot c\right) \cdot \left(i \cdot z\right) - \left(a \cdot t\right) \cdot \left(b \cdot z\right)\right) - \left(y \cdot c\right) \cdot \left(i \cdot x\right)\right) - t\_10\right) + \left(\left(y0 \cdot c - a \cdot y1\right) \cdot t\_2 - \left(t\_17 \cdot \left(y4 \cdot c - a \cdot y5\right) - \left(y1 \cdot y4 - y5 \cdot y0\right) \cdot t\_4\right)\right)\\
\mathbf{elif}\;y4 < -1.2000065055686116 \cdot 10^{-105}:\\
\;\;\;\;t\_16\\
\mathbf{elif}\;y4 < 6.718963124057495 \cdot 10^{-279}:\\
\;\;\;\;t\_15\\
\mathbf{elif}\;y4 < 4.77962681403792 \cdot 10^{-222}:\\
\;\;\;\;t\_16\\
\mathbf{elif}\;y4 < 2.2852241541266835 \cdot 10^{-175}:\\
\;\;\;\;t\_15\\
\mathbf{else}:\\
\;\;\;\;\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(k \cdot \left(i \cdot \left(z \cdot y1\right)\right) - \left(j \cdot \left(i \cdot \left(x \cdot y1\right)\right) + y0 \cdot \left(k \cdot \left(z \cdot b\right)\right)\right)\right)\right) + \left(z \cdot \left(y3 \cdot \left(a \cdot y1\right)\right) - \left(y2 \cdot \left(x \cdot \left(a \cdot y1\right)\right) + y0 \cdot \left(z \cdot \left(c \cdot y3\right)\right)\right)\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot t\_5\right) - t\_17 \cdot t\_1\right) + t\_13\\
\end{array}
\end{array}
herbie shell --seed 2025037
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
:name "Linear.Matrix:det44 from linear-1.19.1.3"
:precision binary64
:alt
(! :herbie-platform default (if (< y4 -7206256231996481000000000000000000000000000000000000000000000) (- (- (* (- (* b a) (* i c)) (- (* y x) (* t z))) (- (* (- (* j x) (* k z)) (- (* y0 b) (* i y1))) (* (- (* j t) (* k y)) (- (* y4 b) (* y5 i))))) (- (/ (- (* y2 t) (* y3 y)) (/ 1 (- (* y4 c) (* y5 a)))) (* (- (* y2 k) (* y3 j)) (- (* y4 y1) (* y5 y0))))) (if (< y4 -3364603505246317/1000000000000000000000000000000000000000000000000000000000000000000000000000000000) (+ (- (- (- (* (* t c) (* i z)) (* (* a t) (* b z))) (* (* y c) (* i x))) (* (- (* b y0) (* i y1)) (- (* j x) (* k z)))) (- (* (- (* y0 c) (* a y1)) (- (* x y2) (* z y3))) (- (* (- (* t y2) (* y y3)) (- (* y4 c) (* a y5))) (* (- (* y1 y4) (* y5 y0)) (- (* k y2) (* j y3)))))) (if (< y4 -3000016263921529/2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (+ (+ (- (* (- (* j t) (* k y)) (- (* y4 b) (* y5 i))) (* (* y3 y) (- (* y5 a) (* y4 c)))) (+ (* (* y5 a) (* t y2)) (* (- (* k y2) (* j y3)) (- (* y4 y1) (* y5 y0))))) (- (* (- (* x y2) (* z y3)) (- (* c y0) (* a y1))) (- (* (- (* b y0) (* i y1)) (- (* j x) (* k z))) (* (- (* y x) (* z t)) (- (* b a) (* i c)))))) (if (< y4 1343792624811499/200000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (+ (- (- (- (* (* k y) (* y5 i)) (* (* y b) (* y4 k))) (* (* y5 t) (* i j))) (- (* (- (* y2 t) (* y3 y)) (- (* y4 c) (* y5 a))) (* (- (* y2 k) (* y3 j)) (- (* y4 y1) (* y5 y0))))) (- (* (- (* b a) (* i c)) (- (* y x) (* t z))) (- (* (- (* j x) (* k z)) (- (* y0 b) (* i y1))) (* (- (* y2 x) (* y3 z)) (- (* c y0) (* y1 a)))))) (if (< y4 29872667587737/6250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (+ (+ (- (* (- (* j t) (* k y)) (- (* y4 b) (* y5 i))) (* (* y3 y) (- (* y5 a) (* y4 c)))) (+ (* (* y5 a) (* t y2)) (* (- (* k y2) (* j y3)) (- (* y4 y1) (* y5 y0))))) (- (* (- (* x y2) (* z y3)) (- (* c y0) (* a y1))) (- (* (- (* b y0) (* i y1)) (- (* j x) (* k z))) (* (- (* y x) (* z t)) (- (* b a) (* i c)))))) (if (< y4 4570448308253367/20000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (+ (- (- (- (* (* k y) (* y5 i)) (* (* y b) (* y4 k))) (* (* y5 t) (* i j))) (- (* (- (* y2 t) (* y3 y)) (- (* y4 c) (* y5 a))) (* (- (* y2 k) (* y3 j)) (- (* y4 y1) (* y5 y0))))) (- (* (- (* b a) (* i c)) (- (* y x) (* t z))) (- (* (- (* j x) (* k z)) (- (* y0 b) (* i y1))) (* (- (* y2 x) (* y3 z)) (- (* c y0) (* y1 a)))))) (+ (- (+ (+ (- (* (- (* x y) (* z t)) (- (* a b) (* c i))) (- (* k (* i (* z y1))) (+ (* j (* i (* x y1))) (* y0 (* k (* z b)))))) (- (* z (* y3 (* a y1))) (+ (* y2 (* x (* a y1))) (* y0 (* z (* c y3)))))) (* (- (* t j) (* y k)) (- (* y4 b) (* y5 i)))) (* (- (* t y2) (* y y3)) (- (* y4 c) (* y5 a)))) (* (- (* k y2) (* j y3)) (- (* y4 y1) (* y5 y0)))))))))))
(+ (- (+ (+ (- (* (- (* x y) (* z t)) (- (* a b) (* c i))) (* (- (* x j) (* z k)) (- (* y0 b) (* y1 i)))) (* (- (* x y2) (* z y3)) (- (* y0 c) (* y1 a)))) (* (- (* t j) (* y k)) (- (* y4 b) (* y5 i)))) (* (- (* t y2) (* y y3)) (- (* y4 c) (* y5 a)))) (* (- (* k y2) (* j y3)) (- (* y4 y1) (* y5 y0)))))