(/ (* PI (+ (* -1/2 z0) 1/4)) z1)

Percentage Accurate: 99.6% → 99.6%
Time: 1.7s
Alternatives: 5
Speedup: N/A×

Specification

?
\[\frac{\pi \cdot \left(-0.5 \cdot z0 + 0.25\right)}{z1} \]
(FPCore (z0 z1)
  :precision binary64
  (/ (* PI (+ (* -0.5 z0) 0.25)) z1))
double code(double z0, double z1) {
	return (((double) M_PI) * ((-0.5 * z0) + 0.25)) / z1;
}
public static double code(double z0, double z1) {
	return (Math.PI * ((-0.5 * z0) + 0.25)) / z1;
}
def code(z0, z1):
	return (math.pi * ((-0.5 * z0) + 0.25)) / z1
function code(z0, z1)
	return Float64(Float64(pi * Float64(Float64(-0.5 * z0) + 0.25)) / z1)
end
function tmp = code(z0, z1)
	tmp = (pi * ((-0.5 * z0) + 0.25)) / z1;
end
code[z0_, z1_] := N[(N[(Pi * N[(N[(-0.5 * z0), $MachinePrecision] + 0.25), $MachinePrecision]), $MachinePrecision] / z1), $MachinePrecision]
\frac{\pi \cdot \left(-0.5 \cdot z0 + 0.25\right)}{z1}

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 5 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.6% accurate, 1.0× speedup?

\[\frac{\pi \cdot \left(-0.5 \cdot z0 + 0.25\right)}{z1} \]
(FPCore (z0 z1)
  :precision binary64
  (/ (* PI (+ (* -0.5 z0) 0.25)) z1))
double code(double z0, double z1) {
	return (((double) M_PI) * ((-0.5 * z0) + 0.25)) / z1;
}
public static double code(double z0, double z1) {
	return (Math.PI * ((-0.5 * z0) + 0.25)) / z1;
}
def code(z0, z1):
	return (math.pi * ((-0.5 * z0) + 0.25)) / z1
function code(z0, z1)
	return Float64(Float64(pi * Float64(Float64(-0.5 * z0) + 0.25)) / z1)
end
function tmp = code(z0, z1)
	tmp = (pi * ((-0.5 * z0) + 0.25)) / z1;
end
code[z0_, z1_] := N[(N[(Pi * N[(N[(-0.5 * z0), $MachinePrecision] + 0.25), $MachinePrecision]), $MachinePrecision] / z1), $MachinePrecision]
\frac{\pi \cdot \left(-0.5 \cdot z0 + 0.25\right)}{z1}

Alternative 1: 99.6% accurate, 0.8× speedup?

\[\frac{\pi}{\frac{z1}{-0.5 \cdot z0 - -0.25}} \]
(FPCore (z0 z1)
  :precision binary64
  (/ PI (/ z1 (- (* -0.5 z0) -0.25))))
double code(double z0, double z1) {
	return ((double) M_PI) / (z1 / ((-0.5 * z0) - -0.25));
}
public static double code(double z0, double z1) {
	return Math.PI / (z1 / ((-0.5 * z0) - -0.25));
}
def code(z0, z1):
	return math.pi / (z1 / ((-0.5 * z0) - -0.25))
function code(z0, z1)
	return Float64(pi / Float64(z1 / Float64(Float64(-0.5 * z0) - -0.25)))
end
function tmp = code(z0, z1)
	tmp = pi / (z1 / ((-0.5 * z0) - -0.25));
end
code[z0_, z1_] := N[(Pi / N[(z1 / N[(N[(-0.5 * z0), $MachinePrecision] - -0.25), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\frac{\pi}{\frac{z1}{-0.5 \cdot z0 - -0.25}}
Derivation
  1. Initial program 99.6%

    \[\frac{\pi \cdot \left(-0.5 \cdot z0 + 0.25\right)}{z1} \]
  2. Step-by-step derivation
    1. lift-*.f64N/A

      \[\leadsto \frac{\color{blue}{\pi \cdot \left(\frac{-1}{2} \cdot z0 + \frac{1}{4}\right)}}{z1} \]
    2. lift-+.f64N/A

      \[\leadsto \frac{\pi \cdot \color{blue}{\left(\frac{-1}{2} \cdot z0 + \frac{1}{4}\right)}}{z1} \]
    3. distribute-lft-inN/A

      \[\leadsto \frac{\color{blue}{\pi \cdot \left(\frac{-1}{2} \cdot z0\right) + \pi \cdot \frac{1}{4}}}{z1} \]
    4. add-flipN/A

      \[\leadsto \frac{\color{blue}{\pi \cdot \left(\frac{-1}{2} \cdot z0\right) - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}}{z1} \]
    5. lower--.f64N/A

      \[\leadsto \frac{\color{blue}{\pi \cdot \left(\frac{-1}{2} \cdot z0\right) - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}}{z1} \]
    6. *-commutativeN/A

      \[\leadsto \frac{\color{blue}{\left(\frac{-1}{2} \cdot z0\right) \cdot \pi} - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
    7. lower-*.f64N/A

      \[\leadsto \frac{\color{blue}{\left(\frac{-1}{2} \cdot z0\right) \cdot \pi} - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
    8. lift-*.f64N/A

      \[\leadsto \frac{\color{blue}{\left(\frac{-1}{2} \cdot z0\right)} \cdot \pi - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
    9. *-commutativeN/A

      \[\leadsto \frac{\color{blue}{\left(z0 \cdot \frac{-1}{2}\right)} \cdot \pi - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
    10. lower-*.f64N/A

      \[\leadsto \frac{\color{blue}{\left(z0 \cdot \frac{-1}{2}\right)} \cdot \pi - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
    11. *-commutativeN/A

      \[\leadsto \frac{\left(z0 \cdot \frac{-1}{2}\right) \cdot \pi - \left(\mathsf{neg}\left(\color{blue}{\frac{1}{4} \cdot \pi}\right)\right)}{z1} \]
    12. distribute-lft-neg-outN/A

      \[\leadsto \frac{\left(z0 \cdot \frac{-1}{2}\right) \cdot \pi - \color{blue}{\left(\mathsf{neg}\left(\frac{1}{4}\right)\right) \cdot \pi}}{z1} \]
    13. lower-*.f64N/A

      \[\leadsto \frac{\left(z0 \cdot \frac{-1}{2}\right) \cdot \pi - \color{blue}{\left(\mathsf{neg}\left(\frac{1}{4}\right)\right) \cdot \pi}}{z1} \]
    14. metadata-eval99.6%

      \[\leadsto \frac{\left(z0 \cdot -0.5\right) \cdot \pi - \color{blue}{-0.25} \cdot \pi}{z1} \]
  3. Applied rewrites99.6%

    \[\leadsto \frac{\color{blue}{\left(z0 \cdot -0.5\right) \cdot \pi - -0.25 \cdot \pi}}{z1} \]
  4. Step-by-step derivation
    1. lift-/.f64N/A

      \[\leadsto \color{blue}{\frac{\left(z0 \cdot \frac{-1}{2}\right) \cdot \pi - \frac{-1}{4} \cdot \pi}{z1}} \]
    2. div-flip-revN/A

      \[\leadsto \color{blue}{\frac{1}{\frac{z1}{\left(z0 \cdot \frac{-1}{2}\right) \cdot \pi - \frac{-1}{4} \cdot \pi}}} \]
    3. lift--.f64N/A

      \[\leadsto \frac{1}{\frac{z1}{\color{blue}{\left(z0 \cdot \frac{-1}{2}\right) \cdot \pi - \frac{-1}{4} \cdot \pi}}} \]
    4. lift-*.f64N/A

      \[\leadsto \frac{1}{\frac{z1}{\color{blue}{\left(z0 \cdot \frac{-1}{2}\right) \cdot \pi} - \frac{-1}{4} \cdot \pi}} \]
    5. lift-*.f64N/A

      \[\leadsto \frac{1}{\frac{z1}{\left(z0 \cdot \frac{-1}{2}\right) \cdot \pi - \color{blue}{\frac{-1}{4} \cdot \pi}}} \]
    6. distribute-rgt-out--N/A

      \[\leadsto \frac{1}{\frac{z1}{\color{blue}{\pi \cdot \left(z0 \cdot \frac{-1}{2} - \frac{-1}{4}\right)}}} \]
    7. lift--.f64N/A

      \[\leadsto \frac{1}{\frac{z1}{\pi \cdot \color{blue}{\left(z0 \cdot \frac{-1}{2} - \frac{-1}{4}\right)}}} \]
    8. lift-*.f64N/A

      \[\leadsto \frac{1}{\frac{z1}{\pi \cdot \left(\color{blue}{z0 \cdot \frac{-1}{2}} - \frac{-1}{4}\right)}} \]
    9. *-commutativeN/A

      \[\leadsto \frac{1}{\frac{z1}{\pi \cdot \left(\color{blue}{\frac{-1}{2} \cdot z0} - \frac{-1}{4}\right)}} \]
    10. lift-*.f64N/A

      \[\leadsto \frac{1}{\frac{z1}{\pi \cdot \left(\color{blue}{\frac{-1}{2} \cdot z0} - \frac{-1}{4}\right)}} \]
    11. *-commutativeN/A

      \[\leadsto \frac{1}{\frac{z1}{\color{blue}{\left(\frac{-1}{2} \cdot z0 - \frac{-1}{4}\right) \cdot \pi}}} \]
    12. lift-*.f64N/A

      \[\leadsto \frac{1}{\frac{z1}{\color{blue}{\left(\frac{-1}{2} \cdot z0 - \frac{-1}{4}\right) \cdot \pi}}} \]
    13. lift-*.f64N/A

      \[\leadsto \frac{1}{\frac{z1}{\color{blue}{\left(\frac{-1}{2} \cdot z0 - \frac{-1}{4}\right) \cdot \pi}}} \]
    14. *-commutativeN/A

      \[\leadsto \frac{1}{\frac{z1}{\color{blue}{\pi \cdot \left(\frac{-1}{2} \cdot z0 - \frac{-1}{4}\right)}}} \]
    15. lift--.f64N/A

      \[\leadsto \frac{1}{\frac{z1}{\pi \cdot \color{blue}{\left(\frac{-1}{2} \cdot z0 - \frac{-1}{4}\right)}}} \]
    16. lift-*.f64N/A

      \[\leadsto \frac{1}{\frac{z1}{\pi \cdot \left(\color{blue}{\frac{-1}{2} \cdot z0} - \frac{-1}{4}\right)}} \]
    17. *-commutativeN/A

      \[\leadsto \frac{1}{\frac{z1}{\pi \cdot \left(\color{blue}{z0 \cdot \frac{-1}{2}} - \frac{-1}{4}\right)}} \]
    18. lift-*.f64N/A

      \[\leadsto \frac{1}{\frac{z1}{\pi \cdot \left(\color{blue}{z0 \cdot \frac{-1}{2}} - \frac{-1}{4}\right)}} \]
    19. lift--.f64N/A

      \[\leadsto \frac{1}{\frac{z1}{\pi \cdot \color{blue}{\left(z0 \cdot \frac{-1}{2} - \frac{-1}{4}\right)}}} \]
    20. *-commutativeN/A

      \[\leadsto \frac{1}{\frac{z1}{\color{blue}{\left(z0 \cdot \frac{-1}{2} - \frac{-1}{4}\right) \cdot \pi}}} \]
  5. Applied rewrites99.6%

    \[\leadsto \color{blue}{\frac{\pi}{\frac{z1}{-0.5 \cdot z0 - -0.25}}} \]
  6. Add Preprocessing

Alternative 2: 99.6% accurate, 1.0× speedup?

\[\frac{\pi}{z1} \cdot \left(z0 \cdot -0.5 - -0.25\right) \]
(FPCore (z0 z1)
  :precision binary64
  (* (/ PI z1) (- (* z0 -0.5) -0.25)))
double code(double z0, double z1) {
	return (((double) M_PI) / z1) * ((z0 * -0.5) - -0.25);
}
public static double code(double z0, double z1) {
	return (Math.PI / z1) * ((z0 * -0.5) - -0.25);
}
def code(z0, z1):
	return (math.pi / z1) * ((z0 * -0.5) - -0.25)
function code(z0, z1)
	return Float64(Float64(pi / z1) * Float64(Float64(z0 * -0.5) - -0.25))
end
function tmp = code(z0, z1)
	tmp = (pi / z1) * ((z0 * -0.5) - -0.25);
end
code[z0_, z1_] := N[(N[(Pi / z1), $MachinePrecision] * N[(N[(z0 * -0.5), $MachinePrecision] - -0.25), $MachinePrecision]), $MachinePrecision]
\frac{\pi}{z1} \cdot \left(z0 \cdot -0.5 - -0.25\right)
Derivation
  1. Initial program 99.6%

    \[\frac{\pi \cdot \left(-0.5 \cdot z0 + 0.25\right)}{z1} \]
  2. Step-by-step derivation
    1. lift-/.f64N/A

      \[\leadsto \color{blue}{\frac{\pi \cdot \left(\frac{-1}{2} \cdot z0 + \frac{1}{4}\right)}{z1}} \]
    2. mult-flipN/A

      \[\leadsto \color{blue}{\left(\pi \cdot \left(\frac{-1}{2} \cdot z0 + \frac{1}{4}\right)\right) \cdot \frac{1}{z1}} \]
    3. lift-*.f64N/A

      \[\leadsto \color{blue}{\left(\pi \cdot \left(\frac{-1}{2} \cdot z0 + \frac{1}{4}\right)\right)} \cdot \frac{1}{z1} \]
    4. *-commutativeN/A

      \[\leadsto \color{blue}{\left(\left(\frac{-1}{2} \cdot z0 + \frac{1}{4}\right) \cdot \pi\right)} \cdot \frac{1}{z1} \]
    5. associate-*l*N/A

      \[\leadsto \color{blue}{\left(\frac{-1}{2} \cdot z0 + \frac{1}{4}\right) \cdot \left(\pi \cdot \frac{1}{z1}\right)} \]
    6. *-commutativeN/A

      \[\leadsto \color{blue}{\left(\pi \cdot \frac{1}{z1}\right) \cdot \left(\frac{-1}{2} \cdot z0 + \frac{1}{4}\right)} \]
    7. lower-*.f64N/A

      \[\leadsto \color{blue}{\left(\pi \cdot \frac{1}{z1}\right) \cdot \left(\frac{-1}{2} \cdot z0 + \frac{1}{4}\right)} \]
    8. mult-flip-revN/A

      \[\leadsto \color{blue}{\frac{\pi}{z1}} \cdot \left(\frac{-1}{2} \cdot z0 + \frac{1}{4}\right) \]
    9. lower-/.f6499.6%

      \[\leadsto \color{blue}{\frac{\pi}{z1}} \cdot \left(-0.5 \cdot z0 + 0.25\right) \]
    10. lift-+.f64N/A

      \[\leadsto \frac{\pi}{z1} \cdot \color{blue}{\left(\frac{-1}{2} \cdot z0 + \frac{1}{4}\right)} \]
    11. add-flipN/A

      \[\leadsto \frac{\pi}{z1} \cdot \color{blue}{\left(\frac{-1}{2} \cdot z0 - \left(\mathsf{neg}\left(\frac{1}{4}\right)\right)\right)} \]
    12. lower--.f64N/A

      \[\leadsto \frac{\pi}{z1} \cdot \color{blue}{\left(\frac{-1}{2} \cdot z0 - \left(\mathsf{neg}\left(\frac{1}{4}\right)\right)\right)} \]
    13. lift-*.f64N/A

      \[\leadsto \frac{\pi}{z1} \cdot \left(\color{blue}{\frac{-1}{2} \cdot z0} - \left(\mathsf{neg}\left(\frac{1}{4}\right)\right)\right) \]
    14. *-commutativeN/A

      \[\leadsto \frac{\pi}{z1} \cdot \left(\color{blue}{z0 \cdot \frac{-1}{2}} - \left(\mathsf{neg}\left(\frac{1}{4}\right)\right)\right) \]
    15. lower-*.f64N/A

      \[\leadsto \frac{\pi}{z1} \cdot \left(\color{blue}{z0 \cdot \frac{-1}{2}} - \left(\mathsf{neg}\left(\frac{1}{4}\right)\right)\right) \]
    16. metadata-eval99.6%

      \[\leadsto \frac{\pi}{z1} \cdot \left(z0 \cdot -0.5 - \color{blue}{-0.25}\right) \]
  3. Applied rewrites99.6%

    \[\leadsto \color{blue}{\frac{\pi}{z1} \cdot \left(z0 \cdot -0.5 - -0.25\right)} \]
  4. Add Preprocessing

Alternative 3: 97.5% accurate, 0.7× speedup?

\[\begin{array}{l} \mathbf{if}\;z0 \leq -1100:\\ \;\;\;\;z0 \cdot \left(-0.5 \cdot \frac{\pi}{z1}\right)\\ \mathbf{elif}\;z0 \leq 13.5:\\ \;\;\;\;\frac{0.7853981633974483}{z1}\\ \mathbf{else}:\\ \;\;\;\;\frac{-0.5 \cdot \left(z0 \cdot \pi\right)}{z1}\\ \end{array} \]
(FPCore (z0 z1)
  :precision binary64
  (if (<= z0 -1100.0)
  (* z0 (* -0.5 (/ PI z1)))
  (if (<= z0 13.5)
    (/ 0.7853981633974483 z1)
    (/ (* -0.5 (* z0 PI)) z1))))
double code(double z0, double z1) {
	double tmp;
	if (z0 <= -1100.0) {
		tmp = z0 * (-0.5 * (((double) M_PI) / z1));
	} else if (z0 <= 13.5) {
		tmp = 0.7853981633974483 / z1;
	} else {
		tmp = (-0.5 * (z0 * ((double) M_PI))) / z1;
	}
	return tmp;
}
public static double code(double z0, double z1) {
	double tmp;
	if (z0 <= -1100.0) {
		tmp = z0 * (-0.5 * (Math.PI / z1));
	} else if (z0 <= 13.5) {
		tmp = 0.7853981633974483 / z1;
	} else {
		tmp = (-0.5 * (z0 * Math.PI)) / z1;
	}
	return tmp;
}
def code(z0, z1):
	tmp = 0
	if z0 <= -1100.0:
		tmp = z0 * (-0.5 * (math.pi / z1))
	elif z0 <= 13.5:
		tmp = 0.7853981633974483 / z1
	else:
		tmp = (-0.5 * (z0 * math.pi)) / z1
	return tmp
function code(z0, z1)
	tmp = 0.0
	if (z0 <= -1100.0)
		tmp = Float64(z0 * Float64(-0.5 * Float64(pi / z1)));
	elseif (z0 <= 13.5)
		tmp = Float64(0.7853981633974483 / z1);
	else
		tmp = Float64(Float64(-0.5 * Float64(z0 * pi)) / z1);
	end
	return tmp
end
function tmp_2 = code(z0, z1)
	tmp = 0.0;
	if (z0 <= -1100.0)
		tmp = z0 * (-0.5 * (pi / z1));
	elseif (z0 <= 13.5)
		tmp = 0.7853981633974483 / z1;
	else
		tmp = (-0.5 * (z0 * pi)) / z1;
	end
	tmp_2 = tmp;
end
code[z0_, z1_] := If[LessEqual[z0, -1100.0], N[(z0 * N[(-0.5 * N[(Pi / z1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z0, 13.5], N[(0.7853981633974483 / z1), $MachinePrecision], N[(N[(-0.5 * N[(z0 * Pi), $MachinePrecision]), $MachinePrecision] / z1), $MachinePrecision]]]
\begin{array}{l}
\mathbf{if}\;z0 \leq -1100:\\
\;\;\;\;z0 \cdot \left(-0.5 \cdot \frac{\pi}{z1}\right)\\

\mathbf{elif}\;z0 \leq 13.5:\\
\;\;\;\;\frac{0.7853981633974483}{z1}\\

\mathbf{else}:\\
\;\;\;\;\frac{-0.5 \cdot \left(z0 \cdot \pi\right)}{z1}\\


\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z0 < -1100

    1. Initial program 99.6%

      \[\frac{\pi \cdot \left(-0.5 \cdot z0 + 0.25\right)}{z1} \]
    2. Taylor expanded in z0 around inf

      \[\leadsto \color{blue}{z0 \cdot \left(\frac{-1}{2} \cdot \frac{\pi}{z1} + \frac{1}{4} \cdot \frac{\pi}{z0 \cdot z1}\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto z0 \cdot \color{blue}{\left(\frac{-1}{2} \cdot \frac{\mathsf{PI}\left(\right)}{z1} + \frac{1}{4} \cdot \frac{\mathsf{PI}\left(\right)}{z0 \cdot z1}\right)} \]
      2. lower-+.f64N/A

        \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \frac{\mathsf{PI}\left(\right)}{z1} + \color{blue}{\frac{1}{4} \cdot \frac{\mathsf{PI}\left(\right)}{z0 \cdot z1}}\right) \]
      3. lower-*.f64N/A

        \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \frac{\mathsf{PI}\left(\right)}{z1} + \color{blue}{\frac{1}{4}} \cdot \frac{\mathsf{PI}\left(\right)}{z0 \cdot z1}\right) \]
      4. lower-/.f64N/A

        \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \frac{\mathsf{PI}\left(\right)}{z1} + \frac{1}{4} \cdot \frac{\mathsf{PI}\left(\right)}{z0 \cdot z1}\right) \]
      5. lower-PI.f64N/A

        \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \frac{\pi}{z1} + \frac{1}{4} \cdot \frac{\mathsf{PI}\left(\right)}{z0 \cdot z1}\right) \]
      6. lower-*.f64N/A

        \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \frac{\pi}{z1} + \frac{1}{4} \cdot \color{blue}{\frac{\mathsf{PI}\left(\right)}{z0 \cdot z1}}\right) \]
      7. lower-/.f64N/A

        \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \frac{\pi}{z1} + \frac{1}{4} \cdot \frac{\mathsf{PI}\left(\right)}{\color{blue}{z0 \cdot z1}}\right) \]
      8. lower-PI.f64N/A

        \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \frac{\pi}{z1} + \frac{1}{4} \cdot \frac{\pi}{\color{blue}{z0} \cdot z1}\right) \]
      9. lower-*.f6487.8%

        \[\leadsto z0 \cdot \left(-0.5 \cdot \frac{\pi}{z1} + 0.25 \cdot \frac{\pi}{z0 \cdot \color{blue}{z1}}\right) \]
    4. Applied rewrites87.8%

      \[\leadsto \color{blue}{z0 \cdot \left(-0.5 \cdot \frac{\pi}{z1} + 0.25 \cdot \frac{\pi}{z0 \cdot z1}\right)} \]
    5. Taylor expanded in z0 around inf

      \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \color{blue}{\frac{\pi}{z1}}\right) \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \frac{\mathsf{PI}\left(\right)}{\color{blue}{z1}}\right) \]
      2. lower-/.f64N/A

        \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \frac{\mathsf{PI}\left(\right)}{z1}\right) \]
      3. lower-PI.f6451.2%

        \[\leadsto z0 \cdot \left(-0.5 \cdot \frac{\pi}{z1}\right) \]
    7. Applied rewrites51.2%

      \[\leadsto z0 \cdot \left(-0.5 \cdot \color{blue}{\frac{\pi}{z1}}\right) \]

    if -1100 < z0 < 13.5

    1. Initial program 99.6%

      \[\frac{\pi \cdot \left(-0.5 \cdot z0 + 0.25\right)}{z1} \]
    2. Step-by-step derivation
      1. lift-*.f64N/A

        \[\leadsto \frac{\color{blue}{\pi \cdot \left(\frac{-1}{2} \cdot z0 + \frac{1}{4}\right)}}{z1} \]
      2. lift-+.f64N/A

        \[\leadsto \frac{\pi \cdot \color{blue}{\left(\frac{-1}{2} \cdot z0 + \frac{1}{4}\right)}}{z1} \]
      3. distribute-lft-inN/A

        \[\leadsto \frac{\color{blue}{\pi \cdot \left(\frac{-1}{2} \cdot z0\right) + \pi \cdot \frac{1}{4}}}{z1} \]
      4. add-flipN/A

        \[\leadsto \frac{\color{blue}{\pi \cdot \left(\frac{-1}{2} \cdot z0\right) - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}}{z1} \]
      5. lower--.f64N/A

        \[\leadsto \frac{\color{blue}{\pi \cdot \left(\frac{-1}{2} \cdot z0\right) - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}}{z1} \]
      6. *-commutativeN/A

        \[\leadsto \frac{\color{blue}{\left(\frac{-1}{2} \cdot z0\right) \cdot \pi} - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
      7. lower-*.f64N/A

        \[\leadsto \frac{\color{blue}{\left(\frac{-1}{2} \cdot z0\right) \cdot \pi} - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
      8. lift-*.f64N/A

        \[\leadsto \frac{\color{blue}{\left(\frac{-1}{2} \cdot z0\right)} \cdot \pi - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
      9. *-commutativeN/A

        \[\leadsto \frac{\color{blue}{\left(z0 \cdot \frac{-1}{2}\right)} \cdot \pi - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
      10. lower-*.f64N/A

        \[\leadsto \frac{\color{blue}{\left(z0 \cdot \frac{-1}{2}\right)} \cdot \pi - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
      11. *-commutativeN/A

        \[\leadsto \frac{\left(z0 \cdot \frac{-1}{2}\right) \cdot \pi - \left(\mathsf{neg}\left(\color{blue}{\frac{1}{4} \cdot \pi}\right)\right)}{z1} \]
      12. distribute-lft-neg-outN/A

        \[\leadsto \frac{\left(z0 \cdot \frac{-1}{2}\right) \cdot \pi - \color{blue}{\left(\mathsf{neg}\left(\frac{1}{4}\right)\right) \cdot \pi}}{z1} \]
      13. lower-*.f64N/A

        \[\leadsto \frac{\left(z0 \cdot \frac{-1}{2}\right) \cdot \pi - \color{blue}{\left(\mathsf{neg}\left(\frac{1}{4}\right)\right) \cdot \pi}}{z1} \]
      14. metadata-eval99.6%

        \[\leadsto \frac{\left(z0 \cdot -0.5\right) \cdot \pi - \color{blue}{-0.25} \cdot \pi}{z1} \]
    3. Applied rewrites99.6%

      \[\leadsto \frac{\color{blue}{\left(z0 \cdot -0.5\right) \cdot \pi - -0.25 \cdot \pi}}{z1} \]
    4. Evaluated real constant99.6%

      \[\leadsto \frac{\left(z0 \cdot -0.5\right) \cdot \pi - \color{blue}{-0.7853981633974483}}{z1} \]
    5. Taylor expanded in z0 around 0

      \[\leadsto \frac{\color{blue}{\frac{884279719003555}{1125899906842624}}}{z1} \]
    6. Step-by-step derivation
      1. Applied rewrites50.5%

        \[\leadsto \frac{\color{blue}{0.7853981633974483}}{z1} \]

      if 13.5 < z0

      1. Initial program 99.6%

        \[\frac{\pi \cdot \left(-0.5 \cdot z0 + 0.25\right)}{z1} \]
      2. Taylor expanded in z0 around 0

        \[\leadsto \frac{\pi \cdot \color{blue}{\frac{1}{4}}}{z1} \]
      3. Step-by-step derivation
        1. Applied rewrites50.5%

          \[\leadsto \frac{\pi \cdot \color{blue}{0.25}}{z1} \]
        2. Taylor expanded in z0 around inf

          \[\leadsto \frac{\color{blue}{\frac{-1}{2} \cdot \left(z0 \cdot \pi\right)}}{z1} \]
        3. Step-by-step derivation
          1. lower-*.f64N/A

            \[\leadsto \frac{\frac{-1}{2} \cdot \color{blue}{\left(z0 \cdot \mathsf{PI}\left(\right)\right)}}{z1} \]
          2. lower-*.f64N/A

            \[\leadsto \frac{\frac{-1}{2} \cdot \left(z0 \cdot \color{blue}{\mathsf{PI}\left(\right)}\right)}{z1} \]
          3. lower-PI.f6451.2%

            \[\leadsto \frac{-0.5 \cdot \left(z0 \cdot \pi\right)}{z1} \]
        4. Applied rewrites51.2%

          \[\leadsto \frac{\color{blue}{-0.5 \cdot \left(z0 \cdot \pi\right)}}{z1} \]
      4. Recombined 3 regimes into one program.
      5. Add Preprocessing

      Alternative 4: 97.5% accurate, 0.7× speedup?

      \[\begin{array}{l} t_0 := z0 \cdot \left(-0.5 \cdot \frac{\pi}{z1}\right)\\ \mathbf{if}\;z0 \leq -1100:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;z0 \leq 13.5:\\ \;\;\;\;\frac{0.7853981633974483}{z1}\\ \mathbf{else}:\\ \;\;\;\;t\_0\\ \end{array} \]
      (FPCore (z0 z1)
        :precision binary64
        (let* ((t_0 (* z0 (* -0.5 (/ PI z1)))))
        (if (<= z0 -1100.0)
          t_0
          (if (<= z0 13.5) (/ 0.7853981633974483 z1) t_0))))
      double code(double z0, double z1) {
      	double t_0 = z0 * (-0.5 * (((double) M_PI) / z1));
      	double tmp;
      	if (z0 <= -1100.0) {
      		tmp = t_0;
      	} else if (z0 <= 13.5) {
      		tmp = 0.7853981633974483 / z1;
      	} else {
      		tmp = t_0;
      	}
      	return tmp;
      }
      
      public static double code(double z0, double z1) {
      	double t_0 = z0 * (-0.5 * (Math.PI / z1));
      	double tmp;
      	if (z0 <= -1100.0) {
      		tmp = t_0;
      	} else if (z0 <= 13.5) {
      		tmp = 0.7853981633974483 / z1;
      	} else {
      		tmp = t_0;
      	}
      	return tmp;
      }
      
      def code(z0, z1):
      	t_0 = z0 * (-0.5 * (math.pi / z1))
      	tmp = 0
      	if z0 <= -1100.0:
      		tmp = t_0
      	elif z0 <= 13.5:
      		tmp = 0.7853981633974483 / z1
      	else:
      		tmp = t_0
      	return tmp
      
      function code(z0, z1)
      	t_0 = Float64(z0 * Float64(-0.5 * Float64(pi / z1)))
      	tmp = 0.0
      	if (z0 <= -1100.0)
      		tmp = t_0;
      	elseif (z0 <= 13.5)
      		tmp = Float64(0.7853981633974483 / z1);
      	else
      		tmp = t_0;
      	end
      	return tmp
      end
      
      function tmp_2 = code(z0, z1)
      	t_0 = z0 * (-0.5 * (pi / z1));
      	tmp = 0.0;
      	if (z0 <= -1100.0)
      		tmp = t_0;
      	elseif (z0 <= 13.5)
      		tmp = 0.7853981633974483 / z1;
      	else
      		tmp = t_0;
      	end
      	tmp_2 = tmp;
      end
      
      code[z0_, z1_] := Block[{t$95$0 = N[(z0 * N[(-0.5 * N[(Pi / z1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z0, -1100.0], t$95$0, If[LessEqual[z0, 13.5], N[(0.7853981633974483 / z1), $MachinePrecision], t$95$0]]]
      
      \begin{array}{l}
      t_0 := z0 \cdot \left(-0.5 \cdot \frac{\pi}{z1}\right)\\
      \mathbf{if}\;z0 \leq -1100:\\
      \;\;\;\;t\_0\\
      
      \mathbf{elif}\;z0 \leq 13.5:\\
      \;\;\;\;\frac{0.7853981633974483}{z1}\\
      
      \mathbf{else}:\\
      \;\;\;\;t\_0\\
      
      
      \end{array}
      
      Derivation
      1. Split input into 2 regimes
      2. if z0 < -1100 or 13.5 < z0

        1. Initial program 99.6%

          \[\frac{\pi \cdot \left(-0.5 \cdot z0 + 0.25\right)}{z1} \]
        2. Taylor expanded in z0 around inf

          \[\leadsto \color{blue}{z0 \cdot \left(\frac{-1}{2} \cdot \frac{\pi}{z1} + \frac{1}{4} \cdot \frac{\pi}{z0 \cdot z1}\right)} \]
        3. Step-by-step derivation
          1. lower-*.f64N/A

            \[\leadsto z0 \cdot \color{blue}{\left(\frac{-1}{2} \cdot \frac{\mathsf{PI}\left(\right)}{z1} + \frac{1}{4} \cdot \frac{\mathsf{PI}\left(\right)}{z0 \cdot z1}\right)} \]
          2. lower-+.f64N/A

            \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \frac{\mathsf{PI}\left(\right)}{z1} + \color{blue}{\frac{1}{4} \cdot \frac{\mathsf{PI}\left(\right)}{z0 \cdot z1}}\right) \]
          3. lower-*.f64N/A

            \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \frac{\mathsf{PI}\left(\right)}{z1} + \color{blue}{\frac{1}{4}} \cdot \frac{\mathsf{PI}\left(\right)}{z0 \cdot z1}\right) \]
          4. lower-/.f64N/A

            \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \frac{\mathsf{PI}\left(\right)}{z1} + \frac{1}{4} \cdot \frac{\mathsf{PI}\left(\right)}{z0 \cdot z1}\right) \]
          5. lower-PI.f64N/A

            \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \frac{\pi}{z1} + \frac{1}{4} \cdot \frac{\mathsf{PI}\left(\right)}{z0 \cdot z1}\right) \]
          6. lower-*.f64N/A

            \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \frac{\pi}{z1} + \frac{1}{4} \cdot \color{blue}{\frac{\mathsf{PI}\left(\right)}{z0 \cdot z1}}\right) \]
          7. lower-/.f64N/A

            \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \frac{\pi}{z1} + \frac{1}{4} \cdot \frac{\mathsf{PI}\left(\right)}{\color{blue}{z0 \cdot z1}}\right) \]
          8. lower-PI.f64N/A

            \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \frac{\pi}{z1} + \frac{1}{4} \cdot \frac{\pi}{\color{blue}{z0} \cdot z1}\right) \]
          9. lower-*.f6487.8%

            \[\leadsto z0 \cdot \left(-0.5 \cdot \frac{\pi}{z1} + 0.25 \cdot \frac{\pi}{z0 \cdot \color{blue}{z1}}\right) \]
        4. Applied rewrites87.8%

          \[\leadsto \color{blue}{z0 \cdot \left(-0.5 \cdot \frac{\pi}{z1} + 0.25 \cdot \frac{\pi}{z0 \cdot z1}\right)} \]
        5. Taylor expanded in z0 around inf

          \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \color{blue}{\frac{\pi}{z1}}\right) \]
        6. Step-by-step derivation
          1. lower-*.f64N/A

            \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \frac{\mathsf{PI}\left(\right)}{\color{blue}{z1}}\right) \]
          2. lower-/.f64N/A

            \[\leadsto z0 \cdot \left(\frac{-1}{2} \cdot \frac{\mathsf{PI}\left(\right)}{z1}\right) \]
          3. lower-PI.f6451.2%

            \[\leadsto z0 \cdot \left(-0.5 \cdot \frac{\pi}{z1}\right) \]
        7. Applied rewrites51.2%

          \[\leadsto z0 \cdot \left(-0.5 \cdot \color{blue}{\frac{\pi}{z1}}\right) \]

        if -1100 < z0 < 13.5

        1. Initial program 99.6%

          \[\frac{\pi \cdot \left(-0.5 \cdot z0 + 0.25\right)}{z1} \]
        2. Step-by-step derivation
          1. lift-*.f64N/A

            \[\leadsto \frac{\color{blue}{\pi \cdot \left(\frac{-1}{2} \cdot z0 + \frac{1}{4}\right)}}{z1} \]
          2. lift-+.f64N/A

            \[\leadsto \frac{\pi \cdot \color{blue}{\left(\frac{-1}{2} \cdot z0 + \frac{1}{4}\right)}}{z1} \]
          3. distribute-lft-inN/A

            \[\leadsto \frac{\color{blue}{\pi \cdot \left(\frac{-1}{2} \cdot z0\right) + \pi \cdot \frac{1}{4}}}{z1} \]
          4. add-flipN/A

            \[\leadsto \frac{\color{blue}{\pi \cdot \left(\frac{-1}{2} \cdot z0\right) - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}}{z1} \]
          5. lower--.f64N/A

            \[\leadsto \frac{\color{blue}{\pi \cdot \left(\frac{-1}{2} \cdot z0\right) - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}}{z1} \]
          6. *-commutativeN/A

            \[\leadsto \frac{\color{blue}{\left(\frac{-1}{2} \cdot z0\right) \cdot \pi} - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
          7. lower-*.f64N/A

            \[\leadsto \frac{\color{blue}{\left(\frac{-1}{2} \cdot z0\right) \cdot \pi} - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
          8. lift-*.f64N/A

            \[\leadsto \frac{\color{blue}{\left(\frac{-1}{2} \cdot z0\right)} \cdot \pi - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
          9. *-commutativeN/A

            \[\leadsto \frac{\color{blue}{\left(z0 \cdot \frac{-1}{2}\right)} \cdot \pi - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
          10. lower-*.f64N/A

            \[\leadsto \frac{\color{blue}{\left(z0 \cdot \frac{-1}{2}\right)} \cdot \pi - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
          11. *-commutativeN/A

            \[\leadsto \frac{\left(z0 \cdot \frac{-1}{2}\right) \cdot \pi - \left(\mathsf{neg}\left(\color{blue}{\frac{1}{4} \cdot \pi}\right)\right)}{z1} \]
          12. distribute-lft-neg-outN/A

            \[\leadsto \frac{\left(z0 \cdot \frac{-1}{2}\right) \cdot \pi - \color{blue}{\left(\mathsf{neg}\left(\frac{1}{4}\right)\right) \cdot \pi}}{z1} \]
          13. lower-*.f64N/A

            \[\leadsto \frac{\left(z0 \cdot \frac{-1}{2}\right) \cdot \pi - \color{blue}{\left(\mathsf{neg}\left(\frac{1}{4}\right)\right) \cdot \pi}}{z1} \]
          14. metadata-eval99.6%

            \[\leadsto \frac{\left(z0 \cdot -0.5\right) \cdot \pi - \color{blue}{-0.25} \cdot \pi}{z1} \]
        3. Applied rewrites99.6%

          \[\leadsto \frac{\color{blue}{\left(z0 \cdot -0.5\right) \cdot \pi - -0.25 \cdot \pi}}{z1} \]
        4. Evaluated real constant99.6%

          \[\leadsto \frac{\left(z0 \cdot -0.5\right) \cdot \pi - \color{blue}{-0.7853981633974483}}{z1} \]
        5. Taylor expanded in z0 around 0

          \[\leadsto \frac{\color{blue}{\frac{884279719003555}{1125899906842624}}}{z1} \]
        6. Step-by-step derivation
          1. Applied rewrites50.5%

            \[\leadsto \frac{\color{blue}{0.7853981633974483}}{z1} \]
        7. Recombined 2 regimes into one program.
        8. Add Preprocessing

        Alternative 5: 50.5% accurate, 2.1× speedup?

        \[\frac{0.7853981633974483}{z1} \]
        (FPCore (z0 z1)
          :precision binary64
          (/ 0.7853981633974483 z1))
        double code(double z0, double z1) {
        	return 0.7853981633974483 / z1;
        }
        
        module fmin_fmax_functions
            implicit none
            private
            public fmax
            public fmin
        
            interface fmax
                module procedure fmax88
                module procedure fmax44
                module procedure fmax84
                module procedure fmax48
            end interface
            interface fmin
                module procedure fmin88
                module procedure fmin44
                module procedure fmin84
                module procedure fmin48
            end interface
        contains
            real(8) function fmax88(x, y) result (res)
                real(8), intent (in) :: x
                real(8), intent (in) :: y
                res = merge(y, merge(x, max(x, y), y /= y), x /= x)
            end function
            real(4) function fmax44(x, y) result (res)
                real(4), intent (in) :: x
                real(4), intent (in) :: y
                res = merge(y, merge(x, max(x, y), y /= y), x /= x)
            end function
            real(8) function fmax84(x, y) result(res)
                real(8), intent (in) :: x
                real(4), intent (in) :: y
                res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
            end function
            real(8) function fmax48(x, y) result(res)
                real(4), intent (in) :: x
                real(8), intent (in) :: y
                res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
            end function
            real(8) function fmin88(x, y) result (res)
                real(8), intent (in) :: x
                real(8), intent (in) :: y
                res = merge(y, merge(x, min(x, y), y /= y), x /= x)
            end function
            real(4) function fmin44(x, y) result (res)
                real(4), intent (in) :: x
                real(4), intent (in) :: y
                res = merge(y, merge(x, min(x, y), y /= y), x /= x)
            end function
            real(8) function fmin84(x, y) result(res)
                real(8), intent (in) :: x
                real(4), intent (in) :: y
                res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
            end function
            real(8) function fmin48(x, y) result(res)
                real(4), intent (in) :: x
                real(8), intent (in) :: y
                res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
            end function
        end module
        
        real(8) function code(z0, z1)
        use fmin_fmax_functions
            real(8), intent (in) :: z0
            real(8), intent (in) :: z1
            code = 0.7853981633974483d0 / z1
        end function
        
        public static double code(double z0, double z1) {
        	return 0.7853981633974483 / z1;
        }
        
        def code(z0, z1):
        	return 0.7853981633974483 / z1
        
        function code(z0, z1)
        	return Float64(0.7853981633974483 / z1)
        end
        
        function tmp = code(z0, z1)
        	tmp = 0.7853981633974483 / z1;
        end
        
        code[z0_, z1_] := N[(0.7853981633974483 / z1), $MachinePrecision]
        
        \frac{0.7853981633974483}{z1}
        
        Derivation
        1. Initial program 99.6%

          \[\frac{\pi \cdot \left(-0.5 \cdot z0 + 0.25\right)}{z1} \]
        2. Step-by-step derivation
          1. lift-*.f64N/A

            \[\leadsto \frac{\color{blue}{\pi \cdot \left(\frac{-1}{2} \cdot z0 + \frac{1}{4}\right)}}{z1} \]
          2. lift-+.f64N/A

            \[\leadsto \frac{\pi \cdot \color{blue}{\left(\frac{-1}{2} \cdot z0 + \frac{1}{4}\right)}}{z1} \]
          3. distribute-lft-inN/A

            \[\leadsto \frac{\color{blue}{\pi \cdot \left(\frac{-1}{2} \cdot z0\right) + \pi \cdot \frac{1}{4}}}{z1} \]
          4. add-flipN/A

            \[\leadsto \frac{\color{blue}{\pi \cdot \left(\frac{-1}{2} \cdot z0\right) - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}}{z1} \]
          5. lower--.f64N/A

            \[\leadsto \frac{\color{blue}{\pi \cdot \left(\frac{-1}{2} \cdot z0\right) - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}}{z1} \]
          6. *-commutativeN/A

            \[\leadsto \frac{\color{blue}{\left(\frac{-1}{2} \cdot z0\right) \cdot \pi} - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
          7. lower-*.f64N/A

            \[\leadsto \frac{\color{blue}{\left(\frac{-1}{2} \cdot z0\right) \cdot \pi} - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
          8. lift-*.f64N/A

            \[\leadsto \frac{\color{blue}{\left(\frac{-1}{2} \cdot z0\right)} \cdot \pi - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
          9. *-commutativeN/A

            \[\leadsto \frac{\color{blue}{\left(z0 \cdot \frac{-1}{2}\right)} \cdot \pi - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
          10. lower-*.f64N/A

            \[\leadsto \frac{\color{blue}{\left(z0 \cdot \frac{-1}{2}\right)} \cdot \pi - \left(\mathsf{neg}\left(\pi \cdot \frac{1}{4}\right)\right)}{z1} \]
          11. *-commutativeN/A

            \[\leadsto \frac{\left(z0 \cdot \frac{-1}{2}\right) \cdot \pi - \left(\mathsf{neg}\left(\color{blue}{\frac{1}{4} \cdot \pi}\right)\right)}{z1} \]
          12. distribute-lft-neg-outN/A

            \[\leadsto \frac{\left(z0 \cdot \frac{-1}{2}\right) \cdot \pi - \color{blue}{\left(\mathsf{neg}\left(\frac{1}{4}\right)\right) \cdot \pi}}{z1} \]
          13. lower-*.f64N/A

            \[\leadsto \frac{\left(z0 \cdot \frac{-1}{2}\right) \cdot \pi - \color{blue}{\left(\mathsf{neg}\left(\frac{1}{4}\right)\right) \cdot \pi}}{z1} \]
          14. metadata-eval99.6%

            \[\leadsto \frac{\left(z0 \cdot -0.5\right) \cdot \pi - \color{blue}{-0.25} \cdot \pi}{z1} \]
        3. Applied rewrites99.6%

          \[\leadsto \frac{\color{blue}{\left(z0 \cdot -0.5\right) \cdot \pi - -0.25 \cdot \pi}}{z1} \]
        4. Evaluated real constant99.6%

          \[\leadsto \frac{\left(z0 \cdot -0.5\right) \cdot \pi - \color{blue}{-0.7853981633974483}}{z1} \]
        5. Taylor expanded in z0 around 0

          \[\leadsto \frac{\color{blue}{\frac{884279719003555}{1125899906842624}}}{z1} \]
        6. Step-by-step derivation
          1. Applied rewrites50.5%

            \[\leadsto \frac{\color{blue}{0.7853981633974483}}{z1} \]
          2. Add Preprocessing

          Reproduce

          ?
          herbie shell --seed 2025250 
          (FPCore (z0 z1)
            :name "(/ (* PI (+ (* -1/2 z0) 1/4)) z1)"
            :precision binary64
            (/ (* PI (+ (* -0.5 z0) 0.25)) z1))