Average Error: 0.1 → 0.1
Time: 3.2s
Precision: binary64
Cost: 6912
\[0.954929658551372 \cdot x - 0.12900613773279798 \cdot \left(\left(x \cdot x\right) \cdot x\right)\]
\[x \cdot 0.954929658551372 - 0.12900613773279798 \cdot {x}^{3}\]
0.954929658551372 \cdot x - 0.12900613773279798 \cdot \left(\left(x \cdot x\right) \cdot x\right)
x \cdot 0.954929658551372 - 0.12900613773279798 \cdot {x}^{3}
(FPCore (x)
 :precision binary64
 (- (* 0.954929658551372 x) (* 0.12900613773279798 (* (* x x) x))))
(FPCore (x)
 :precision binary64
 (- (* x 0.954929658551372) (* 0.12900613773279798 (pow x 3.0))))
double code(double x) {
	return (0.954929658551372 * x) - (0.12900613773279798 * ((x * x) * x));
}
double code(double x) {
	return (x * 0.954929658551372) - (0.12900613773279798 * pow(x, 3.0));
}

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Alternatives

Alternative 1
Error0.4
Cost39552
\[x \cdot 0.954929658551372 - \sqrt[3]{0.12900613773279798 \cdot {x}^{3}} \cdot \left(\sqrt[3]{0.12900613773279798 \cdot {x}^{3}} \cdot \sqrt[3]{0.12900613773279798 \cdot {x}^{3}}\right)\]
Alternative 2
Error32.1
Cost26688
\[\sqrt{x \cdot 0.954929658551372 - 0.12900613773279798 \cdot {x}^{3}} \cdot \sqrt{x \cdot 0.954929658551372 - 0.12900613773279798 \cdot {x}^{3}}\]
Alternative 3
Error32.0
Cost26560
\[x \cdot 0.954929658551372 - \left(\sqrt{0.12900613773279798} \cdot \left(x \cdot \sqrt{x}\right)\right) \cdot \left(\sqrt{0.12900613773279798} \cdot \left(x \cdot \sqrt{x}\right)\right)\]
Alternative 4
Error32.0
Cost26432
\[x \cdot 0.954929658551372 - \left(\sqrt{0.12900613773279798} \cdot {x}^{1.5}\right) \cdot \left(\sqrt{0.12900613773279798} \cdot {x}^{1.5}\right)\]
Alternative 5
Error16.3
Cost26432
\[x \cdot 0.954929658551372 - \sqrt{0.12900613773279798 \cdot {x}^{3}} \cdot \sqrt{0.12900613773279798 \cdot {x}^{3}}\]
Alternative 6
Error40.3
Cost19776
\[\sqrt[3]{{\left(x \cdot 0.954929658551372 - 0.12900613773279798 \cdot {x}^{3}\right)}^{3}}\]
Alternative 7
Error29.7
Cost14016
\[\frac{x \cdot \left(x \cdot 0.91189065278104\right) + -0.016642583572733644 \cdot {x}^{6}}{x \cdot 0.954929658551372 + 0.12900613773279798 \cdot {x}^{3}}\]
Alternative 8
Error32.1
Cost14016
\[\sqrt{x \cdot \left(0.954929658551372 + \left(x \cdot x\right) \cdot -0.12900613773279798\right)} \cdot \sqrt{x \cdot \left(0.954929658551372 + \left(x \cdot x\right) \cdot -0.12900613773279798\right)}\]
Alternative 9
Error0.3
Cost13568
\[x \cdot 0.954929658551372 - \left(\left(x \cdot x\right) \cdot 0.12900613773279798\right) \cdot {\left(\sqrt[3]{x}\right)}^{3}\]
Alternative 10
Error10.5
Cost13312
\[x \cdot 0.954929658551372 - \sqrt[3]{0.0021469954286136776 \cdot {x}^{9}}\]
Alternative 11
Error29.7
Cost7680
\[\frac{x \cdot \left(x \cdot 0.91189065278104\right) + -0.016642583572733644 \cdot {x}^{6}}{x \cdot \left(0.954929658551372 - \left(x \cdot x\right) \cdot -0.12900613773279798\right)}\]
Alternative 12
Error6.4
Cost7424
\[\frac{x \cdot \left(0.91189065278104 + {x}^{4} \cdot -0.016642583572733644\right)}{0.954929658551372 - \left(x \cdot x\right) \cdot -0.12900613773279798}\]
Alternative 13
Error46.6
Cost6656
\[-0.12900613773279798 \cdot {x}^{3}\]
Alternative 14
Error0.1
Cost704
\[x \cdot 0.954929658551372 - 0.12900613773279798 \cdot \left(x \cdot \left(x \cdot x\right)\right)\]
Alternative 15
Error0.1
Cost704
\[x \cdot 0.954929658551372 - \left(x \cdot x\right) \cdot \left(x \cdot 0.12900613773279798\right)\]
Alternative 16
Error0.1
Cost704
\[x \cdot 0.954929658551372 - x \cdot \left(\left(x \cdot x\right) \cdot 0.12900613773279798\right)\]
Alternative 17
Error0.1
Cost576
\[x \cdot \left(0.954929658551372 + \left(x \cdot x\right) \cdot -0.12900613773279798\right)\]
Alternative 18
Error16.0
Cost192
\[x \cdot 0.954929658551372\]
Alternative 19
Error61.6
Cost64
\[1\]
Alternative 20
Error61.1
Cost64
\[0\]
Alternative 21
Error61.7
Cost64
\[-1\]

Error

Derivation

  1. Initial program 0.1

    \[0.954929658551372 \cdot x - 0.12900613773279798 \cdot \left(\left(x \cdot x\right) \cdot x\right)\]
  2. Simplified0.1

    \[\leadsto \color{blue}{0.954929658551372 \cdot x - 0.12900613773279798 \cdot {x}^{3}}\]
  3. Simplified0.1

    \[\leadsto \color{blue}{x \cdot 0.954929658551372 - 0.12900613773279798 \cdot {x}^{3}}\]
  4. Final simplification0.1

    \[\leadsto x \cdot 0.954929658551372 - 0.12900613773279798 \cdot {x}^{3}\]

Reproduce

herbie shell --seed 2021042 
(FPCore (x)
  :name "Rosa's Benchmark"
  :precision binary64
  (- (* 0.954929658551372 x) (* 0.12900613773279798 (* (* x x) x))))