Data.Number.Erf:$cinvnormcdf from erf-2.0.0.0, A

Percentage Accurate: 99.4% → 99.8%
Time: 13.4s
Alternatives: 12
Speedup: 1.0×

Specification

?
\[\begin{array}{l} \\ \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (* (* (- (* x 0.5) y) (sqrt (* z 2.0))) (exp (/ (* t t) 2.0))))
double code(double x, double y, double z, double t) {
	return (((x * 0.5) - y) * sqrt((z * 2.0))) * exp(((t * t) / 2.0));
}
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 * 0.5d0) - y) * sqrt((z * 2.0d0))) * exp(((t * t) / 2.0d0))
end function
public static double code(double x, double y, double z, double t) {
	return (((x * 0.5) - y) * Math.sqrt((z * 2.0))) * Math.exp(((t * t) / 2.0));
}
def code(x, y, z, t):
	return (((x * 0.5) - y) * math.sqrt((z * 2.0))) * math.exp(((t * t) / 2.0))
function code(x, y, z, t)
	return Float64(Float64(Float64(Float64(x * 0.5) - y) * sqrt(Float64(z * 2.0))) * exp(Float64(Float64(t * t) / 2.0)))
end
function tmp = code(x, y, z, t)
	tmp = (((x * 0.5) - y) * sqrt((z * 2.0))) * exp(((t * t) / 2.0));
end
code[x_, y_, z_, t_] := N[(N[(N[(N[(x * 0.5), $MachinePrecision] - y), $MachinePrecision] * N[Sqrt[N[(z * 2.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * N[Exp[N[(N[(t * t), $MachinePrecision] / 2.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}}
\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 12 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: 99.4% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (* (* (- (* x 0.5) y) (sqrt (* z 2.0))) (exp (/ (* t t) 2.0))))
double code(double x, double y, double z, double t) {
	return (((x * 0.5) - y) * sqrt((z * 2.0))) * exp(((t * t) / 2.0));
}
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 * 0.5d0) - y) * sqrt((z * 2.0d0))) * exp(((t * t) / 2.0d0))
end function
public static double code(double x, double y, double z, double t) {
	return (((x * 0.5) - y) * Math.sqrt((z * 2.0))) * Math.exp(((t * t) / 2.0));
}
def code(x, y, z, t):
	return (((x * 0.5) - y) * math.sqrt((z * 2.0))) * math.exp(((t * t) / 2.0))
function code(x, y, z, t)
	return Float64(Float64(Float64(Float64(x * 0.5) - y) * sqrt(Float64(z * 2.0))) * exp(Float64(Float64(t * t) / 2.0)))
end
function tmp = code(x, y, z, t)
	tmp = (((x * 0.5) - y) * sqrt((z * 2.0))) * exp(((t * t) / 2.0));
end
code[x_, y_, z_, t_] := N[(N[(N[(N[(x * 0.5), $MachinePrecision] - y), $MachinePrecision] * N[Sqrt[N[(z * 2.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * N[Exp[N[(N[(t * t), $MachinePrecision] / 2.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}}
\end{array}

Alternative 1: 99.8% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (* (- (* x 0.5) y) (sqrt (* z (* 2.0 (exp (pow t 2.0)))))))
double code(double x, double y, double z, double t) {
	return ((x * 0.5) - y) * sqrt((z * (2.0 * exp(pow(t, 2.0)))));
}
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 * 0.5d0) - y) * sqrt((z * (2.0d0 * exp((t ** 2.0d0)))))
end function
public static double code(double x, double y, double z, double t) {
	return ((x * 0.5) - y) * Math.sqrt((z * (2.0 * Math.exp(Math.pow(t, 2.0)))));
}
def code(x, y, z, t):
	return ((x * 0.5) - y) * math.sqrt((z * (2.0 * math.exp(math.pow(t, 2.0)))))
function code(x, y, z, t)
	return Float64(Float64(Float64(x * 0.5) - y) * sqrt(Float64(z * Float64(2.0 * exp((t ^ 2.0))))))
end
function tmp = code(x, y, z, t)
	tmp = ((x * 0.5) - y) * sqrt((z * (2.0 * exp((t ^ 2.0)))));
end
code[x_, y_, z_, t_] := N[(N[(N[(x * 0.5), $MachinePrecision] - y), $MachinePrecision] * N[Sqrt[N[(z * N[(2.0 * N[Exp[N[Power[t, 2.0], $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}
\end{array}
Derivation
  1. Initial program 99.1%

    \[\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \]
  2. Step-by-step derivation
    1. sqr-neg99.1%

      \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{\color{blue}{\left(-t\right) \cdot \left(-t\right)}}{2}} \]
    2. associate-/l*99.1%

      \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}} \]
    3. distribute-frac-neg99.1%

      \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{-\frac{t}{\frac{2}{-t}}}} \]
    4. exp-neg99.1%

      \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot \color{blue}{\frac{1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
    5. associate-*r/99.1%

      \[\leadsto \color{blue}{\frac{\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot 1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
    6. *-rgt-identity99.1%

      \[\leadsto \frac{\color{blue}{\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}}}{e^{\frac{t}{\frac{2}{-t}}}} \]
    7. associate-*r/99.9%

      \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \frac{\sqrt{z \cdot 2}}{e^{\frac{t}{\frac{2}{-t}}}}} \]
    8. *-rgt-identity99.9%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \frac{\color{blue}{\sqrt{z \cdot 2} \cdot 1}}{e^{\frac{t}{\frac{2}{-t}}}} \]
    9. associate-*r/99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(\sqrt{z \cdot 2} \cdot \frac{1}{e^{\frac{t}{\frac{2}{-t}}}}\right)} \]
    10. exp-neg99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{e^{-\frac{t}{\frac{2}{-t}}}}\right) \]
    11. distribute-frac-neg99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}}\right) \]
    12. associate-/l*99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{\left(-t\right) \cdot \left(-t\right)}{2}}}\right) \]
    13. sqr-neg99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\frac{\color{blue}{t \cdot t}}{2}}\right) \]
    14. exp-sqrt99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{\sqrt{e^{t \cdot t}}}\right) \]
  3. Simplified99.8%

    \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} \]
  4. Step-by-step derivation
    1. expm1-log1p-u98.4%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)\right)} \]
    2. expm1-udef74.0%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} - 1\right)} \]
    3. sqrt-unprod74.0%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\color{blue}{\sqrt{\left(z \cdot 2\right) \cdot e^{t \cdot t}}}\right)} - 1\right) \]
    4. associate-*l*74.0%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{\color{blue}{z \cdot \left(2 \cdot e^{t \cdot t}\right)}}\right)} - 1\right) \]
    5. pow274.0%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{\color{blue}{{t}^{2}}}\right)}\right)} - 1\right) \]
  5. Applied egg-rr74.0%

    \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)} - 1\right)} \]
  6. Step-by-step derivation
    1. expm1-def98.4%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)\right)} \]
    2. expm1-log1p99.9%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
  7. Simplified99.9%

    \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
  8. Final simplification99.9%

    \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)} \]

Alternative 2: 99.4% accurate, 1.0× speedup?

\[\begin{array}{l} \\ e^{\frac{t \cdot t}{2}} \cdot \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (* (exp (/ (* t t) 2.0)) (* (- (* x 0.5) y) (sqrt (* z 2.0)))))
double code(double x, double y, double z, double t) {
	return exp(((t * t) / 2.0)) * (((x * 0.5) - y) * sqrt((z * 2.0)));
}
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 = exp(((t * t) / 2.0d0)) * (((x * 0.5d0) - y) * sqrt((z * 2.0d0)))
end function
public static double code(double x, double y, double z, double t) {
	return Math.exp(((t * t) / 2.0)) * (((x * 0.5) - y) * Math.sqrt((z * 2.0)));
}
def code(x, y, z, t):
	return math.exp(((t * t) / 2.0)) * (((x * 0.5) - y) * math.sqrt((z * 2.0)))
function code(x, y, z, t)
	return Float64(exp(Float64(Float64(t * t) / 2.0)) * Float64(Float64(Float64(x * 0.5) - y) * sqrt(Float64(z * 2.0))))
end
function tmp = code(x, y, z, t)
	tmp = exp(((t * t) / 2.0)) * (((x * 0.5) - y) * sqrt((z * 2.0)));
end
code[x_, y_, z_, t_] := N[(N[Exp[N[(N[(t * t), $MachinePrecision] / 2.0), $MachinePrecision]], $MachinePrecision] * N[(N[(N[(x * 0.5), $MachinePrecision] - y), $MachinePrecision] * N[Sqrt[N[(z * 2.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
e^{\frac{t \cdot t}{2}} \cdot \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right)
\end{array}
Derivation
  1. Initial program 99.1%

    \[\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \]
  2. Final simplification99.1%

    \[\leadsto e^{\frac{t \cdot t}{2}} \cdot \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \]

Alternative 3: 70.6% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x \cdot 0.5 - y\\ \mathbf{if}\;t \leq 1:\\ \;\;\;\;t_1 \cdot \sqrt{z \cdot 2}\\ \mathbf{else}:\\ \;\;\;\;t_1 \cdot \sqrt{{t}^{2} \cdot \left(z \cdot 2\right)}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (- (* x 0.5) y)))
   (if (<= t 1.0)
     (* t_1 (sqrt (* z 2.0)))
     (* t_1 (sqrt (* (pow t 2.0) (* z 2.0)))))))
double code(double x, double y, double z, double t) {
	double t_1 = (x * 0.5) - y;
	double tmp;
	if (t <= 1.0) {
		tmp = t_1 * sqrt((z * 2.0));
	} else {
		tmp = t_1 * sqrt((pow(t, 2.0) * (z * 2.0)));
	}
	return tmp;
}
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) :: t_1
    real(8) :: tmp
    t_1 = (x * 0.5d0) - y
    if (t <= 1.0d0) then
        tmp = t_1 * sqrt((z * 2.0d0))
    else
        tmp = t_1 * sqrt(((t ** 2.0d0) * (z * 2.0d0)))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double t_1 = (x * 0.5) - y;
	double tmp;
	if (t <= 1.0) {
		tmp = t_1 * Math.sqrt((z * 2.0));
	} else {
		tmp = t_1 * Math.sqrt((Math.pow(t, 2.0) * (z * 2.0)));
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = (x * 0.5) - y
	tmp = 0
	if t <= 1.0:
		tmp = t_1 * math.sqrt((z * 2.0))
	else:
		tmp = t_1 * math.sqrt((math.pow(t, 2.0) * (z * 2.0)))
	return tmp
function code(x, y, z, t)
	t_1 = Float64(Float64(x * 0.5) - y)
	tmp = 0.0
	if (t <= 1.0)
		tmp = Float64(t_1 * sqrt(Float64(z * 2.0)));
	else
		tmp = Float64(t_1 * sqrt(Float64((t ^ 2.0) * Float64(z * 2.0))));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = (x * 0.5) - y;
	tmp = 0.0;
	if (t <= 1.0)
		tmp = t_1 * sqrt((z * 2.0));
	else
		tmp = t_1 * sqrt(((t ^ 2.0) * (z * 2.0)));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x * 0.5), $MachinePrecision] - y), $MachinePrecision]}, If[LessEqual[t, 1.0], N[(t$95$1 * N[Sqrt[N[(z * 2.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(t$95$1 * N[Sqrt[N[(N[Power[t, 2.0], $MachinePrecision] * N[(z * 2.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := x \cdot 0.5 - y\\
\mathbf{if}\;t \leq 1:\\
\;\;\;\;t_1 \cdot \sqrt{z \cdot 2}\\

\mathbf{else}:\\
\;\;\;\;t_1 \cdot \sqrt{{t}^{2} \cdot \left(z \cdot 2\right)}\\


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

    1. Initial program 99.3%

      \[\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \]
    2. Step-by-step derivation
      1. sqr-neg99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{\color{blue}{\left(-t\right) \cdot \left(-t\right)}}{2}} \]
      2. associate-/l*99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}} \]
      3. distribute-frac-neg99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{-\frac{t}{\frac{2}{-t}}}} \]
      4. exp-neg99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot \color{blue}{\frac{1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      5. associate-*r/99.3%

        \[\leadsto \color{blue}{\frac{\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot 1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      6. *-rgt-identity99.3%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}}}{e^{\frac{t}{\frac{2}{-t}}}} \]
      7. associate-*r/99.8%

        \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \frac{\sqrt{z \cdot 2}}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      8. *-rgt-identity99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \frac{\color{blue}{\sqrt{z \cdot 2} \cdot 1}}{e^{\frac{t}{\frac{2}{-t}}}} \]
      9. associate-*r/99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(\sqrt{z \cdot 2} \cdot \frac{1}{e^{\frac{t}{\frac{2}{-t}}}}\right)} \]
      10. exp-neg99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{e^{-\frac{t}{\frac{2}{-t}}}}\right) \]
      11. distribute-frac-neg99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}}\right) \]
      12. associate-/l*99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{\left(-t\right) \cdot \left(-t\right)}{2}}}\right) \]
      13. sqr-neg99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\frac{\color{blue}{t \cdot t}}{2}}\right) \]
      14. exp-sqrt99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{\sqrt{e^{t \cdot t}}}\right) \]
    3. Simplified99.8%

      \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} \]
    4. Step-by-step derivation
      1. expm1-log1p-u98.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)\right)} \]
      2. expm1-udef66.9%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} - 1\right)} \]
      3. sqrt-unprod66.9%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\color{blue}{\sqrt{\left(z \cdot 2\right) \cdot e^{t \cdot t}}}\right)} - 1\right) \]
      4. associate-*l*66.9%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{\color{blue}{z \cdot \left(2 \cdot e^{t \cdot t}\right)}}\right)} - 1\right) \]
      5. pow266.9%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{\color{blue}{{t}^{2}}}\right)}\right)} - 1\right) \]
    5. Applied egg-rr66.9%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)} - 1\right)} \]
    6. Step-by-step derivation
      1. expm1-def98.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)\right)} \]
      2. expm1-log1p99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
    7. Simplified99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
    8. Taylor expanded in t around 0 71.0%

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

    if 1 < t

    1. Initial program 98.2%

      \[\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \]
    2. Step-by-step derivation
      1. sqr-neg98.2%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{\color{blue}{\left(-t\right) \cdot \left(-t\right)}}{2}} \]
      2. associate-/l*98.2%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}} \]
      3. distribute-frac-neg98.2%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{-\frac{t}{\frac{2}{-t}}}} \]
      4. exp-neg98.2%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot \color{blue}{\frac{1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      5. associate-*r/98.2%

        \[\leadsto \color{blue}{\frac{\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot 1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      6. *-rgt-identity98.2%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}}}{e^{\frac{t}{\frac{2}{-t}}}} \]
      7. associate-*r/100.0%

        \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \frac{\sqrt{z \cdot 2}}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      8. *-rgt-identity100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \frac{\color{blue}{\sqrt{z \cdot 2} \cdot 1}}{e^{\frac{t}{\frac{2}{-t}}}} \]
      9. associate-*r/100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(\sqrt{z \cdot 2} \cdot \frac{1}{e^{\frac{t}{\frac{2}{-t}}}}\right)} \]
      10. exp-neg100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{e^{-\frac{t}{\frac{2}{-t}}}}\right) \]
      11. distribute-frac-neg100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}}\right) \]
      12. associate-/l*100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{\left(-t\right) \cdot \left(-t\right)}{2}}}\right) \]
      13. sqr-neg100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\frac{\color{blue}{t \cdot t}}{2}}\right) \]
      14. exp-sqrt100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{\sqrt{e^{t \cdot t}}}\right) \]
    3. Simplified100.0%

      \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} \]
    4. Step-by-step derivation
      1. expm1-log1p-u100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)\right)} \]
      2. expm1-udef100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} - 1\right)} \]
      3. sqrt-unprod100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\color{blue}{\sqrt{\left(z \cdot 2\right) \cdot e^{t \cdot t}}}\right)} - 1\right) \]
      4. associate-*l*100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{\color{blue}{z \cdot \left(2 \cdot e^{t \cdot t}\right)}}\right)} - 1\right) \]
      5. pow2100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{\color{blue}{{t}^{2}}}\right)}\right)} - 1\right) \]
    5. Applied egg-rr100.0%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)} - 1\right)} \]
    6. Step-by-step derivation
      1. expm1-def100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)\right)} \]
      2. expm1-log1p100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
    7. Simplified100.0%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
    8. Taylor expanded in t around 0 79.3%

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

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

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot \left(2 \cdot \left(\color{blue}{t \cdot t} + 1\right)\right)} \]
      3. fma-def79.3%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot \left(2 \cdot \color{blue}{\mathsf{fma}\left(t, t, 1\right)}\right)} \]
    10. Simplified79.3%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot \left(2 \cdot \color{blue}{\mathsf{fma}\left(t, t, 1\right)}\right)} \]
    11. Taylor expanded in t around inf 79.3%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{\color{blue}{2 \cdot \left({t}^{2} \cdot z\right)}} \]
    12. Step-by-step derivation
      1. *-commutative79.3%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{2 \cdot \color{blue}{\left(z \cdot {t}^{2}\right)}} \]
      2. *-commutative79.3%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{\color{blue}{\left(z \cdot {t}^{2}\right) \cdot 2}} \]
      3. *-commutative79.3%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{\color{blue}{\left({t}^{2} \cdot z\right)} \cdot 2} \]
      4. associate-*l*79.3%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{\color{blue}{{t}^{2} \cdot \left(z \cdot 2\right)}} \]
    13. Simplified79.3%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{\color{blue}{{t}^{2} \cdot \left(z \cdot 2\right)}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification72.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq 1:\\ \;\;\;\;\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\\ \mathbf{else}:\\ \;\;\;\;\left(x \cdot 0.5 - y\right) \cdot \sqrt{{t}^{2} \cdot \left(z \cdot 2\right)}\\ \end{array} \]

Alternative 4: 79.1% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x \cdot 0.5 - y\\ \mathbf{if}\;t \leq 10^{+16}:\\ \;\;\;\;t_1 \cdot \left(\sqrt{z \cdot 2} \cdot \mathsf{hypot}\left(1, t\right)\right)\\ \mathbf{else}:\\ \;\;\;\;t_1 \cdot \sqrt{{t}^{2} \cdot \left(z \cdot 2\right)}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (- (* x 0.5) y)))
   (if (<= t 1e+16)
     (* t_1 (* (sqrt (* z 2.0)) (hypot 1.0 t)))
     (* t_1 (sqrt (* (pow t 2.0) (* z 2.0)))))))
double code(double x, double y, double z, double t) {
	double t_1 = (x * 0.5) - y;
	double tmp;
	if (t <= 1e+16) {
		tmp = t_1 * (sqrt((z * 2.0)) * hypot(1.0, t));
	} else {
		tmp = t_1 * sqrt((pow(t, 2.0) * (z * 2.0)));
	}
	return tmp;
}
public static double code(double x, double y, double z, double t) {
	double t_1 = (x * 0.5) - y;
	double tmp;
	if (t <= 1e+16) {
		tmp = t_1 * (Math.sqrt((z * 2.0)) * Math.hypot(1.0, t));
	} else {
		tmp = t_1 * Math.sqrt((Math.pow(t, 2.0) * (z * 2.0)));
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = (x * 0.5) - y
	tmp = 0
	if t <= 1e+16:
		tmp = t_1 * (math.sqrt((z * 2.0)) * math.hypot(1.0, t))
	else:
		tmp = t_1 * math.sqrt((math.pow(t, 2.0) * (z * 2.0)))
	return tmp
function code(x, y, z, t)
	t_1 = Float64(Float64(x * 0.5) - y)
	tmp = 0.0
	if (t <= 1e+16)
		tmp = Float64(t_1 * Float64(sqrt(Float64(z * 2.0)) * hypot(1.0, t)));
	else
		tmp = Float64(t_1 * sqrt(Float64((t ^ 2.0) * Float64(z * 2.0))));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = (x * 0.5) - y;
	tmp = 0.0;
	if (t <= 1e+16)
		tmp = t_1 * (sqrt((z * 2.0)) * hypot(1.0, t));
	else
		tmp = t_1 * sqrt(((t ^ 2.0) * (z * 2.0)));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x * 0.5), $MachinePrecision] - y), $MachinePrecision]}, If[LessEqual[t, 1e+16], N[(t$95$1 * N[(N[Sqrt[N[(z * 2.0), $MachinePrecision]], $MachinePrecision] * N[Sqrt[1.0 ^ 2 + t ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t$95$1 * N[Sqrt[N[(N[Power[t, 2.0], $MachinePrecision] * N[(z * 2.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := x \cdot 0.5 - y\\
\mathbf{if}\;t \leq 10^{+16}:\\
\;\;\;\;t_1 \cdot \left(\sqrt{z \cdot 2} \cdot \mathsf{hypot}\left(1, t\right)\right)\\

\mathbf{else}:\\
\;\;\;\;t_1 \cdot \sqrt{{t}^{2} \cdot \left(z \cdot 2\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < 1e16

    1. Initial program 99.3%

      \[\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \]
    2. Step-by-step derivation
      1. sqr-neg99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{\color{blue}{\left(-t\right) \cdot \left(-t\right)}}{2}} \]
      2. associate-/l*99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}} \]
      3. distribute-frac-neg99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{-\frac{t}{\frac{2}{-t}}}} \]
      4. exp-neg99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot \color{blue}{\frac{1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      5. associate-*r/99.3%

        \[\leadsto \color{blue}{\frac{\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot 1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      6. *-rgt-identity99.3%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}}}{e^{\frac{t}{\frac{2}{-t}}}} \]
      7. associate-*r/99.8%

        \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \frac{\sqrt{z \cdot 2}}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      8. *-rgt-identity99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \frac{\color{blue}{\sqrt{z \cdot 2} \cdot 1}}{e^{\frac{t}{\frac{2}{-t}}}} \]
      9. associate-*r/99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(\sqrt{z \cdot 2} \cdot \frac{1}{e^{\frac{t}{\frac{2}{-t}}}}\right)} \]
      10. exp-neg99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{e^{-\frac{t}{\frac{2}{-t}}}}\right) \]
      11. distribute-frac-neg99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}}\right) \]
      12. associate-/l*99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{\left(-t\right) \cdot \left(-t\right)}{2}}}\right) \]
      13. sqr-neg99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\frac{\color{blue}{t \cdot t}}{2}}\right) \]
      14. exp-sqrt99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{\sqrt{e^{t \cdot t}}}\right) \]
    3. Simplified99.8%

      \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} \]
    4. Step-by-step derivation
      1. expm1-log1p-u98.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)\right)} \]
      2. expm1-udef67.4%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} - 1\right)} \]
      3. sqrt-unprod67.4%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\color{blue}{\sqrt{\left(z \cdot 2\right) \cdot e^{t \cdot t}}}\right)} - 1\right) \]
      4. associate-*l*67.4%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{\color{blue}{z \cdot \left(2 \cdot e^{t \cdot t}\right)}}\right)} - 1\right) \]
      5. pow267.4%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{\color{blue}{{t}^{2}}}\right)}\right)} - 1\right) \]
    5. Applied egg-rr67.4%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)} - 1\right)} \]
    6. Step-by-step derivation
      1. expm1-def98.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)\right)} \]
      2. expm1-log1p99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
    7. Simplified99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
    8. Taylor expanded in t around 0 89.2%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{\color{blue}{2 \cdot z + 2 \cdot \left({t}^{2} \cdot z\right)}} \]
    9. Step-by-step derivation
      1. distribute-lft-out89.2%

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

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{2 \cdot \left(z + \color{blue}{z \cdot {t}^{2}}\right)} \]
    10. Simplified89.2%

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

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

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{2 \cdot \left(\color{blue}{{t}^{2} \cdot z} + z\right)} \]
      3. *-un-lft-identity89.2%

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

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

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{2 \cdot \left(z \cdot \left(\color{blue}{t \cdot t} + 1\right)\right)} \]
      6. fma-udef89.2%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{2 \cdot \left(z \cdot \color{blue}{\mathsf{fma}\left(t, t, 1\right)}\right)} \]
      7. associate-*l*89.2%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{\color{blue}{\left(2 \cdot z\right) \cdot \mathsf{fma}\left(t, t, 1\right)}} \]
      8. *-commutative89.2%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{\color{blue}{\left(z \cdot 2\right)} \cdot \mathsf{fma}\left(t, t, 1\right)} \]
      9. sqrt-prod88.7%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(\sqrt{z \cdot 2} \cdot \sqrt{\mathsf{fma}\left(t, t, 1\right)}\right)} \]
      10. *-commutative88.7%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{\color{blue}{2 \cdot z}} \cdot \sqrt{\mathsf{fma}\left(t, t, 1\right)}\right) \]
    12. Applied egg-rr88.7%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(\sqrt{2 \cdot z} \cdot \sqrt{\mathsf{fma}\left(t, t, 1\right)}\right)} \]
    13. Step-by-step derivation
      1. *-commutative88.7%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{\color{blue}{z \cdot 2}} \cdot \sqrt{\mathsf{fma}\left(t, t, 1\right)}\right) \]
      2. fma-udef88.7%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \sqrt{\color{blue}{t \cdot t + 1}}\right) \]
      3. unpow288.7%

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

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \sqrt{\color{blue}{1 + {t}^{2}}}\right) \]
      5. unpow288.7%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \sqrt{1 + \color{blue}{t \cdot t}}\right) \]
      6. hypot-1-def83.6%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{\mathsf{hypot}\left(1, t\right)}\right) \]
    14. Simplified83.6%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(\sqrt{z \cdot 2} \cdot \mathsf{hypot}\left(1, t\right)\right)} \]

    if 1e16 < t

    1. Initial program 98.1%

      \[\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \]
    2. Step-by-step derivation
      1. sqr-neg98.1%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{\color{blue}{\left(-t\right) \cdot \left(-t\right)}}{2}} \]
      2. associate-/l*98.1%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}} \]
      3. distribute-frac-neg98.1%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{-\frac{t}{\frac{2}{-t}}}} \]
      4. exp-neg98.1%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot \color{blue}{\frac{1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      5. associate-*r/98.1%

        \[\leadsto \color{blue}{\frac{\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot 1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      6. *-rgt-identity98.1%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}}}{e^{\frac{t}{\frac{2}{-t}}}} \]
      7. associate-*r/100.0%

        \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \frac{\sqrt{z \cdot 2}}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      8. *-rgt-identity100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \frac{\color{blue}{\sqrt{z \cdot 2} \cdot 1}}{e^{\frac{t}{\frac{2}{-t}}}} \]
      9. associate-*r/100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(\sqrt{z \cdot 2} \cdot \frac{1}{e^{\frac{t}{\frac{2}{-t}}}}\right)} \]
      10. exp-neg100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{e^{-\frac{t}{\frac{2}{-t}}}}\right) \]
      11. distribute-frac-neg100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}}\right) \]
      12. associate-/l*100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{\left(-t\right) \cdot \left(-t\right)}{2}}}\right) \]
      13. sqr-neg100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\frac{\color{blue}{t \cdot t}}{2}}\right) \]
      14. exp-sqrt100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{\sqrt{e^{t \cdot t}}}\right) \]
    3. Simplified100.0%

      \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} \]
    4. Step-by-step derivation
      1. expm1-log1p-u100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)\right)} \]
      2. expm1-udef100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} - 1\right)} \]
      3. sqrt-unprod100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\color{blue}{\sqrt{\left(z \cdot 2\right) \cdot e^{t \cdot t}}}\right)} - 1\right) \]
      4. associate-*l*100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{\color{blue}{z \cdot \left(2 \cdot e^{t \cdot t}\right)}}\right)} - 1\right) \]
      5. pow2100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{\color{blue}{{t}^{2}}}\right)}\right)} - 1\right) \]
    5. Applied egg-rr100.0%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)} - 1\right)} \]
    6. Step-by-step derivation
      1. expm1-def100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)\right)} \]
      2. expm1-log1p100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
    7. Simplified100.0%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
    8. Taylor expanded in t around 0 81.7%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot \left(2 \cdot \color{blue}{\left(1 + {t}^{2}\right)}\right)} \]
    9. Step-by-step derivation
      1. +-commutative81.7%

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

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot \left(2 \cdot \left(\color{blue}{t \cdot t} + 1\right)\right)} \]
      3. fma-def81.7%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot \left(2 \cdot \color{blue}{\mathsf{fma}\left(t, t, 1\right)}\right)} \]
    10. Simplified81.7%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot \left(2 \cdot \color{blue}{\mathsf{fma}\left(t, t, 1\right)}\right)} \]
    11. Taylor expanded in t around inf 81.7%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{\color{blue}{2 \cdot \left({t}^{2} \cdot z\right)}} \]
    12. Step-by-step derivation
      1. *-commutative81.7%

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

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

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{\color{blue}{\left({t}^{2} \cdot z\right)} \cdot 2} \]
      4. associate-*l*81.7%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{\color{blue}{{t}^{2} \cdot \left(z \cdot 2\right)}} \]
    13. Simplified81.7%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{\color{blue}{{t}^{2} \cdot \left(z \cdot 2\right)}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification83.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq 10^{+16}:\\ \;\;\;\;\left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \mathsf{hypot}\left(1, t\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(x \cdot 0.5 - y\right) \cdot \sqrt{{t}^{2} \cdot \left(z \cdot 2\right)}\\ \end{array} \]

Alternative 5: 66.2% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x \cdot 0.5 - y\\ \mathbf{if}\;t \leq 1:\\ \;\;\;\;t_1 \cdot \sqrt{z \cdot 2}\\ \mathbf{else}:\\ \;\;\;\;\left(t \cdot \left(t_1 \cdot \sqrt{2}\right)\right) \cdot \sqrt{z}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (- (* x 0.5) y)))
   (if (<= t 1.0)
     (* t_1 (sqrt (* z 2.0)))
     (* (* t (* t_1 (sqrt 2.0))) (sqrt z)))))
double code(double x, double y, double z, double t) {
	double t_1 = (x * 0.5) - y;
	double tmp;
	if (t <= 1.0) {
		tmp = t_1 * sqrt((z * 2.0));
	} else {
		tmp = (t * (t_1 * sqrt(2.0))) * sqrt(z);
	}
	return tmp;
}
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) :: t_1
    real(8) :: tmp
    t_1 = (x * 0.5d0) - y
    if (t <= 1.0d0) then
        tmp = t_1 * sqrt((z * 2.0d0))
    else
        tmp = (t * (t_1 * sqrt(2.0d0))) * sqrt(z)
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double t_1 = (x * 0.5) - y;
	double tmp;
	if (t <= 1.0) {
		tmp = t_1 * Math.sqrt((z * 2.0));
	} else {
		tmp = (t * (t_1 * Math.sqrt(2.0))) * Math.sqrt(z);
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = (x * 0.5) - y
	tmp = 0
	if t <= 1.0:
		tmp = t_1 * math.sqrt((z * 2.0))
	else:
		tmp = (t * (t_1 * math.sqrt(2.0))) * math.sqrt(z)
	return tmp
function code(x, y, z, t)
	t_1 = Float64(Float64(x * 0.5) - y)
	tmp = 0.0
	if (t <= 1.0)
		tmp = Float64(t_1 * sqrt(Float64(z * 2.0)));
	else
		tmp = Float64(Float64(t * Float64(t_1 * sqrt(2.0))) * sqrt(z));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = (x * 0.5) - y;
	tmp = 0.0;
	if (t <= 1.0)
		tmp = t_1 * sqrt((z * 2.0));
	else
		tmp = (t * (t_1 * sqrt(2.0))) * sqrt(z);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x * 0.5), $MachinePrecision] - y), $MachinePrecision]}, If[LessEqual[t, 1.0], N[(t$95$1 * N[Sqrt[N[(z * 2.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[(t * N[(t$95$1 * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Sqrt[z], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := x \cdot 0.5 - y\\
\mathbf{if}\;t \leq 1:\\
\;\;\;\;t_1 \cdot \sqrt{z \cdot 2}\\

\mathbf{else}:\\
\;\;\;\;\left(t \cdot \left(t_1 \cdot \sqrt{2}\right)\right) \cdot \sqrt{z}\\


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

    1. Initial program 99.3%

      \[\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \]
    2. Step-by-step derivation
      1. sqr-neg99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{\color{blue}{\left(-t\right) \cdot \left(-t\right)}}{2}} \]
      2. associate-/l*99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}} \]
      3. distribute-frac-neg99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{-\frac{t}{\frac{2}{-t}}}} \]
      4. exp-neg99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot \color{blue}{\frac{1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      5. associate-*r/99.3%

        \[\leadsto \color{blue}{\frac{\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot 1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      6. *-rgt-identity99.3%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}}}{e^{\frac{t}{\frac{2}{-t}}}} \]
      7. associate-*r/99.8%

        \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \frac{\sqrt{z \cdot 2}}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      8. *-rgt-identity99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \frac{\color{blue}{\sqrt{z \cdot 2} \cdot 1}}{e^{\frac{t}{\frac{2}{-t}}}} \]
      9. associate-*r/99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(\sqrt{z \cdot 2} \cdot \frac{1}{e^{\frac{t}{\frac{2}{-t}}}}\right)} \]
      10. exp-neg99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{e^{-\frac{t}{\frac{2}{-t}}}}\right) \]
      11. distribute-frac-neg99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}}\right) \]
      12. associate-/l*99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{\left(-t\right) \cdot \left(-t\right)}{2}}}\right) \]
      13. sqr-neg99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\frac{\color{blue}{t \cdot t}}{2}}\right) \]
      14. exp-sqrt99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{\sqrt{e^{t \cdot t}}}\right) \]
    3. Simplified99.8%

      \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} \]
    4. Step-by-step derivation
      1. expm1-log1p-u98.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)\right)} \]
      2. expm1-udef66.9%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} - 1\right)} \]
      3. sqrt-unprod66.9%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\color{blue}{\sqrt{\left(z \cdot 2\right) \cdot e^{t \cdot t}}}\right)} - 1\right) \]
      4. associate-*l*66.9%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{\color{blue}{z \cdot \left(2 \cdot e^{t \cdot t}\right)}}\right)} - 1\right) \]
      5. pow266.9%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{\color{blue}{{t}^{2}}}\right)}\right)} - 1\right) \]
    5. Applied egg-rr66.9%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)} - 1\right)} \]
    6. Step-by-step derivation
      1. expm1-def98.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)\right)} \]
      2. expm1-log1p99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
    7. Simplified99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
    8. Taylor expanded in t around 0 71.0%

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

    if 1 < t

    1. Initial program 98.2%

      \[\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \]
    2. Step-by-step derivation
      1. sqr-neg98.2%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{\color{blue}{\left(-t\right) \cdot \left(-t\right)}}{2}} \]
      2. associate-/l*98.2%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}} \]
      3. distribute-frac-neg98.2%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{-\frac{t}{\frac{2}{-t}}}} \]
      4. exp-neg98.2%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot \color{blue}{\frac{1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      5. associate-*r/98.2%

        \[\leadsto \color{blue}{\frac{\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot 1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      6. *-rgt-identity98.2%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}}}{e^{\frac{t}{\frac{2}{-t}}}} \]
      7. associate-*r/100.0%

        \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \frac{\sqrt{z \cdot 2}}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      8. *-rgt-identity100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \frac{\color{blue}{\sqrt{z \cdot 2} \cdot 1}}{e^{\frac{t}{\frac{2}{-t}}}} \]
      9. associate-*r/100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(\sqrt{z \cdot 2} \cdot \frac{1}{e^{\frac{t}{\frac{2}{-t}}}}\right)} \]
      10. exp-neg100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{e^{-\frac{t}{\frac{2}{-t}}}}\right) \]
      11. distribute-frac-neg100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}}\right) \]
      12. associate-/l*100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{\left(-t\right) \cdot \left(-t\right)}{2}}}\right) \]
      13. sqr-neg100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\frac{\color{blue}{t \cdot t}}{2}}\right) \]
      14. exp-sqrt100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{\sqrt{e^{t \cdot t}}}\right) \]
    3. Simplified100.0%

      \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} \]
    4. Step-by-step derivation
      1. expm1-log1p-u100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)\right)} \]
      2. expm1-udef100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} - 1\right)} \]
      3. sqrt-unprod100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\color{blue}{\sqrt{\left(z \cdot 2\right) \cdot e^{t \cdot t}}}\right)} - 1\right) \]
      4. associate-*l*100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{\color{blue}{z \cdot \left(2 \cdot e^{t \cdot t}\right)}}\right)} - 1\right) \]
      5. pow2100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{\color{blue}{{t}^{2}}}\right)}\right)} - 1\right) \]
    5. Applied egg-rr100.0%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)} - 1\right)} \]
    6. Step-by-step derivation
      1. expm1-def100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)\right)} \]
      2. expm1-log1p100.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
    7. Simplified100.0%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
    8. Taylor expanded in t around 0 79.3%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{\color{blue}{2 \cdot z + 2 \cdot \left({t}^{2} \cdot z\right)}} \]
    9. Step-by-step derivation
      1. distribute-lft-out79.3%

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

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{2 \cdot \left(z + \color{blue}{z \cdot {t}^{2}}\right)} \]
    10. Simplified79.3%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{\color{blue}{2 \cdot \left(z + z \cdot {t}^{2}\right)}} \]
    11. Taylor expanded in t around inf 46.1%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq 1:\\ \;\;\;\;\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\\ \mathbf{else}:\\ \;\;\;\;\left(t \cdot \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{2}\right)\right) \cdot \sqrt{z}\\ \end{array} \]

Alternative 6: 84.4% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot \left(2 \cdot \mathsf{fma}\left(t, t, 1\right)\right)} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (* (- (* x 0.5) y) (sqrt (* z (* 2.0 (fma t t 1.0))))))
double code(double x, double y, double z, double t) {
	return ((x * 0.5) - y) * sqrt((z * (2.0 * fma(t, t, 1.0))));
}
function code(x, y, z, t)
	return Float64(Float64(Float64(x * 0.5) - y) * sqrt(Float64(z * Float64(2.0 * fma(t, t, 1.0)))))
end
code[x_, y_, z_, t_] := N[(N[(N[(x * 0.5), $MachinePrecision] - y), $MachinePrecision] * N[Sqrt[N[(z * N[(2.0 * N[(t * t + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot \left(2 \cdot \mathsf{fma}\left(t, t, 1\right)\right)}
\end{array}
Derivation
  1. Initial program 99.1%

    \[\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \]
  2. Step-by-step derivation
    1. sqr-neg99.1%

      \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{\color{blue}{\left(-t\right) \cdot \left(-t\right)}}{2}} \]
    2. associate-/l*99.1%

      \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}} \]
    3. distribute-frac-neg99.1%

      \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{-\frac{t}{\frac{2}{-t}}}} \]
    4. exp-neg99.1%

      \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot \color{blue}{\frac{1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
    5. associate-*r/99.1%

      \[\leadsto \color{blue}{\frac{\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot 1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
    6. *-rgt-identity99.1%

      \[\leadsto \frac{\color{blue}{\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}}}{e^{\frac{t}{\frac{2}{-t}}}} \]
    7. associate-*r/99.9%

      \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \frac{\sqrt{z \cdot 2}}{e^{\frac{t}{\frac{2}{-t}}}}} \]
    8. *-rgt-identity99.9%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \frac{\color{blue}{\sqrt{z \cdot 2} \cdot 1}}{e^{\frac{t}{\frac{2}{-t}}}} \]
    9. associate-*r/99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(\sqrt{z \cdot 2} \cdot \frac{1}{e^{\frac{t}{\frac{2}{-t}}}}\right)} \]
    10. exp-neg99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{e^{-\frac{t}{\frac{2}{-t}}}}\right) \]
    11. distribute-frac-neg99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}}\right) \]
    12. associate-/l*99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{\left(-t\right) \cdot \left(-t\right)}{2}}}\right) \]
    13. sqr-neg99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\frac{\color{blue}{t \cdot t}}{2}}\right) \]
    14. exp-sqrt99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{\sqrt{e^{t \cdot t}}}\right) \]
  3. Simplified99.8%

    \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} \]
  4. Step-by-step derivation
    1. expm1-log1p-u98.4%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)\right)} \]
    2. expm1-udef74.0%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} - 1\right)} \]
    3. sqrt-unprod74.0%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\color{blue}{\sqrt{\left(z \cdot 2\right) \cdot e^{t \cdot t}}}\right)} - 1\right) \]
    4. associate-*l*74.0%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{\color{blue}{z \cdot \left(2 \cdot e^{t \cdot t}\right)}}\right)} - 1\right) \]
    5. pow274.0%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{\color{blue}{{t}^{2}}}\right)}\right)} - 1\right) \]
  5. Applied egg-rr74.0%

    \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)} - 1\right)} \]
  6. Step-by-step derivation
    1. expm1-def98.4%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)\right)} \]
    2. expm1-log1p99.9%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
  7. Simplified99.9%

    \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
  8. Taylor expanded in t around 0 87.7%

    \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot \left(2 \cdot \color{blue}{\left(1 + {t}^{2}\right)}\right)} \]
  9. Step-by-step derivation
    1. +-commutative87.7%

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

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot \left(2 \cdot \left(\color{blue}{t \cdot t} + 1\right)\right)} \]
    3. fma-def87.7%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot \left(2 \cdot \color{blue}{\mathsf{fma}\left(t, t, 1\right)}\right)} \]
  10. Simplified87.7%

    \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot \left(2 \cdot \color{blue}{\mathsf{fma}\left(t, t, 1\right)}\right)} \]
  11. Final simplification87.7%

    \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot \left(2 \cdot \mathsf{fma}\left(t, t, 1\right)\right)} \]

Alternative 7: 59.8% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x \cdot 0.5 - y\\ \mathbf{if}\;t \leq 6.8 \cdot 10^{+20}:\\ \;\;\;\;t_1 \cdot \sqrt{z \cdot 2}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\left(z \cdot 2\right) \cdot {t_1}^{2}}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (- (* x 0.5) y)))
   (if (<= t 6.8e+20)
     (* t_1 (sqrt (* z 2.0)))
     (sqrt (* (* z 2.0) (pow t_1 2.0))))))
double code(double x, double y, double z, double t) {
	double t_1 = (x * 0.5) - y;
	double tmp;
	if (t <= 6.8e+20) {
		tmp = t_1 * sqrt((z * 2.0));
	} else {
		tmp = sqrt(((z * 2.0) * pow(t_1, 2.0)));
	}
	return tmp;
}
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) :: t_1
    real(8) :: tmp
    t_1 = (x * 0.5d0) - y
    if (t <= 6.8d+20) then
        tmp = t_1 * sqrt((z * 2.0d0))
    else
        tmp = sqrt(((z * 2.0d0) * (t_1 ** 2.0d0)))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double t_1 = (x * 0.5) - y;
	double tmp;
	if (t <= 6.8e+20) {
		tmp = t_1 * Math.sqrt((z * 2.0));
	} else {
		tmp = Math.sqrt(((z * 2.0) * Math.pow(t_1, 2.0)));
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = (x * 0.5) - y
	tmp = 0
	if t <= 6.8e+20:
		tmp = t_1 * math.sqrt((z * 2.0))
	else:
		tmp = math.sqrt(((z * 2.0) * math.pow(t_1, 2.0)))
	return tmp
function code(x, y, z, t)
	t_1 = Float64(Float64(x * 0.5) - y)
	tmp = 0.0
	if (t <= 6.8e+20)
		tmp = Float64(t_1 * sqrt(Float64(z * 2.0)));
	else
		tmp = sqrt(Float64(Float64(z * 2.0) * (t_1 ^ 2.0)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = (x * 0.5) - y;
	tmp = 0.0;
	if (t <= 6.8e+20)
		tmp = t_1 * sqrt((z * 2.0));
	else
		tmp = sqrt(((z * 2.0) * (t_1 ^ 2.0)));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x * 0.5), $MachinePrecision] - y), $MachinePrecision]}, If[LessEqual[t, 6.8e+20], N[(t$95$1 * N[Sqrt[N[(z * 2.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[Sqrt[N[(N[(z * 2.0), $MachinePrecision] * N[Power[t$95$1, 2.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := x \cdot 0.5 - y\\
\mathbf{if}\;t \leq 6.8 \cdot 10^{+20}:\\
\;\;\;\;t_1 \cdot \sqrt{z \cdot 2}\\

\mathbf{else}:\\
\;\;\;\;\sqrt{\left(z \cdot 2\right) \cdot {t_1}^{2}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < 6.8e20

    1. Initial program 99.3%

      \[\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \]
    2. Step-by-step derivation
      1. sqr-neg99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{\color{blue}{\left(-t\right) \cdot \left(-t\right)}}{2}} \]
      2. associate-/l*99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}} \]
      3. distribute-frac-neg99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{-\frac{t}{\frac{2}{-t}}}} \]
      4. exp-neg99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot \color{blue}{\frac{1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      5. associate-*r/99.3%

        \[\leadsto \color{blue}{\frac{\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot 1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      6. *-rgt-identity99.3%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}}}{e^{\frac{t}{\frac{2}{-t}}}} \]
      7. associate-*r/99.8%

        \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \frac{\sqrt{z \cdot 2}}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      8. *-rgt-identity99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \frac{\color{blue}{\sqrt{z \cdot 2} \cdot 1}}{e^{\frac{t}{\frac{2}{-t}}}} \]
      9. associate-*r/99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(\sqrt{z \cdot 2} \cdot \frac{1}{e^{\frac{t}{\frac{2}{-t}}}}\right)} \]
      10. exp-neg99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{e^{-\frac{t}{\frac{2}{-t}}}}\right) \]
      11. distribute-frac-neg99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}}\right) \]
      12. associate-/l*99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{\left(-t\right) \cdot \left(-t\right)}{2}}}\right) \]
      13. sqr-neg99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\frac{\color{blue}{t \cdot t}}{2}}\right) \]
      14. exp-sqrt99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{\sqrt{e^{t \cdot t}}}\right) \]
    3. Simplified99.8%

      \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} \]
    4. Step-by-step derivation
      1. expm1-log1p-u98.0%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)\right)} \]
      2. expm1-udef67.6%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} - 1\right)} \]
      3. sqrt-unprod67.6%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\color{blue}{\sqrt{\left(z \cdot 2\right) \cdot e^{t \cdot t}}}\right)} - 1\right) \]
      4. associate-*l*67.6%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{\color{blue}{z \cdot \left(2 \cdot e^{t \cdot t}\right)}}\right)} - 1\right) \]
      5. pow267.6%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{\color{blue}{{t}^{2}}}\right)}\right)} - 1\right) \]
    5. Applied egg-rr67.6%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)} - 1\right)} \]
    6. Step-by-step derivation
      1. expm1-def98.1%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)\right)} \]
      2. expm1-log1p99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
    7. Simplified99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
    8. Taylor expanded in t around 0 70.2%

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

    if 6.8e20 < t

    1. Initial program 98.0%

      \[\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \]
    2. Taylor expanded in t around 0 11.1%

      \[\leadsto \color{blue}{\sqrt{z} \cdot \left(\sqrt{2} \cdot \left(0.5 \cdot x - y\right)\right)} \]
    3. Step-by-step derivation
      1. *-commutative11.1%

        \[\leadsto \sqrt{z} \cdot \color{blue}{\left(\left(0.5 \cdot x - y\right) \cdot \sqrt{2}\right)} \]
      2. associate-*r*11.1%

        \[\leadsto \color{blue}{\left(\sqrt{z} \cdot \left(0.5 \cdot x - y\right)\right) \cdot \sqrt{2}} \]
      3. add-sqr-sqrt3.8%

        \[\leadsto \left(\sqrt{z} \cdot \color{blue}{\left(\sqrt{0.5 \cdot x - y} \cdot \sqrt{0.5 \cdot x - y}\right)}\right) \cdot \sqrt{2} \]
      4. sqrt-prod13.2%

        \[\leadsto \left(\sqrt{z} \cdot \color{blue}{\sqrt{\left(0.5 \cdot x - y\right) \cdot \left(0.5 \cdot x - y\right)}}\right) \cdot \sqrt{2} \]
      5. unpow213.2%

        \[\leadsto \left(\sqrt{z} \cdot \sqrt{\color{blue}{{\left(0.5 \cdot x - y\right)}^{2}}}\right) \cdot \sqrt{2} \]
      6. sqrt-prod15.1%

        \[\leadsto \color{blue}{\sqrt{z \cdot {\left(0.5 \cdot x - y\right)}^{2}}} \cdot \sqrt{2} \]
      7. sqrt-prod15.1%

        \[\leadsto \color{blue}{\sqrt{\left(z \cdot {\left(0.5 \cdot x - y\right)}^{2}\right) \cdot 2}} \]
      8. *-commutative15.1%

        \[\leadsto \sqrt{\color{blue}{\left({\left(0.5 \cdot x - y\right)}^{2} \cdot z\right)} \cdot 2} \]
      9. associate-*l*15.1%

        \[\leadsto \sqrt{\color{blue}{{\left(0.5 \cdot x - y\right)}^{2} \cdot \left(z \cdot 2\right)}} \]
      10. *-commutative15.1%

        \[\leadsto \sqrt{{\left(\color{blue}{x \cdot 0.5} - y\right)}^{2} \cdot \left(z \cdot 2\right)} \]
    4. Applied egg-rr15.1%

      \[\leadsto \color{blue}{\sqrt{{\left(x \cdot 0.5 - y\right)}^{2} \cdot \left(z \cdot 2\right)}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification59.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq 6.8 \cdot 10^{+20}:\\ \;\;\;\;\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\left(z \cdot 2\right) \cdot {\left(x \cdot 0.5 - y\right)}^{2}}\\ \end{array} \]

Alternative 8: 43.3% accurate, 1.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \sqrt{z \cdot 2}\\ \mathbf{if}\;y \leq -7.2 \cdot 10^{+37} \lor \neg \left(y \leq 1.4 \cdot 10^{-59}\right):\\ \;\;\;\;t_1 \cdot \left(-y\right)\\ \mathbf{else}:\\ \;\;\;\;0.5 \cdot \left(x \cdot t_1\right)\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (sqrt (* z 2.0))))
   (if (or (<= y -7.2e+37) (not (<= y 1.4e-59)))
     (* t_1 (- y))
     (* 0.5 (* x t_1)))))
double code(double x, double y, double z, double t) {
	double t_1 = sqrt((z * 2.0));
	double tmp;
	if ((y <= -7.2e+37) || !(y <= 1.4e-59)) {
		tmp = t_1 * -y;
	} else {
		tmp = 0.5 * (x * t_1);
	}
	return tmp;
}
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) :: t_1
    real(8) :: tmp
    t_1 = sqrt((z * 2.0d0))
    if ((y <= (-7.2d+37)) .or. (.not. (y <= 1.4d-59))) then
        tmp = t_1 * -y
    else
        tmp = 0.5d0 * (x * t_1)
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double t_1 = Math.sqrt((z * 2.0));
	double tmp;
	if ((y <= -7.2e+37) || !(y <= 1.4e-59)) {
		tmp = t_1 * -y;
	} else {
		tmp = 0.5 * (x * t_1);
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = math.sqrt((z * 2.0))
	tmp = 0
	if (y <= -7.2e+37) or not (y <= 1.4e-59):
		tmp = t_1 * -y
	else:
		tmp = 0.5 * (x * t_1)
	return tmp
function code(x, y, z, t)
	t_1 = sqrt(Float64(z * 2.0))
	tmp = 0.0
	if ((y <= -7.2e+37) || !(y <= 1.4e-59))
		tmp = Float64(t_1 * Float64(-y));
	else
		tmp = Float64(0.5 * Float64(x * t_1));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = sqrt((z * 2.0));
	tmp = 0.0;
	if ((y <= -7.2e+37) || ~((y <= 1.4e-59)))
		tmp = t_1 * -y;
	else
		tmp = 0.5 * (x * t_1);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[Sqrt[N[(z * 2.0), $MachinePrecision]], $MachinePrecision]}, If[Or[LessEqual[y, -7.2e+37], N[Not[LessEqual[y, 1.4e-59]], $MachinePrecision]], N[(t$95$1 * (-y)), $MachinePrecision], N[(0.5 * N[(x * t$95$1), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \sqrt{z \cdot 2}\\
\mathbf{if}\;y \leq -7.2 \cdot 10^{+37} \lor \neg \left(y \leq 1.4 \cdot 10^{-59}\right):\\
\;\;\;\;t_1 \cdot \left(-y\right)\\

\mathbf{else}:\\
\;\;\;\;0.5 \cdot \left(x \cdot t_1\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -7.19999999999999995e37 or 1.3999999999999999e-59 < y

    1. Initial program 99.8%

      \[\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \]
    2. Taylor expanded in t around 0 63.2%

      \[\leadsto \color{blue}{\sqrt{z} \cdot \left(\sqrt{2} \cdot \left(0.5 \cdot x - y\right)\right)} \]
    3. Taylor expanded in x around 0 51.0%

      \[\leadsto \color{blue}{-1 \cdot \left(\left(y \cdot \sqrt{2}\right) \cdot \sqrt{z}\right)} \]
    4. Step-by-step derivation
      1. mul-1-neg51.0%

        \[\leadsto \color{blue}{-\left(y \cdot \sqrt{2}\right) \cdot \sqrt{z}} \]
      2. associate-*l*51.0%

        \[\leadsto -\color{blue}{y \cdot \left(\sqrt{2} \cdot \sqrt{z}\right)} \]
      3. *-commutative51.0%

        \[\leadsto -y \cdot \color{blue}{\left(\sqrt{z} \cdot \sqrt{2}\right)} \]
      4. *-commutative51.0%

        \[\leadsto -\color{blue}{\left(\sqrt{z} \cdot \sqrt{2}\right) \cdot y} \]
      5. distribute-rgt-neg-in51.0%

        \[\leadsto \color{blue}{\left(\sqrt{z} \cdot \sqrt{2}\right) \cdot \left(-y\right)} \]
      6. *-commutative51.0%

        \[\leadsto \color{blue}{\left(\sqrt{2} \cdot \sqrt{z}\right)} \cdot \left(-y\right) \]
    5. Simplified51.0%

      \[\leadsto \color{blue}{\left(\sqrt{2} \cdot \sqrt{z}\right) \cdot \left(-y\right)} \]
    6. Step-by-step derivation
      1. sqrt-prod51.1%

        \[\leadsto \color{blue}{\sqrt{2 \cdot z}} \cdot \left(-y\right) \]
      2. *-commutative51.1%

        \[\leadsto \sqrt{\color{blue}{z \cdot 2}} \cdot \left(-y\right) \]
    7. Applied egg-rr51.1%

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

    if -7.19999999999999995e37 < y < 1.3999999999999999e-59

    1. Initial program 98.3%

      \[\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \]
    2. Taylor expanded in t around 0 53.2%

      \[\leadsto \color{blue}{\sqrt{z} \cdot \left(\sqrt{2} \cdot \left(0.5 \cdot x - y\right)\right)} \]
    3. Taylor expanded in x around inf 43.3%

      \[\leadsto \color{blue}{0.5 \cdot \left(\left(x \cdot \sqrt{2}\right) \cdot \sqrt{z}\right)} \]
    4. Step-by-step derivation
      1. associate-*l*43.3%

        \[\leadsto 0.5 \cdot \color{blue}{\left(x \cdot \left(\sqrt{2} \cdot \sqrt{z}\right)\right)} \]
    5. Simplified43.3%

      \[\leadsto \color{blue}{0.5 \cdot \left(x \cdot \left(\sqrt{2} \cdot \sqrt{z}\right)\right)} \]
    6. Step-by-step derivation
      1. sqrt-prod11.7%

        \[\leadsto \color{blue}{\sqrt{2 \cdot z}} \cdot \left(-y\right) \]
      2. *-commutative11.7%

        \[\leadsto \sqrt{\color{blue}{z \cdot 2}} \cdot \left(-y\right) \]
    7. Applied egg-rr43.4%

      \[\leadsto 0.5 \cdot \left(x \cdot \color{blue}{\sqrt{z \cdot 2}}\right) \]
  3. Recombined 2 regimes into one program.
  4. Final simplification47.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -7.2 \cdot 10^{+37} \lor \neg \left(y \leq 1.4 \cdot 10^{-59}\right):\\ \;\;\;\;\sqrt{z \cdot 2} \cdot \left(-y\right)\\ \mathbf{else}:\\ \;\;\;\;0.5 \cdot \left(x \cdot \sqrt{z \cdot 2}\right)\\ \end{array} \]

Alternative 9: 57.4% accurate, 1.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq 9.2 \cdot 10^{+86}:\\ \;\;\;\;\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\left(z \cdot 2\right) \cdot \left(y \cdot \left(y - x\right)\right)}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (<= t 9.2e+86)
   (* (- (* x 0.5) y) (sqrt (* z 2.0)))
   (sqrt (* (* z 2.0) (* y (- y x))))))
double code(double x, double y, double z, double t) {
	double tmp;
	if (t <= 9.2e+86) {
		tmp = ((x * 0.5) - y) * sqrt((z * 2.0));
	} else {
		tmp = sqrt(((z * 2.0) * (y * (y - x))));
	}
	return tmp;
}
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 (t <= 9.2d+86) then
        tmp = ((x * 0.5d0) - y) * sqrt((z * 2.0d0))
    else
        tmp = sqrt(((z * 2.0d0) * (y * (y - x))))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (t <= 9.2e+86) {
		tmp = ((x * 0.5) - y) * Math.sqrt((z * 2.0));
	} else {
		tmp = Math.sqrt(((z * 2.0) * (y * (y - x))));
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if t <= 9.2e+86:
		tmp = ((x * 0.5) - y) * math.sqrt((z * 2.0))
	else:
		tmp = math.sqrt(((z * 2.0) * (y * (y - x))))
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if (t <= 9.2e+86)
		tmp = Float64(Float64(Float64(x * 0.5) - y) * sqrt(Float64(z * 2.0)));
	else
		tmp = sqrt(Float64(Float64(z * 2.0) * Float64(y * Float64(y - x))));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (t <= 9.2e+86)
		tmp = ((x * 0.5) - y) * sqrt((z * 2.0));
	else
		tmp = sqrt(((z * 2.0) * (y * (y - x))));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[LessEqual[t, 9.2e+86], N[(N[(N[(x * 0.5), $MachinePrecision] - y), $MachinePrecision] * N[Sqrt[N[(z * 2.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[Sqrt[N[(N[(z * 2.0), $MachinePrecision] * N[(y * N[(y - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq 9.2 \cdot 10^{+86}:\\
\;\;\;\;\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\\

\mathbf{else}:\\
\;\;\;\;\sqrt{\left(z \cdot 2\right) \cdot \left(y \cdot \left(y - x\right)\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < 9.19999999999999958e86

    1. Initial program 99.3%

      \[\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \]
    2. Step-by-step derivation
      1. sqr-neg99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{\color{blue}{\left(-t\right) \cdot \left(-t\right)}}{2}} \]
      2. associate-/l*99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}} \]
      3. distribute-frac-neg99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{-\frac{t}{\frac{2}{-t}}}} \]
      4. exp-neg99.3%

        \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot \color{blue}{\frac{1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      5. associate-*r/99.3%

        \[\leadsto \color{blue}{\frac{\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot 1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      6. *-rgt-identity99.3%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}}}{e^{\frac{t}{\frac{2}{-t}}}} \]
      7. associate-*r/99.8%

        \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \frac{\sqrt{z \cdot 2}}{e^{\frac{t}{\frac{2}{-t}}}}} \]
      8. *-rgt-identity99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \frac{\color{blue}{\sqrt{z \cdot 2} \cdot 1}}{e^{\frac{t}{\frac{2}{-t}}}} \]
      9. associate-*r/99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(\sqrt{z \cdot 2} \cdot \frac{1}{e^{\frac{t}{\frac{2}{-t}}}}\right)} \]
      10. exp-neg99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{e^{-\frac{t}{\frac{2}{-t}}}}\right) \]
      11. distribute-frac-neg99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}}\right) \]
      12. associate-/l*99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{\left(-t\right) \cdot \left(-t\right)}{2}}}\right) \]
      13. sqr-neg99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\frac{\color{blue}{t \cdot t}}{2}}\right) \]
      14. exp-sqrt99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{\sqrt{e^{t \cdot t}}}\right) \]
    3. Simplified99.8%

      \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} \]
    4. Step-by-step derivation
      1. expm1-log1p-u98.1%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)\right)} \]
      2. expm1-udef68.6%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} - 1\right)} \]
      3. sqrt-unprod68.6%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\color{blue}{\sqrt{\left(z \cdot 2\right) \cdot e^{t \cdot t}}}\right)} - 1\right) \]
      4. associate-*l*68.6%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{\color{blue}{z \cdot \left(2 \cdot e^{t \cdot t}\right)}}\right)} - 1\right) \]
      5. pow268.6%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{\color{blue}{{t}^{2}}}\right)}\right)} - 1\right) \]
    5. Applied egg-rr68.6%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)} - 1\right)} \]
    6. Step-by-step derivation
      1. expm1-def98.1%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)\right)} \]
      2. expm1-log1p99.8%

        \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
    7. Simplified99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
    8. Taylor expanded in t around 0 68.5%

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

    if 9.19999999999999958e86 < t

    1. Initial program 97.7%

      \[\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \]
    2. Taylor expanded in t around 0 10.0%

      \[\leadsto \color{blue}{\sqrt{z} \cdot \left(\sqrt{2} \cdot \left(0.5 \cdot x - y\right)\right)} \]
    3. Step-by-step derivation
      1. *-commutative10.0%

        \[\leadsto \sqrt{z} \cdot \color{blue}{\left(\left(0.5 \cdot x - y\right) \cdot \sqrt{2}\right)} \]
      2. associate-*r*10.0%

        \[\leadsto \color{blue}{\left(\sqrt{z} \cdot \left(0.5 \cdot x - y\right)\right) \cdot \sqrt{2}} \]
      3. add-sqr-sqrt4.1%

        \[\leadsto \left(\sqrt{z} \cdot \color{blue}{\left(\sqrt{0.5 \cdot x - y} \cdot \sqrt{0.5 \cdot x - y}\right)}\right) \cdot \sqrt{2} \]
      4. sqrt-prod12.9%

        \[\leadsto \left(\sqrt{z} \cdot \color{blue}{\sqrt{\left(0.5 \cdot x - y\right) \cdot \left(0.5 \cdot x - y\right)}}\right) \cdot \sqrt{2} \]
      5. unpow212.9%

        \[\leadsto \left(\sqrt{z} \cdot \sqrt{\color{blue}{{\left(0.5 \cdot x - y\right)}^{2}}}\right) \cdot \sqrt{2} \]
      6. sqrt-prod15.1%

        \[\leadsto \color{blue}{\sqrt{z \cdot {\left(0.5 \cdot x - y\right)}^{2}}} \cdot \sqrt{2} \]
      7. sqrt-prod15.1%

        \[\leadsto \color{blue}{\sqrt{\left(z \cdot {\left(0.5 \cdot x - y\right)}^{2}\right) \cdot 2}} \]
      8. *-commutative15.1%

        \[\leadsto \sqrt{\color{blue}{\left({\left(0.5 \cdot x - y\right)}^{2} \cdot z\right)} \cdot 2} \]
      9. associate-*l*15.1%

        \[\leadsto \sqrt{\color{blue}{{\left(0.5 \cdot x - y\right)}^{2} \cdot \left(z \cdot 2\right)}} \]
      10. *-commutative15.1%

        \[\leadsto \sqrt{{\left(\color{blue}{x \cdot 0.5} - y\right)}^{2} \cdot \left(z \cdot 2\right)} \]
    4. Applied egg-rr15.1%

      \[\leadsto \color{blue}{\sqrt{{\left(x \cdot 0.5 - y\right)}^{2} \cdot \left(z \cdot 2\right)}} \]
    5. Taylor expanded in x around 0 12.5%

      \[\leadsto \sqrt{\color{blue}{\left(-1 \cdot \left(x \cdot y\right) + {y}^{2}\right)} \cdot \left(z \cdot 2\right)} \]
    6. Step-by-step derivation
      1. +-commutative12.5%

        \[\leadsto \sqrt{\color{blue}{\left({y}^{2} + -1 \cdot \left(x \cdot y\right)\right)} \cdot \left(z \cdot 2\right)} \]
      2. unpow212.5%

        \[\leadsto \sqrt{\left(\color{blue}{y \cdot y} + -1 \cdot \left(x \cdot y\right)\right) \cdot \left(z \cdot 2\right)} \]
      3. associate-*r*12.5%

        \[\leadsto \sqrt{\left(y \cdot y + \color{blue}{\left(-1 \cdot x\right) \cdot y}\right) \cdot \left(z \cdot 2\right)} \]
      4. distribute-rgt-out12.5%

        \[\leadsto \sqrt{\color{blue}{\left(y \cdot \left(y + -1 \cdot x\right)\right)} \cdot \left(z \cdot 2\right)} \]
      5. mul-1-neg12.5%

        \[\leadsto \sqrt{\left(y \cdot \left(y + \color{blue}{\left(-x\right)}\right)\right) \cdot \left(z \cdot 2\right)} \]
    7. Simplified12.5%

      \[\leadsto \sqrt{\color{blue}{\left(y \cdot \left(y + \left(-x\right)\right)\right)} \cdot \left(z \cdot 2\right)} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification58.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq 9.2 \cdot 10^{+86}:\\ \;\;\;\;\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\left(z \cdot 2\right) \cdot \left(y \cdot \left(y - x\right)\right)}\\ \end{array} \]

Alternative 10: 57.1% accurate, 2.0× speedup?

\[\begin{array}{l} \\ \left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2} \end{array} \]
(FPCore (x y z t) :precision binary64 (* (- (* x 0.5) y) (sqrt (* z 2.0))))
double code(double x, double y, double z, double t) {
	return ((x * 0.5) - y) * sqrt((z * 2.0));
}
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 * 0.5d0) - y) * sqrt((z * 2.0d0))
end function
public static double code(double x, double y, double z, double t) {
	return ((x * 0.5) - y) * Math.sqrt((z * 2.0));
}
def code(x, y, z, t):
	return ((x * 0.5) - y) * math.sqrt((z * 2.0))
function code(x, y, z, t)
	return Float64(Float64(Float64(x * 0.5) - y) * sqrt(Float64(z * 2.0)))
end
function tmp = code(x, y, z, t)
	tmp = ((x * 0.5) - y) * sqrt((z * 2.0));
end
code[x_, y_, z_, t_] := N[(N[(N[(x * 0.5), $MachinePrecision] - y), $MachinePrecision] * N[Sqrt[N[(z * 2.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}
\end{array}
Derivation
  1. Initial program 99.1%

    \[\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \]
  2. Step-by-step derivation
    1. sqr-neg99.1%

      \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{\color{blue}{\left(-t\right) \cdot \left(-t\right)}}{2}} \]
    2. associate-/l*99.1%

      \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}} \]
    3. distribute-frac-neg99.1%

      \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\color{blue}{-\frac{t}{\frac{2}{-t}}}} \]
    4. exp-neg99.1%

      \[\leadsto \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot \color{blue}{\frac{1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
    5. associate-*r/99.1%

      \[\leadsto \color{blue}{\frac{\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot 1}{e^{\frac{t}{\frac{2}{-t}}}}} \]
    6. *-rgt-identity99.1%

      \[\leadsto \frac{\color{blue}{\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}}}{e^{\frac{t}{\frac{2}{-t}}}} \]
    7. associate-*r/99.9%

      \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \frac{\sqrt{z \cdot 2}}{e^{\frac{t}{\frac{2}{-t}}}}} \]
    8. *-rgt-identity99.9%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \frac{\color{blue}{\sqrt{z \cdot 2} \cdot 1}}{e^{\frac{t}{\frac{2}{-t}}}} \]
    9. associate-*r/99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(\sqrt{z \cdot 2} \cdot \frac{1}{e^{\frac{t}{\frac{2}{-t}}}}\right)} \]
    10. exp-neg99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{e^{-\frac{t}{\frac{2}{-t}}}}\right) \]
    11. distribute-frac-neg99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{-t}{\frac{2}{-t}}}}\right) \]
    12. associate-/l*99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\color{blue}{\frac{\left(-t\right) \cdot \left(-t\right)}{2}}}\right) \]
    13. sqr-neg99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot e^{\frac{\color{blue}{t \cdot t}}{2}}\right) \]
    14. exp-sqrt99.8%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \color{blue}{\sqrt{e^{t \cdot t}}}\right) \]
  3. Simplified99.8%

    \[\leadsto \color{blue}{\left(x \cdot 0.5 - y\right) \cdot \left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} \]
  4. Step-by-step derivation
    1. expm1-log1p-u98.4%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)\right)} \]
    2. expm1-udef74.0%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot 2} \cdot \sqrt{e^{t \cdot t}}\right)} - 1\right)} \]
    3. sqrt-unprod74.0%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\color{blue}{\sqrt{\left(z \cdot 2\right) \cdot e^{t \cdot t}}}\right)} - 1\right) \]
    4. associate-*l*74.0%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{\color{blue}{z \cdot \left(2 \cdot e^{t \cdot t}\right)}}\right)} - 1\right) \]
    5. pow274.0%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{\color{blue}{{t}^{2}}}\right)}\right)} - 1\right) \]
  5. Applied egg-rr74.0%

    \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\left(e^{\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)} - 1\right)} \]
  6. Step-by-step derivation
    1. expm1-def98.4%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}\right)\right)} \]
    2. expm1-log1p99.9%

      \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
  7. Simplified99.9%

    \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \color{blue}{\sqrt{z \cdot \left(2 \cdot e^{{t}^{2}}\right)}} \]
  8. Taylor expanded in t around 0 58.4%

    \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{\color{blue}{2 \cdot z}} \]
  9. Final simplification58.4%

    \[\leadsto \left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2} \]

Alternative 11: 29.7% accurate, 2.0× speedup?

\[\begin{array}{l} \\ \sqrt{z \cdot 2} \cdot \left(-y\right) \end{array} \]
(FPCore (x y z t) :precision binary64 (* (sqrt (* z 2.0)) (- y)))
double code(double x, double y, double z, double t) {
	return sqrt((z * 2.0)) * -y;
}
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 = sqrt((z * 2.0d0)) * -y
end function
public static double code(double x, double y, double z, double t) {
	return Math.sqrt((z * 2.0)) * -y;
}
def code(x, y, z, t):
	return math.sqrt((z * 2.0)) * -y
function code(x, y, z, t)
	return Float64(sqrt(Float64(z * 2.0)) * Float64(-y))
end
function tmp = code(x, y, z, t)
	tmp = sqrt((z * 2.0)) * -y;
end
code[x_, y_, z_, t_] := N[(N[Sqrt[N[(z * 2.0), $MachinePrecision]], $MachinePrecision] * (-y)), $MachinePrecision]
\begin{array}{l}

\\
\sqrt{z \cdot 2} \cdot \left(-y\right)
\end{array}
Derivation
  1. Initial program 99.1%

    \[\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \]
  2. Taylor expanded in t around 0 58.2%

    \[\leadsto \color{blue}{\sqrt{z} \cdot \left(\sqrt{2} \cdot \left(0.5 \cdot x - y\right)\right)} \]
  3. Taylor expanded in x around 0 31.3%

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

      \[\leadsto \color{blue}{-\left(y \cdot \sqrt{2}\right) \cdot \sqrt{z}} \]
    2. associate-*l*31.3%

      \[\leadsto -\color{blue}{y \cdot \left(\sqrt{2} \cdot \sqrt{z}\right)} \]
    3. *-commutative31.3%

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

      \[\leadsto -\color{blue}{\left(\sqrt{z} \cdot \sqrt{2}\right) \cdot y} \]
    5. distribute-rgt-neg-in31.3%

      \[\leadsto \color{blue}{\left(\sqrt{z} \cdot \sqrt{2}\right) \cdot \left(-y\right)} \]
    6. *-commutative31.3%

      \[\leadsto \color{blue}{\left(\sqrt{2} \cdot \sqrt{z}\right)} \cdot \left(-y\right) \]
  5. Simplified31.3%

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

      \[\leadsto \color{blue}{\sqrt{2 \cdot z}} \cdot \left(-y\right) \]
    2. *-commutative31.4%

      \[\leadsto \sqrt{\color{blue}{z \cdot 2}} \cdot \left(-y\right) \]
  7. Applied egg-rr31.4%

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

    \[\leadsto \sqrt{z \cdot 2} \cdot \left(-y\right) \]

Alternative 12: 2.5% accurate, 2.0× speedup?

\[\begin{array}{l} \\ y \cdot \sqrt{z \cdot 2} \end{array} \]
(FPCore (x y z t) :precision binary64 (* y (sqrt (* z 2.0))))
double code(double x, double y, double z, double t) {
	return y * sqrt((z * 2.0));
}
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 = y * sqrt((z * 2.0d0))
end function
public static double code(double x, double y, double z, double t) {
	return y * Math.sqrt((z * 2.0));
}
def code(x, y, z, t):
	return y * math.sqrt((z * 2.0))
function code(x, y, z, t)
	return Float64(y * sqrt(Float64(z * 2.0)))
end
function tmp = code(x, y, z, t)
	tmp = y * sqrt((z * 2.0));
end
code[x_, y_, z_, t_] := N[(y * N[Sqrt[N[(z * 2.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
y \cdot \sqrt{z \cdot 2}
\end{array}
Derivation
  1. Initial program 99.1%

    \[\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot e^{\frac{t \cdot t}{2}} \]
  2. Taylor expanded in t around 0 58.2%

    \[\leadsto \color{blue}{\sqrt{z} \cdot \left(\sqrt{2} \cdot \left(0.5 \cdot x - y\right)\right)} \]
  3. Taylor expanded in x around 0 31.3%

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

      \[\leadsto \color{blue}{-\left(y \cdot \sqrt{2}\right) \cdot \sqrt{z}} \]
    2. associate-*l*31.3%

      \[\leadsto -\color{blue}{y \cdot \left(\sqrt{2} \cdot \sqrt{z}\right)} \]
    3. *-commutative31.3%

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

      \[\leadsto -\color{blue}{\left(\sqrt{z} \cdot \sqrt{2}\right) \cdot y} \]
    5. distribute-rgt-neg-in31.3%

      \[\leadsto \color{blue}{\left(\sqrt{z} \cdot \sqrt{2}\right) \cdot \left(-y\right)} \]
    6. *-commutative31.3%

      \[\leadsto \color{blue}{\left(\sqrt{2} \cdot \sqrt{z}\right)} \cdot \left(-y\right) \]
  5. Simplified31.3%

    \[\leadsto \color{blue}{\left(\sqrt{2} \cdot \sqrt{z}\right) \cdot \left(-y\right)} \]
  6. Step-by-step derivation
    1. expm1-log1p-u21.5%

      \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\left(\sqrt{2} \cdot \sqrt{z}\right) \cdot \left(-y\right)\right)\right)} \]
    2. expm1-udef14.3%

      \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\left(\sqrt{2} \cdot \sqrt{z}\right) \cdot \left(-y\right)\right)} - 1} \]
    3. *-commutative14.3%

      \[\leadsto e^{\mathsf{log1p}\left(\color{blue}{\left(\sqrt{z} \cdot \sqrt{2}\right)} \cdot \left(-y\right)\right)} - 1 \]
    4. sqrt-prod14.3%

      \[\leadsto e^{\mathsf{log1p}\left(\color{blue}{\sqrt{z \cdot 2}} \cdot \left(-y\right)\right)} - 1 \]
    5. pow1/214.3%

      \[\leadsto e^{\mathsf{log1p}\left(\color{blue}{{\left(z \cdot 2\right)}^{0.5}} \cdot \left(-y\right)\right)} - 1 \]
    6. exp-to-pow14.2%

      \[\leadsto e^{\mathsf{log1p}\left(\color{blue}{e^{\log \left(z \cdot 2\right) \cdot 0.5}} \cdot \left(-y\right)\right)} - 1 \]
    7. add-sqr-sqrt12.9%

      \[\leadsto e^{\mathsf{log1p}\left(e^{\log \left(z \cdot 2\right) \cdot 0.5} \cdot \color{blue}{\left(\sqrt{-y} \cdot \sqrt{-y}\right)}\right)} - 1 \]
    8. sqrt-unprod14.6%

      \[\leadsto e^{\mathsf{log1p}\left(e^{\log \left(z \cdot 2\right) \cdot 0.5} \cdot \color{blue}{\sqrt{\left(-y\right) \cdot \left(-y\right)}}\right)} - 1 \]
    9. sqr-neg14.6%

      \[\leadsto e^{\mathsf{log1p}\left(e^{\log \left(z \cdot 2\right) \cdot 0.5} \cdot \sqrt{\color{blue}{y \cdot y}}\right)} - 1 \]
    10. sqrt-unprod1.2%

      \[\leadsto e^{\mathsf{log1p}\left(e^{\log \left(z \cdot 2\right) \cdot 0.5} \cdot \color{blue}{\left(\sqrt{y} \cdot \sqrt{y}\right)}\right)} - 1 \]
    11. add-sqr-sqrt1.7%

      \[\leadsto e^{\mathsf{log1p}\left(e^{\log \left(z \cdot 2\right) \cdot 0.5} \cdot \color{blue}{y}\right)} - 1 \]
    12. *-commutative1.7%

      \[\leadsto e^{\mathsf{log1p}\left(\color{blue}{y \cdot e^{\log \left(z \cdot 2\right) \cdot 0.5}}\right)} - 1 \]
    13. exp-to-pow1.7%

      \[\leadsto e^{\mathsf{log1p}\left(y \cdot \color{blue}{{\left(z \cdot 2\right)}^{0.5}}\right)} - 1 \]
    14. pow1/21.7%

      \[\leadsto e^{\mathsf{log1p}\left(y \cdot \color{blue}{\sqrt{z \cdot 2}}\right)} - 1 \]
    15. *-commutative1.7%

      \[\leadsto e^{\mathsf{log1p}\left(y \cdot \sqrt{\color{blue}{2 \cdot z}}\right)} - 1 \]
  7. Applied egg-rr1.7%

    \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(y \cdot \sqrt{2 \cdot z}\right)} - 1} \]
  8. Step-by-step derivation
    1. expm1-def1.6%

      \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(y \cdot \sqrt{2 \cdot z}\right)\right)} \]
    2. expm1-log1p1.9%

      \[\leadsto \color{blue}{y \cdot \sqrt{2 \cdot z}} \]
    3. *-commutative1.9%

      \[\leadsto y \cdot \sqrt{\color{blue}{z \cdot 2}} \]
  9. Simplified1.9%

    \[\leadsto \color{blue}{y \cdot \sqrt{z \cdot 2}} \]
  10. Final simplification1.9%

    \[\leadsto y \cdot \sqrt{z \cdot 2} \]

Developer target: 99.4% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot {\left(e^{1}\right)}^{\left(\frac{t \cdot t}{2}\right)} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (* (* (- (* x 0.5) y) (sqrt (* z 2.0))) (pow (exp 1.0) (/ (* t t) 2.0))))
double code(double x, double y, double z, double t) {
	return (((x * 0.5) - y) * sqrt((z * 2.0))) * pow(exp(1.0), ((t * t) / 2.0));
}
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 * 0.5d0) - y) * sqrt((z * 2.0d0))) * (exp(1.0d0) ** ((t * t) / 2.0d0))
end function
public static double code(double x, double y, double z, double t) {
	return (((x * 0.5) - y) * Math.sqrt((z * 2.0))) * Math.pow(Math.exp(1.0), ((t * t) / 2.0));
}
def code(x, y, z, t):
	return (((x * 0.5) - y) * math.sqrt((z * 2.0))) * math.pow(math.exp(1.0), ((t * t) / 2.0))
function code(x, y, z, t)
	return Float64(Float64(Float64(Float64(x * 0.5) - y) * sqrt(Float64(z * 2.0))) * (exp(1.0) ^ Float64(Float64(t * t) / 2.0)))
end
function tmp = code(x, y, z, t)
	tmp = (((x * 0.5) - y) * sqrt((z * 2.0))) * (exp(1.0) ^ ((t * t) / 2.0));
end
code[x_, y_, z_, t_] := N[(N[(N[(N[(x * 0.5), $MachinePrecision] - y), $MachinePrecision] * N[Sqrt[N[(z * 2.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] * N[Power[N[Exp[1.0], $MachinePrecision], N[(N[(t * t), $MachinePrecision] / 2.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\left(\left(x \cdot 0.5 - y\right) \cdot \sqrt{z \cdot 2}\right) \cdot {\left(e^{1}\right)}^{\left(\frac{t \cdot t}{2}\right)}
\end{array}

Reproduce

?
herbie shell --seed 2023308 
(FPCore (x y z t)
  :name "Data.Number.Erf:$cinvnormcdf from erf-2.0.0.0, A"
  :precision binary64

  :herbie-target
  (* (* (- (* x 0.5) y) (sqrt (* z 2.0))) (pow (exp 1.0) (/ (* t t) 2.0)))

  (* (* (- (* x 0.5) y) (sqrt (* z 2.0))) (exp (/ (* t t) 2.0))))