?

Average Error: 0.0 → 0.0
Time: 10.9s
Precision: binary64
Cost: 448

?

\[\left(x + y\right) \cdot \left(z + 1\right) \]
\[\left(x + y\right) \cdot \left(z + 1\right) \]
(FPCore (x y z) :precision binary64 (* (+ x y) (+ z 1.0)))
(FPCore (x y z) :precision binary64 (* (+ x y) (+ z 1.0)))
double code(double x, double y, double z) {
	return (x + y) * (z + 1.0);
}
double code(double x, double y, double z) {
	return (x + y) * (z + 1.0);
}
real(8) function code(x, y, z)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    code = (x + y) * (z + 1.0d0)
end function
real(8) function code(x, y, z)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    code = (x + y) * (z + 1.0d0)
end function
public static double code(double x, double y, double z) {
	return (x + y) * (z + 1.0);
}
public static double code(double x, double y, double z) {
	return (x + y) * (z + 1.0);
}
def code(x, y, z):
	return (x + y) * (z + 1.0)
def code(x, y, z):
	return (x + y) * (z + 1.0)
function code(x, y, z)
	return Float64(Float64(x + y) * Float64(z + 1.0))
end
function code(x, y, z)
	return Float64(Float64(x + y) * Float64(z + 1.0))
end
function tmp = code(x, y, z)
	tmp = (x + y) * (z + 1.0);
end
function tmp = code(x, y, z)
	tmp = (x + y) * (z + 1.0);
end
code[x_, y_, z_] := N[(N[(x + y), $MachinePrecision] * N[(z + 1.0), $MachinePrecision]), $MachinePrecision]
code[x_, y_, z_] := N[(N[(x + y), $MachinePrecision] * N[(z + 1.0), $MachinePrecision]), $MachinePrecision]
\left(x + y\right) \cdot \left(z + 1\right)
\left(x + y\right) \cdot \left(z + 1\right)

Error?

Try it out?

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation?

  1. Initial program 0.0

    \[\left(x + y\right) \cdot \left(z + 1\right) \]
  2. Final simplification0.0

    \[\leadsto \left(x + y\right) \cdot \left(z + 1\right) \]

Alternatives

Alternative 1
Error12.1
Cost720
\[\begin{array}{l} t_0 := y \cdot \left(z - -1\right)\\ \mathbf{if}\;z \leq -2.2 \cdot 10^{-7}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;z \leq 4.6 \cdot 10^{-6}:\\ \;\;\;\;y + x\\ \mathbf{elif}\;z \leq 1.25 \cdot 10^{+21}:\\ \;\;\;\;t_0\\ \mathbf{elif}\;z \leq 1.85 \cdot 10^{+95}:\\ \;\;\;\;z \cdot x\\ \mathbf{else}:\\ \;\;\;\;z \cdot y\\ \end{array} \]
Alternative 2
Error32.4
Cost588
\[\begin{array}{l} \mathbf{if}\;z \leq -1:\\ \;\;\;\;z \cdot y\\ \mathbf{elif}\;z \leq 205000000000:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq 8.6 \cdot 10^{+94}:\\ \;\;\;\;z \cdot x\\ \mathbf{else}:\\ \;\;\;\;z \cdot y\\ \end{array} \]
Alternative 3
Error12.7
Cost588
\[\begin{array}{l} \mathbf{if}\;z \leq -1:\\ \;\;\;\;z \cdot y\\ \mathbf{elif}\;z \leq 205000000000:\\ \;\;\;\;y + x\\ \mathbf{elif}\;z \leq 1.15 \cdot 10^{+95}:\\ \;\;\;\;z \cdot x\\ \mathbf{else}:\\ \;\;\;\;z \cdot y\\ \end{array} \]
Alternative 4
Error1.6
Cost584
\[\begin{array}{l} t_0 := \left(y + x\right) \cdot z\\ \mathbf{if}\;z \leq -1:\\ \;\;\;\;t_0\\ \mathbf{elif}\;z \leq 1:\\ \;\;\;\;y + x\\ \mathbf{else}:\\ \;\;\;\;t_0\\ \end{array} \]
Alternative 5
Error32.7
Cost456
\[\begin{array}{l} \mathbf{if}\;z \leq -1:\\ \;\;\;\;z \cdot x\\ \mathbf{elif}\;z \leq 205000000000:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;z \cdot x\\ \end{array} \]
Alternative 6
Error42.9
Cost64
\[x \]

Error

Reproduce?

herbie shell --seed 2023074 
(FPCore (x y z)
  :name "Optimisation.CirclePacking:place from circle-packing-0.1.0.4, G"
  :precision binary64
  (* (+ x y) (+ z 1.0)))