Graphics.Rasterific.Shading:$sradialGradientWithFocusShader from Rasterific-0.6.1, B

Percentage Accurate: 91.0% → 94.1%
Time: 10.3s
Alternatives: 8
Speedup: 0.8×

Specification

?
\[\begin{array}{l} \\ x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right) \end{array} \]
(FPCore (x y z t) :precision binary64 (- (* x x) (* (* y 4.0) (- (* z z) t))))
double code(double x, double y, double z, double t) {
	return (x * x) - ((y * 4.0) * ((z * z) - t));
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    code = (x * x) - ((y * 4.0d0) * ((z * z) - t))
end function
public static double code(double x, double y, double z, double t) {
	return (x * x) - ((y * 4.0) * ((z * z) - t));
}
def code(x, y, z, t):
	return (x * x) - ((y * 4.0) * ((z * z) - t))
function code(x, y, z, t)
	return Float64(Float64(x * x) - Float64(Float64(y * 4.0) * Float64(Float64(z * z) - t)))
end
function tmp = code(x, y, z, t)
	tmp = (x * x) - ((y * 4.0) * ((z * z) - t));
end
code[x_, y_, z_, t_] := N[(N[(x * x), $MachinePrecision] - N[(N[(y * 4.0), $MachinePrecision] * N[(N[(z * z), $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right)
\end{array}

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

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

Accuracy vs Speed?

Herbie found 8 alternatives:

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

Initial Program: 91.0% accurate, 1.0× speedup?

\[\begin{array}{l} \\ x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right) \end{array} \]
(FPCore (x y z t) :precision binary64 (- (* x x) (* (* y 4.0) (- (* z z) t))))
double code(double x, double y, double z, double t) {
	return (x * x) - ((y * 4.0) * ((z * z) - t));
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    code = (x * x) - ((y * 4.0d0) * ((z * z) - t))
end function
public static double code(double x, double y, double z, double t) {
	return (x * x) - ((y * 4.0) * ((z * z) - t));
}
def code(x, y, z, t):
	return (x * x) - ((y * 4.0) * ((z * z) - t))
function code(x, y, z, t)
	return Float64(Float64(x * x) - Float64(Float64(y * 4.0) * Float64(Float64(z * z) - t)))
end
function tmp = code(x, y, z, t)
	tmp = (x * x) - ((y * 4.0) * ((z * z) - t));
end
code[x_, y_, z_, t_] := N[(N[(x * x), $MachinePrecision] - N[(N[(y * 4.0), $MachinePrecision] * N[(N[(z * z), $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right)
\end{array}

Alternative 1: 94.1% accurate, 0.1× speedup?

\[\begin{array}{l} x = |x|\\ \\ \begin{array}{l} \mathbf{if}\;x \leq 1.2 \cdot 10^{+201}:\\ \;\;\;\;\mathsf{fma}\left(x, x, \left(z \cdot z - t\right) \cdot \left(y \cdot -4\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-t, y \cdot -4, x \cdot x\right)\\ \end{array} \end{array} \]
NOTE: x should be positive before calling this function
(FPCore (x y z t)
 :precision binary64
 (if (<= x 1.2e+201)
   (fma x x (* (- (* z z) t) (* y -4.0)))
   (fma (- t) (* y -4.0) (* x x))))
x = abs(x);
double code(double x, double y, double z, double t) {
	double tmp;
	if (x <= 1.2e+201) {
		tmp = fma(x, x, (((z * z) - t) * (y * -4.0)));
	} else {
		tmp = fma(-t, (y * -4.0), (x * x));
	}
	return tmp;
}
x = abs(x)
function code(x, y, z, t)
	tmp = 0.0
	if (x <= 1.2e+201)
		tmp = fma(x, x, Float64(Float64(Float64(z * z) - t) * Float64(y * -4.0)));
	else
		tmp = fma(Float64(-t), Float64(y * -4.0), Float64(x * x));
	end
	return tmp
end
NOTE: x should be positive before calling this function
code[x_, y_, z_, t_] := If[LessEqual[x, 1.2e+201], N[(x * x + N[(N[(N[(z * z), $MachinePrecision] - t), $MachinePrecision] * N[(y * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[((-t) * N[(y * -4.0), $MachinePrecision] + N[(x * x), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
x = |x|\\
\\
\begin{array}{l}
\mathbf{if}\;x \leq 1.2 \cdot 10^{+201}:\\
\;\;\;\;\mathsf{fma}\left(x, x, \left(z \cdot z - t\right) \cdot \left(y \cdot -4\right)\right)\\

\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(-t, y \cdot -4, x \cdot x\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if x < 1.19999999999999996e201

    1. Initial program 88.3%

      \[x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right) \]
    2. Step-by-step derivation
      1. fma-neg90.9%

        \[\leadsto \color{blue}{\mathsf{fma}\left(x, x, -\left(y \cdot 4\right) \cdot \left(z \cdot z - t\right)\right)} \]
      2. *-commutative90.9%

        \[\leadsto \mathsf{fma}\left(x, x, -\color{blue}{\left(z \cdot z - t\right) \cdot \left(y \cdot 4\right)}\right) \]
      3. distribute-rgt-neg-in90.9%

        \[\leadsto \mathsf{fma}\left(x, x, \color{blue}{\left(z \cdot z - t\right) \cdot \left(-y \cdot 4\right)}\right) \]
      4. distribute-rgt-neg-in90.9%

        \[\leadsto \mathsf{fma}\left(x, x, \left(z \cdot z - t\right) \cdot \color{blue}{\left(y \cdot \left(-4\right)\right)}\right) \]
      5. metadata-eval90.9%

        \[\leadsto \mathsf{fma}\left(x, x, \left(z \cdot z - t\right) \cdot \left(y \cdot \color{blue}{-4}\right)\right) \]
    3. Simplified90.9%

      \[\leadsto \color{blue}{\mathsf{fma}\left(x, x, \left(z \cdot z - t\right) \cdot \left(y \cdot -4\right)\right)} \]

    if 1.19999999999999996e201 < x

    1. Initial program 88.0%

      \[x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right) \]
    2. Taylor expanded in x around 0 88.0%

      \[\leadsto \color{blue}{-4 \cdot \left(y \cdot \left({z}^{2} - t\right)\right) + {x}^{2}} \]
    3. Step-by-step derivation
      1. unpow288.0%

        \[\leadsto -4 \cdot \left(y \cdot \left({z}^{2} - t\right)\right) + \color{blue}{x \cdot x} \]
      2. *-commutative88.0%

        \[\leadsto \color{blue}{\left(y \cdot \left({z}^{2} - t\right)\right) \cdot -4} + x \cdot x \]
      3. *-commutative88.0%

        \[\leadsto \color{blue}{\left(\left({z}^{2} - t\right) \cdot y\right)} \cdot -4 + x \cdot x \]
      4. unpow288.0%

        \[\leadsto \left(\left(\color{blue}{z \cdot z} - t\right) \cdot y\right) \cdot -4 + x \cdot x \]
      5. associate-*l*88.0%

        \[\leadsto \color{blue}{\left(z \cdot z - t\right) \cdot \left(y \cdot -4\right)} + x \cdot x \]
      6. rem-log-exp88.0%

        \[\leadsto \left(z \cdot z - t\right) \cdot \left(y \cdot \color{blue}{\log \left(e^{-4}\right)}\right) + x \cdot x \]
      7. log-pow68.0%

        \[\leadsto \left(z \cdot z - t\right) \cdot \color{blue}{\log \left({\left(e^{-4}\right)}^{y}\right)} + x \cdot x \]
      8. fma-udef68.0%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z \cdot z - t, \log \left({\left(e^{-4}\right)}^{y}\right), x \cdot x\right)} \]
      9. log-pow88.0%

        \[\leadsto \mathsf{fma}\left(z \cdot z - t, \color{blue}{y \cdot \log \left(e^{-4}\right)}, x \cdot x\right) \]
      10. rem-log-exp88.0%

        \[\leadsto \mathsf{fma}\left(z \cdot z - t, y \cdot \color{blue}{-4}, x \cdot x\right) \]
    4. Simplified88.0%

      \[\leadsto \color{blue}{\mathsf{fma}\left(z \cdot z - t, y \cdot -4, x \cdot x\right)} \]
    5. Taylor expanded in z around 0 100.0%

      \[\leadsto \mathsf{fma}\left(\color{blue}{-1 \cdot t}, y \cdot -4, x \cdot x\right) \]
    6. Step-by-step derivation
      1. neg-mul-1100.0%

        \[\leadsto \mathsf{fma}\left(\color{blue}{-t}, y \cdot -4, x \cdot x\right) \]
    7. Simplified100.0%

      \[\leadsto \mathsf{fma}\left(\color{blue}{-t}, y \cdot -4, x \cdot x\right) \]
  3. Recombined 2 regimes into one program.
  4. Final simplification91.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq 1.2 \cdot 10^{+201}:\\ \;\;\;\;\mathsf{fma}\left(x, x, \left(z \cdot z - t\right) \cdot \left(y \cdot -4\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-t, y \cdot -4, x \cdot x\right)\\ \end{array} \]

Alternative 2: 93.1% accurate, 0.1× speedup?

\[\begin{array}{l} x = |x|\\ \\ \begin{array}{l} \mathbf{if}\;x \leq 4.5 \cdot 10^{+148}:\\ \;\;\;\;x \cdot x + \left(y \cdot 4\right) \cdot \left(t - z \cdot z\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-t, y \cdot -4, x \cdot x\right)\\ \end{array} \end{array} \]
NOTE: x should be positive before calling this function
(FPCore (x y z t)
 :precision binary64
 (if (<= x 4.5e+148)
   (+ (* x x) (* (* y 4.0) (- t (* z z))))
   (fma (- t) (* y -4.0) (* x x))))
x = abs(x);
double code(double x, double y, double z, double t) {
	double tmp;
	if (x <= 4.5e+148) {
		tmp = (x * x) + ((y * 4.0) * (t - (z * z)));
	} else {
		tmp = fma(-t, (y * -4.0), (x * x));
	}
	return tmp;
}
x = abs(x)
function code(x, y, z, t)
	tmp = 0.0
	if (x <= 4.5e+148)
		tmp = Float64(Float64(x * x) + Float64(Float64(y * 4.0) * Float64(t - Float64(z * z))));
	else
		tmp = fma(Float64(-t), Float64(y * -4.0), Float64(x * x));
	end
	return tmp
end
NOTE: x should be positive before calling this function
code[x_, y_, z_, t_] := If[LessEqual[x, 4.5e+148], N[(N[(x * x), $MachinePrecision] + N[(N[(y * 4.0), $MachinePrecision] * N[(t - N[(z * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[((-t) * N[(y * -4.0), $MachinePrecision] + N[(x * x), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
x = |x|\\
\\
\begin{array}{l}
\mathbf{if}\;x \leq 4.5 \cdot 10^{+148}:\\
\;\;\;\;x \cdot x + \left(y \cdot 4\right) \cdot \left(t - z \cdot z\right)\\

\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(-t, y \cdot -4, x \cdot x\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if x < 4.49999999999999994e148

    1. Initial program 89.5%

      \[x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right) \]

    if 4.49999999999999994e148 < x

    1. Initial program 81.1%

      \[x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right) \]
    2. Taylor expanded in x around 0 81.1%

      \[\leadsto \color{blue}{-4 \cdot \left(y \cdot \left({z}^{2} - t\right)\right) + {x}^{2}} \]
    3. Step-by-step derivation
      1. unpow281.1%

        \[\leadsto -4 \cdot \left(y \cdot \left({z}^{2} - t\right)\right) + \color{blue}{x \cdot x} \]
      2. *-commutative81.1%

        \[\leadsto \color{blue}{\left(y \cdot \left({z}^{2} - t\right)\right) \cdot -4} + x \cdot x \]
      3. *-commutative81.1%

        \[\leadsto \color{blue}{\left(\left({z}^{2} - t\right) \cdot y\right)} \cdot -4 + x \cdot x \]
      4. unpow281.1%

        \[\leadsto \left(\left(\color{blue}{z \cdot z} - t\right) \cdot y\right) \cdot -4 + x \cdot x \]
      5. associate-*l*81.1%

        \[\leadsto \color{blue}{\left(z \cdot z - t\right) \cdot \left(y \cdot -4\right)} + x \cdot x \]
      6. rem-log-exp81.1%

        \[\leadsto \left(z \cdot z - t\right) \cdot \left(y \cdot \color{blue}{\log \left(e^{-4}\right)}\right) + x \cdot x \]
      7. log-pow59.5%

        \[\leadsto \left(z \cdot z - t\right) \cdot \color{blue}{\log \left({\left(e^{-4}\right)}^{y}\right)} + x \cdot x \]
      8. fma-udef59.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z \cdot z - t, \log \left({\left(e^{-4}\right)}^{y}\right), x \cdot x\right)} \]
      9. log-pow83.8%

        \[\leadsto \mathsf{fma}\left(z \cdot z - t, \color{blue}{y \cdot \log \left(e^{-4}\right)}, x \cdot x\right) \]
      10. rem-log-exp83.8%

        \[\leadsto \mathsf{fma}\left(z \cdot z - t, y \cdot \color{blue}{-4}, x \cdot x\right) \]
    4. Simplified83.8%

      \[\leadsto \color{blue}{\mathsf{fma}\left(z \cdot z - t, y \cdot -4, x \cdot x\right)} \]
    5. Taylor expanded in z around 0 91.9%

      \[\leadsto \mathsf{fma}\left(\color{blue}{-1 \cdot t}, y \cdot -4, x \cdot x\right) \]
    6. Step-by-step derivation
      1. neg-mul-191.9%

        \[\leadsto \mathsf{fma}\left(\color{blue}{-t}, y \cdot -4, x \cdot x\right) \]
    7. Simplified91.9%

      \[\leadsto \mathsf{fma}\left(\color{blue}{-t}, y \cdot -4, x \cdot x\right) \]
  3. Recombined 2 regimes into one program.
  4. Final simplification89.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq 4.5 \cdot 10^{+148}:\\ \;\;\;\;x \cdot x + \left(y \cdot 4\right) \cdot \left(t - z \cdot z\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-t, y \cdot -4, x \cdot x\right)\\ \end{array} \]

Alternative 3: 58.0% accurate, 0.7× speedup?

\[\begin{array}{l} x = |x|\\ \\ \begin{array}{l} \mathbf{if}\;x \cdot x \leq 3.8 \cdot 10^{-44}:\\ \;\;\;\;y \cdot \left(t \cdot 4\right)\\ \mathbf{elif}\;x \cdot x \leq 9000000000000:\\ \;\;\;\;x \cdot x\\ \mathbf{elif}\;x \cdot x \leq 1.76 \cdot 10^{+152}:\\ \;\;\;\;y \cdot \left(\left(z \cdot z\right) \cdot -4\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot x\\ \end{array} \end{array} \]
NOTE: x should be positive before calling this function
(FPCore (x y z t)
 :precision binary64
 (if (<= (* x x) 3.8e-44)
   (* y (* t 4.0))
   (if (<= (* x x) 9000000000000.0)
     (* x x)
     (if (<= (* x x) 1.76e+152) (* y (* (* z z) -4.0)) (* x x)))))
x = abs(x);
double code(double x, double y, double z, double t) {
	double tmp;
	if ((x * x) <= 3.8e-44) {
		tmp = y * (t * 4.0);
	} else if ((x * x) <= 9000000000000.0) {
		tmp = x * x;
	} else if ((x * x) <= 1.76e+152) {
		tmp = y * ((z * z) * -4.0);
	} else {
		tmp = x * x;
	}
	return tmp;
}
NOTE: x should be positive before calling this function
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if ((x * x) <= 3.8d-44) then
        tmp = y * (t * 4.0d0)
    else if ((x * x) <= 9000000000000.0d0) then
        tmp = x * x
    else if ((x * x) <= 1.76d+152) then
        tmp = y * ((z * z) * (-4.0d0))
    else
        tmp = x * x
    end if
    code = tmp
end function
x = Math.abs(x);
public static double code(double x, double y, double z, double t) {
	double tmp;
	if ((x * x) <= 3.8e-44) {
		tmp = y * (t * 4.0);
	} else if ((x * x) <= 9000000000000.0) {
		tmp = x * x;
	} else if ((x * x) <= 1.76e+152) {
		tmp = y * ((z * z) * -4.0);
	} else {
		tmp = x * x;
	}
	return tmp;
}
x = abs(x)
def code(x, y, z, t):
	tmp = 0
	if (x * x) <= 3.8e-44:
		tmp = y * (t * 4.0)
	elif (x * x) <= 9000000000000.0:
		tmp = x * x
	elif (x * x) <= 1.76e+152:
		tmp = y * ((z * z) * -4.0)
	else:
		tmp = x * x
	return tmp
x = abs(x)
function code(x, y, z, t)
	tmp = 0.0
	if (Float64(x * x) <= 3.8e-44)
		tmp = Float64(y * Float64(t * 4.0));
	elseif (Float64(x * x) <= 9000000000000.0)
		tmp = Float64(x * x);
	elseif (Float64(x * x) <= 1.76e+152)
		tmp = Float64(y * Float64(Float64(z * z) * -4.0));
	else
		tmp = Float64(x * x);
	end
	return tmp
end
x = abs(x)
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if ((x * x) <= 3.8e-44)
		tmp = y * (t * 4.0);
	elseif ((x * x) <= 9000000000000.0)
		tmp = x * x;
	elseif ((x * x) <= 1.76e+152)
		tmp = y * ((z * z) * -4.0);
	else
		tmp = x * x;
	end
	tmp_2 = tmp;
end
NOTE: x should be positive before calling this function
code[x_, y_, z_, t_] := If[LessEqual[N[(x * x), $MachinePrecision], 3.8e-44], N[(y * N[(t * 4.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(x * x), $MachinePrecision], 9000000000000.0], N[(x * x), $MachinePrecision], If[LessEqual[N[(x * x), $MachinePrecision], 1.76e+152], N[(y * N[(N[(z * z), $MachinePrecision] * -4.0), $MachinePrecision]), $MachinePrecision], N[(x * x), $MachinePrecision]]]]
\begin{array}{l}
x = |x|\\
\\
\begin{array}{l}
\mathbf{if}\;x \cdot x \leq 3.8 \cdot 10^{-44}:\\
\;\;\;\;y \cdot \left(t \cdot 4\right)\\

\mathbf{elif}\;x \cdot x \leq 9000000000000:\\
\;\;\;\;x \cdot x\\

\mathbf{elif}\;x \cdot x \leq 1.76 \cdot 10^{+152}:\\
\;\;\;\;y \cdot \left(\left(z \cdot z\right) \cdot -4\right)\\

\mathbf{else}:\\
\;\;\;\;x \cdot x\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (*.f64 x x) < 3.8000000000000001e-44

    1. Initial program 90.7%

      \[x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right) \]
    2. Taylor expanded in t around inf 54.6%

      \[\leadsto \color{blue}{4 \cdot \left(t \cdot y\right)} \]
    3. Step-by-step derivation
      1. associate-*r*54.6%

        \[\leadsto \color{blue}{\left(4 \cdot t\right) \cdot y} \]
      2. *-commutative54.6%

        \[\leadsto \color{blue}{y \cdot \left(4 \cdot t\right)} \]
    4. Simplified54.6%

      \[\leadsto \color{blue}{y \cdot \left(4 \cdot t\right)} \]

    if 3.8000000000000001e-44 < (*.f64 x x) < 9e12 or 1.76000000000000005e152 < (*.f64 x x)

    1. Initial program 84.7%

      \[x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right) \]
    2. Taylor expanded in x around inf 79.0%

      \[\leadsto \color{blue}{{x}^{2}} \]
    3. Step-by-step derivation
      1. unpow279.0%

        \[\leadsto \color{blue}{x \cdot x} \]
    4. Simplified79.0%

      \[\leadsto \color{blue}{x \cdot x} \]

    if 9e12 < (*.f64 x x) < 1.76000000000000005e152

    1. Initial program 92.1%

      \[x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right) \]
    2. Taylor expanded in z around inf 55.7%

      \[\leadsto \color{blue}{-4 \cdot \left(y \cdot {z}^{2}\right)} \]
    3. Step-by-step derivation
      1. *-commutative55.7%

        \[\leadsto \color{blue}{\left(y \cdot {z}^{2}\right) \cdot -4} \]
      2. unpow255.7%

        \[\leadsto \left(y \cdot \color{blue}{\left(z \cdot z\right)}\right) \cdot -4 \]
      3. associate-*l*55.7%

        \[\leadsto \color{blue}{y \cdot \left(\left(z \cdot z\right) \cdot -4\right)} \]
    4. Simplified55.7%

      \[\leadsto \color{blue}{y \cdot \left(\left(z \cdot z\right) \cdot -4\right)} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification65.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \cdot x \leq 3.8 \cdot 10^{-44}:\\ \;\;\;\;y \cdot \left(t \cdot 4\right)\\ \mathbf{elif}\;x \cdot x \leq 9000000000000:\\ \;\;\;\;x \cdot x\\ \mathbf{elif}\;x \cdot x \leq 1.76 \cdot 10^{+152}:\\ \;\;\;\;y \cdot \left(\left(z \cdot z\right) \cdot -4\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot x\\ \end{array} \]

Alternative 4: 86.1% accurate, 0.7× speedup?

\[\begin{array}{l} x = |x|\\ \\ \begin{array}{l} \mathbf{if}\;z \cdot z \leq 8 \cdot 10^{-73}:\\ \;\;\;\;x \cdot x - y \cdot \left(t \cdot -4\right)\\ \mathbf{elif}\;z \cdot z \leq 2.65 \cdot 10^{+306}:\\ \;\;\;\;x \cdot x - \left(z \cdot z\right) \cdot \left(y \cdot 4\right)\\ \mathbf{else}:\\ \;\;\;\;y \cdot \left(\left(z \cdot z\right) \cdot -4\right)\\ \end{array} \end{array} \]
NOTE: x should be positive before calling this function
(FPCore (x y z t)
 :precision binary64
 (if (<= (* z z) 8e-73)
   (- (* x x) (* y (* t -4.0)))
   (if (<= (* z z) 2.65e+306)
     (- (* x x) (* (* z z) (* y 4.0)))
     (* y (* (* z z) -4.0)))))
x = abs(x);
double code(double x, double y, double z, double t) {
	double tmp;
	if ((z * z) <= 8e-73) {
		tmp = (x * x) - (y * (t * -4.0));
	} else if ((z * z) <= 2.65e+306) {
		tmp = (x * x) - ((z * z) * (y * 4.0));
	} else {
		tmp = y * ((z * z) * -4.0);
	}
	return tmp;
}
NOTE: x should be positive before calling this function
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if ((z * z) <= 8d-73) then
        tmp = (x * x) - (y * (t * (-4.0d0)))
    else if ((z * z) <= 2.65d+306) then
        tmp = (x * x) - ((z * z) * (y * 4.0d0))
    else
        tmp = y * ((z * z) * (-4.0d0))
    end if
    code = tmp
end function
x = Math.abs(x);
public static double code(double x, double y, double z, double t) {
	double tmp;
	if ((z * z) <= 8e-73) {
		tmp = (x * x) - (y * (t * -4.0));
	} else if ((z * z) <= 2.65e+306) {
		tmp = (x * x) - ((z * z) * (y * 4.0));
	} else {
		tmp = y * ((z * z) * -4.0);
	}
	return tmp;
}
x = abs(x)
def code(x, y, z, t):
	tmp = 0
	if (z * z) <= 8e-73:
		tmp = (x * x) - (y * (t * -4.0))
	elif (z * z) <= 2.65e+306:
		tmp = (x * x) - ((z * z) * (y * 4.0))
	else:
		tmp = y * ((z * z) * -4.0)
	return tmp
x = abs(x)
function code(x, y, z, t)
	tmp = 0.0
	if (Float64(z * z) <= 8e-73)
		tmp = Float64(Float64(x * x) - Float64(y * Float64(t * -4.0)));
	elseif (Float64(z * z) <= 2.65e+306)
		tmp = Float64(Float64(x * x) - Float64(Float64(z * z) * Float64(y * 4.0)));
	else
		tmp = Float64(y * Float64(Float64(z * z) * -4.0));
	end
	return tmp
end
x = abs(x)
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if ((z * z) <= 8e-73)
		tmp = (x * x) - (y * (t * -4.0));
	elseif ((z * z) <= 2.65e+306)
		tmp = (x * x) - ((z * z) * (y * 4.0));
	else
		tmp = y * ((z * z) * -4.0);
	end
	tmp_2 = tmp;
end
NOTE: x should be positive before calling this function
code[x_, y_, z_, t_] := If[LessEqual[N[(z * z), $MachinePrecision], 8e-73], N[(N[(x * x), $MachinePrecision] - N[(y * N[(t * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(z * z), $MachinePrecision], 2.65e+306], N[(N[(x * x), $MachinePrecision] - N[(N[(z * z), $MachinePrecision] * N[(y * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y * N[(N[(z * z), $MachinePrecision] * -4.0), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
x = |x|\\
\\
\begin{array}{l}
\mathbf{if}\;z \cdot z \leq 8 \cdot 10^{-73}:\\
\;\;\;\;x \cdot x - y \cdot \left(t \cdot -4\right)\\

\mathbf{elif}\;z \cdot z \leq 2.65 \cdot 10^{+306}:\\
\;\;\;\;x \cdot x - \left(z \cdot z\right) \cdot \left(y \cdot 4\right)\\

\mathbf{else}:\\
\;\;\;\;y \cdot \left(\left(z \cdot z\right) \cdot -4\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (*.f64 z z) < 7.99999999999999998e-73

    1. Initial program 98.2%

      \[x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right) \]
    2. Taylor expanded in z around 0 97.4%

      \[\leadsto x \cdot x - \color{blue}{-4 \cdot \left(t \cdot y\right)} \]
    3. Step-by-step derivation
      1. associate-*r*97.4%

        \[\leadsto x \cdot x - \color{blue}{\left(-4 \cdot t\right) \cdot y} \]
    4. Simplified97.4%

      \[\leadsto x \cdot x - \color{blue}{\left(-4 \cdot t\right) \cdot y} \]

    if 7.99999999999999998e-73 < (*.f64 z z) < 2.65000000000000013e306

    1. Initial program 95.9%

      \[x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right) \]
    2. Taylor expanded in z around inf 81.6%

      \[\leadsto x \cdot x - \left(y \cdot 4\right) \cdot \color{blue}{{z}^{2}} \]
    3. Step-by-step derivation
      1. unpow281.6%

        \[\leadsto x \cdot x - \left(y \cdot 4\right) \cdot \color{blue}{\left(z \cdot z\right)} \]
    4. Simplified81.6%

      \[\leadsto x \cdot x - \left(y \cdot 4\right) \cdot \color{blue}{\left(z \cdot z\right)} \]

    if 2.65000000000000013e306 < (*.f64 z z)

    1. Initial program 63.5%

      \[x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right) \]
    2. Taylor expanded in z around inf 69.3%

      \[\leadsto \color{blue}{-4 \cdot \left(y \cdot {z}^{2}\right)} \]
    3. Step-by-step derivation
      1. *-commutative69.3%

        \[\leadsto \color{blue}{\left(y \cdot {z}^{2}\right) \cdot -4} \]
      2. unpow269.3%

        \[\leadsto \left(y \cdot \color{blue}{\left(z \cdot z\right)}\right) \cdot -4 \]
      3. associate-*l*69.3%

        \[\leadsto \color{blue}{y \cdot \left(\left(z \cdot z\right) \cdot -4\right)} \]
    4. Simplified69.3%

      \[\leadsto \color{blue}{y \cdot \left(\left(z \cdot z\right) \cdot -4\right)} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification85.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \cdot z \leq 8 \cdot 10^{-73}:\\ \;\;\;\;x \cdot x - y \cdot \left(t \cdot -4\right)\\ \mathbf{elif}\;z \cdot z \leq 2.65 \cdot 10^{+306}:\\ \;\;\;\;x \cdot x - \left(z \cdot z\right) \cdot \left(y \cdot 4\right)\\ \mathbf{else}:\\ \;\;\;\;y \cdot \left(\left(z \cdot z\right) \cdot -4\right)\\ \end{array} \]

Alternative 5: 93.1% accurate, 0.8× speedup?

\[\begin{array}{l} x = |x|\\ \\ \begin{array}{l} \mathbf{if}\;x \cdot x \leq 5 \cdot 10^{+301}:\\ \;\;\;\;x \cdot x + \left(y \cdot 4\right) \cdot \left(t - z \cdot z\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot x\\ \end{array} \end{array} \]
NOTE: x should be positive before calling this function
(FPCore (x y z t)
 :precision binary64
 (if (<= (* x x) 5e+301) (+ (* x x) (* (* y 4.0) (- t (* z z)))) (* x x)))
x = abs(x);
double code(double x, double y, double z, double t) {
	double tmp;
	if ((x * x) <= 5e+301) {
		tmp = (x * x) + ((y * 4.0) * (t - (z * z)));
	} else {
		tmp = x * x;
	}
	return tmp;
}
NOTE: x should be positive before calling this function
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if ((x * x) <= 5d+301) then
        tmp = (x * x) + ((y * 4.0d0) * (t - (z * z)))
    else
        tmp = x * x
    end if
    code = tmp
end function
x = Math.abs(x);
public static double code(double x, double y, double z, double t) {
	double tmp;
	if ((x * x) <= 5e+301) {
		tmp = (x * x) + ((y * 4.0) * (t - (z * z)));
	} else {
		tmp = x * x;
	}
	return tmp;
}
x = abs(x)
def code(x, y, z, t):
	tmp = 0
	if (x * x) <= 5e+301:
		tmp = (x * x) + ((y * 4.0) * (t - (z * z)))
	else:
		tmp = x * x
	return tmp
x = abs(x)
function code(x, y, z, t)
	tmp = 0.0
	if (Float64(x * x) <= 5e+301)
		tmp = Float64(Float64(x * x) + Float64(Float64(y * 4.0) * Float64(t - Float64(z * z))));
	else
		tmp = Float64(x * x);
	end
	return tmp
end
x = abs(x)
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if ((x * x) <= 5e+301)
		tmp = (x * x) + ((y * 4.0) * (t - (z * z)));
	else
		tmp = x * x;
	end
	tmp_2 = tmp;
end
NOTE: x should be positive before calling this function
code[x_, y_, z_, t_] := If[LessEqual[N[(x * x), $MachinePrecision], 5e+301], N[(N[(x * x), $MachinePrecision] + N[(N[(y * 4.0), $MachinePrecision] * N[(t - N[(z * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * x), $MachinePrecision]]
\begin{array}{l}
x = |x|\\
\\
\begin{array}{l}
\mathbf{if}\;x \cdot x \leq 5 \cdot 10^{+301}:\\
\;\;\;\;x \cdot x + \left(y \cdot 4\right) \cdot \left(t - z \cdot z\right)\\

\mathbf{else}:\\
\;\;\;\;x \cdot x\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (*.f64 x x) < 5.0000000000000004e301

    1. Initial program 92.7%

      \[x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right) \]

    if 5.0000000000000004e301 < (*.f64 x x)

    1. Initial program 75.0%

      \[x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right) \]
    2. Taylor expanded in x around inf 90.6%

      \[\leadsto \color{blue}{{x}^{2}} \]
    3. Step-by-step derivation
      1. unpow290.6%

        \[\leadsto \color{blue}{x \cdot x} \]
    4. Simplified90.6%

      \[\leadsto \color{blue}{x \cdot x} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification92.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \cdot x \leq 5 \cdot 10^{+301}:\\ \;\;\;\;x \cdot x + \left(y \cdot 4\right) \cdot \left(t - z \cdot z\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot x\\ \end{array} \]

Alternative 6: 74.2% accurate, 1.2× speedup?

\[\begin{array}{l} x = |x|\\ \\ \begin{array}{l} \mathbf{if}\;z \leq 2.2 \cdot 10^{+84}:\\ \;\;\;\;x \cdot x - y \cdot \left(t \cdot -4\right)\\ \mathbf{else}:\\ \;\;\;\;y \cdot \left(\left(z \cdot z\right) \cdot -4\right)\\ \end{array} \end{array} \]
NOTE: x should be positive before calling this function
(FPCore (x y z t)
 :precision binary64
 (if (<= z 2.2e+84) (- (* x x) (* y (* t -4.0))) (* y (* (* z z) -4.0))))
x = abs(x);
double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= 2.2e+84) {
		tmp = (x * x) - (y * (t * -4.0));
	} else {
		tmp = y * ((z * z) * -4.0);
	}
	return tmp;
}
NOTE: x should be positive before calling this function
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if (z <= 2.2d+84) then
        tmp = (x * x) - (y * (t * (-4.0d0)))
    else
        tmp = y * ((z * z) * (-4.0d0))
    end if
    code = tmp
end function
x = Math.abs(x);
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= 2.2e+84) {
		tmp = (x * x) - (y * (t * -4.0));
	} else {
		tmp = y * ((z * z) * -4.0);
	}
	return tmp;
}
x = abs(x)
def code(x, y, z, t):
	tmp = 0
	if z <= 2.2e+84:
		tmp = (x * x) - (y * (t * -4.0))
	else:
		tmp = y * ((z * z) * -4.0)
	return tmp
x = abs(x)
function code(x, y, z, t)
	tmp = 0.0
	if (z <= 2.2e+84)
		tmp = Float64(Float64(x * x) - Float64(y * Float64(t * -4.0)));
	else
		tmp = Float64(y * Float64(Float64(z * z) * -4.0));
	end
	return tmp
end
x = abs(x)
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (z <= 2.2e+84)
		tmp = (x * x) - (y * (t * -4.0));
	else
		tmp = y * ((z * z) * -4.0);
	end
	tmp_2 = tmp;
end
NOTE: x should be positive before calling this function
code[x_, y_, z_, t_] := If[LessEqual[z, 2.2e+84], N[(N[(x * x), $MachinePrecision] - N[(y * N[(t * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y * N[(N[(z * z), $MachinePrecision] * -4.0), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
x = |x|\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq 2.2 \cdot 10^{+84}:\\
\;\;\;\;x \cdot x - y \cdot \left(t \cdot -4\right)\\

\mathbf{else}:\\
\;\;\;\;y \cdot \left(\left(z \cdot z\right) \cdot -4\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < 2.1999999999999998e84

    1. Initial program 93.4%

      \[x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right) \]
    2. Taylor expanded in z around 0 77.2%

      \[\leadsto x \cdot x - \color{blue}{-4 \cdot \left(t \cdot y\right)} \]
    3. Step-by-step derivation
      1. associate-*r*77.2%

        \[\leadsto x \cdot x - \color{blue}{\left(-4 \cdot t\right) \cdot y} \]
    4. Simplified77.2%

      \[\leadsto x \cdot x - \color{blue}{\left(-4 \cdot t\right) \cdot y} \]

    if 2.1999999999999998e84 < z

    1. Initial program 66.6%

      \[x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right) \]
    2. Taylor expanded in z around inf 70.8%

      \[\leadsto \color{blue}{-4 \cdot \left(y \cdot {z}^{2}\right)} \]
    3. Step-by-step derivation
      1. *-commutative70.8%

        \[\leadsto \color{blue}{\left(y \cdot {z}^{2}\right) \cdot -4} \]
      2. unpow270.8%

        \[\leadsto \left(y \cdot \color{blue}{\left(z \cdot z\right)}\right) \cdot -4 \]
      3. associate-*l*70.8%

        \[\leadsto \color{blue}{y \cdot \left(\left(z \cdot z\right) \cdot -4\right)} \]
    4. Simplified70.8%

      \[\leadsto \color{blue}{y \cdot \left(\left(z \cdot z\right) \cdot -4\right)} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification76.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq 2.2 \cdot 10^{+84}:\\ \;\;\;\;x \cdot x - y \cdot \left(t \cdot -4\right)\\ \mathbf{else}:\\ \;\;\;\;y \cdot \left(\left(z \cdot z\right) \cdot -4\right)\\ \end{array} \]

Alternative 7: 58.5% accurate, 1.4× speedup?

\[\begin{array}{l} x = |x|\\ \\ \begin{array}{l} \mathbf{if}\;x \cdot x \leq 1.48 \cdot 10^{-52}:\\ \;\;\;\;y \cdot \left(t \cdot 4\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot x\\ \end{array} \end{array} \]
NOTE: x should be positive before calling this function
(FPCore (x y z t)
 :precision binary64
 (if (<= (* x x) 1.48e-52) (* y (* t 4.0)) (* x x)))
x = abs(x);
double code(double x, double y, double z, double t) {
	double tmp;
	if ((x * x) <= 1.48e-52) {
		tmp = y * (t * 4.0);
	} else {
		tmp = x * x;
	}
	return tmp;
}
NOTE: x should be positive before calling this function
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if ((x * x) <= 1.48d-52) then
        tmp = y * (t * 4.0d0)
    else
        tmp = x * x
    end if
    code = tmp
end function
x = Math.abs(x);
public static double code(double x, double y, double z, double t) {
	double tmp;
	if ((x * x) <= 1.48e-52) {
		tmp = y * (t * 4.0);
	} else {
		tmp = x * x;
	}
	return tmp;
}
x = abs(x)
def code(x, y, z, t):
	tmp = 0
	if (x * x) <= 1.48e-52:
		tmp = y * (t * 4.0)
	else:
		tmp = x * x
	return tmp
x = abs(x)
function code(x, y, z, t)
	tmp = 0.0
	if (Float64(x * x) <= 1.48e-52)
		tmp = Float64(y * Float64(t * 4.0));
	else
		tmp = Float64(x * x);
	end
	return tmp
end
x = abs(x)
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if ((x * x) <= 1.48e-52)
		tmp = y * (t * 4.0);
	else
		tmp = x * x;
	end
	tmp_2 = tmp;
end
NOTE: x should be positive before calling this function
code[x_, y_, z_, t_] := If[LessEqual[N[(x * x), $MachinePrecision], 1.48e-52], N[(y * N[(t * 4.0), $MachinePrecision]), $MachinePrecision], N[(x * x), $MachinePrecision]]
\begin{array}{l}
x = |x|\\
\\
\begin{array}{l}
\mathbf{if}\;x \cdot x \leq 1.48 \cdot 10^{-52}:\\
\;\;\;\;y \cdot \left(t \cdot 4\right)\\

\mathbf{else}:\\
\;\;\;\;x \cdot x\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (*.f64 x x) < 1.47999999999999993e-52

    1. Initial program 90.7%

      \[x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right) \]
    2. Taylor expanded in t around inf 54.6%

      \[\leadsto \color{blue}{4 \cdot \left(t \cdot y\right)} \]
    3. Step-by-step derivation
      1. associate-*r*54.6%

        \[\leadsto \color{blue}{\left(4 \cdot t\right) \cdot y} \]
      2. *-commutative54.6%

        \[\leadsto \color{blue}{y \cdot \left(4 \cdot t\right)} \]
    4. Simplified54.6%

      \[\leadsto \color{blue}{y \cdot \left(4 \cdot t\right)} \]

    if 1.47999999999999993e-52 < (*.f64 x x)

    1. Initial program 86.5%

      \[x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right) \]
    2. Taylor expanded in x around inf 64.9%

      \[\leadsto \color{blue}{{x}^{2}} \]
    3. Step-by-step derivation
      1. unpow264.9%

        \[\leadsto \color{blue}{x \cdot x} \]
    4. Simplified64.9%

      \[\leadsto \color{blue}{x \cdot x} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification60.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \cdot x \leq 1.48 \cdot 10^{-52}:\\ \;\;\;\;y \cdot \left(t \cdot 4\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot x\\ \end{array} \]

Alternative 8: 40.4% accurate, 4.3× speedup?

\[\begin{array}{l} x = |x|\\ \\ x \cdot x \end{array} \]
NOTE: x should be positive before calling this function
(FPCore (x y z t) :precision binary64 (* x x))
x = abs(x);
double code(double x, double y, double z, double t) {
	return x * x;
}
NOTE: x should be positive before calling this function
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    code = x * x
end function
x = Math.abs(x);
public static double code(double x, double y, double z, double t) {
	return x * x;
}
x = abs(x)
def code(x, y, z, t):
	return x * x
x = abs(x)
function code(x, y, z, t)
	return Float64(x * x)
end
x = abs(x)
function tmp = code(x, y, z, t)
	tmp = x * x;
end
NOTE: x should be positive before calling this function
code[x_, y_, z_, t_] := N[(x * x), $MachinePrecision]
\begin{array}{l}
x = |x|\\
\\
x \cdot x
\end{array}
Derivation
  1. Initial program 88.3%

    \[x \cdot x - \left(y \cdot 4\right) \cdot \left(z \cdot z - t\right) \]
  2. Taylor expanded in x around inf 43.0%

    \[\leadsto \color{blue}{{x}^{2}} \]
  3. Step-by-step derivation
    1. unpow243.0%

      \[\leadsto \color{blue}{x \cdot x} \]
  4. Simplified43.0%

    \[\leadsto \color{blue}{x \cdot x} \]
  5. Final simplification43.0%

    \[\leadsto x \cdot x \]

Developer target: 91.0% accurate, 1.0× speedup?

\[\begin{array}{l} \\ x \cdot x - 4 \cdot \left(y \cdot \left(z \cdot z - t\right)\right) \end{array} \]
(FPCore (x y z t) :precision binary64 (- (* x x) (* 4.0 (* y (- (* z z) t)))))
double code(double x, double y, double z, double t) {
	return (x * x) - (4.0 * (y * ((z * z) - t)));
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    code = (x * x) - (4.0d0 * (y * ((z * z) - t)))
end function
public static double code(double x, double y, double z, double t) {
	return (x * x) - (4.0 * (y * ((z * z) - t)));
}
def code(x, y, z, t):
	return (x * x) - (4.0 * (y * ((z * z) - t)))
function code(x, y, z, t)
	return Float64(Float64(x * x) - Float64(4.0 * Float64(y * Float64(Float64(z * z) - t))))
end
function tmp = code(x, y, z, t)
	tmp = (x * x) - (4.0 * (y * ((z * z) - t)));
end
code[x_, y_, z_, t_] := N[(N[(x * x), $MachinePrecision] - N[(4.0 * N[(y * N[(N[(z * z), $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
x \cdot x - 4 \cdot \left(y \cdot \left(z \cdot z - t\right)\right)
\end{array}

Reproduce

?
herbie shell --seed 2023287 
(FPCore (x y z t)
  :name "Graphics.Rasterific.Shading:$sradialGradientWithFocusShader from Rasterific-0.6.1, B"
  :precision binary64

  :herbie-target
  (- (* x x) (* 4.0 (* y (- (* z z) t))))

  (- (* x x) (* (* y 4.0) (- (* z z) t))))