(FPCore (x y z t) :precision binary64 (/ (- (+ x y) z) (* t 2.0)))
(FPCore (x y z t) :precision binary64 (/ (/ (- (- z y) x) t) -2.0))
double code(double x, double y, double z, double t) {
return ((x + y) - z) / (t * 2.0);
}
double code(double x, double y, double z, double t) {
return (((z - y) - x) / 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 + y) - z) / (t * 2.0d0)
end function
real(8) function code(x, y, z, t)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
code = (((z - y) - x) / t) / (-2.0d0)
end function
public static double code(double x, double y, double z, double t) {
return ((x + y) - z) / (t * 2.0);
}
public static double code(double x, double y, double z, double t) {
return (((z - y) - x) / t) / -2.0;
}
def code(x, y, z, t): return ((x + y) - z) / (t * 2.0)
def code(x, y, z, t): return (((z - y) - x) / t) / -2.0
function code(x, y, z, t) return Float64(Float64(Float64(x + y) - z) / Float64(t * 2.0)) end
function code(x, y, z, t) return Float64(Float64(Float64(Float64(z - y) - x) / t) / -2.0) end
function tmp = code(x, y, z, t) tmp = ((x + y) - z) / (t * 2.0); end
function tmp = code(x, y, z, t) tmp = (((z - y) - x) / t) / -2.0; end
code[x_, y_, z_, t_] := N[(N[(N[(x + y), $MachinePrecision] - z), $MachinePrecision] / N[(t * 2.0), $MachinePrecision]), $MachinePrecision]
code[x_, y_, z_, t_] := N[(N[(N[(N[(z - y), $MachinePrecision] - x), $MachinePrecision] / t), $MachinePrecision] / -2.0), $MachinePrecision]
\frac{\left(x + y\right) - z}{t \cdot 2}
\frac{\frac{\left(z - y\right) - x}{t}}{-2}



Bits error versus x



Bits error versus y



Bits error versus z



Bits error versus t
Results
Initial program 0.1
Applied egg-rr0.3
Applied egg-rr0.1
Final simplification0.1
herbie shell --seed 2022151
(FPCore (x y z t)
:name "Optimisation.CirclePacking:place from circle-packing-0.1.0.4, B"
:precision binary64
(/ (- (+ x y) z) (* t 2.0)))