Alternative 1 | |
---|---|
Error | 0.6 |
Cost | 128 |
\[-x
\]
(FPCore (x) :precision binary64 (- (pow x 100.0) x))
(FPCore (x) :precision binary64 (- (pow x 100.0) x))
double code(double x) { return pow(x, 100.0) - x; }
double code(double x) { return pow(x, 100.0) - x; }
real(8) function code(x) real(8), intent (in) :: x code = (x ** 100.0d0) - x end function
real(8) function code(x) real(8), intent (in) :: x code = (x ** 100.0d0) - x end function
public static double code(double x) { return Math.pow(x, 100.0) - x; }
public static double code(double x) { return Math.pow(x, 100.0) - x; }
def code(x): return math.pow(x, 100.0) - x
def code(x): return math.pow(x, 100.0) - x
function code(x) return Float64((x ^ 100.0) - x) end
function code(x) return Float64((x ^ 100.0) - x) end
function tmp = code(x) tmp = (x ^ 100.0) - x; end
function tmp = code(x) tmp = (x ^ 100.0) - x; end
code[x_] := N[(N[Power[x, 100.0], $MachinePrecision] - x), $MachinePrecision]
code[x_] := N[(N[Power[x, 100.0], $MachinePrecision] - x), $MachinePrecision]
{x}^{100} - x
{x}^{100} - x
Results
Initial program 0.0
Final simplification0.0
Alternative 1 | |
---|---|
Error | 0.6 |
Cost | 128 |
herbie shell --seed 1
(FPCore (x)
:name "x^100-x"
:precision binary64
:pre (and (<= -1000.0 x) (<= x 1000.0))
(- (pow x 100.0) x))