Average Error: 21.5 → 0.3
Time: 11.7s
Precision: 64
Internal Precision: 832
$x \cdot \left(1 - \sqrt{1 - 0.6 \cdot x}\right)$
$\begin{array}{l} \mathbf{if}\;x \le -0.00020712147214625587:\\ \;\;\;\;x + \sqrt{1 - 0.6 \cdot x} \cdot \left(-x\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(0.0135 \cdot \left(x \cdot x\right) + \left(x \cdot 0.045 + 0.3\right)\right) \cdot x\right) \cdot x\\ \end{array}$

# Try it out

Results

 In Out
Enter valid numbers for all inputs

# Derivation

1. Split input into 2 regimes
2. ## if x < -0.00020712147214625587

1. Initial program 0.4

$x \cdot \left(1 - \sqrt{1 - 0.6 \cdot x}\right)$
2. Using strategy rm
3. Applied sub-neg0.4

$\leadsto x \cdot \color{blue}{\left(1 + \left(-\sqrt{1 - 0.6 \cdot x}\right)\right)}$
4. Applied distribute-lft-in0.4

$\leadsto \color{blue}{x \cdot 1 + x \cdot \left(-\sqrt{1 - 0.6 \cdot x}\right)}$

## if -0.00020712147214625587 < x

1. Initial program 28.8

$x \cdot \left(1 - \sqrt{1 - 0.6 \cdot x}\right)$
2. Taylor expanded around 0 0.3

$\leadsto x \cdot \color{blue}{\left(0.0135 \cdot {x}^{3} + \left(0.045 \cdot {x}^{2} + 0.3 \cdot x\right)\right)}$
3. Simplified0.3

$\leadsto x \cdot \color{blue}{\left(\left(\left(x \cdot x\right) \cdot 0.0135 + \left(0.3 + 0.045 \cdot x\right)\right) \cdot x\right)}$
3. Recombined 2 regimes into one program.
4. Final simplification0.3

$\leadsto \begin{array}{l} \mathbf{if}\;x \le -0.00020712147214625587:\\ \;\;\;\;x + \sqrt{1 - 0.6 \cdot x} \cdot \left(-x\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(0.0135 \cdot \left(x \cdot x\right) + \left(x \cdot 0.045 + 0.3\right)\right) \cdot x\right) \cdot x\\ \end{array}$

# Runtime

Time bar (total: 11.7s)Debug log

herbie shell --seed '#(2775764126 3555076145 3898259844 1891440260 2599947619 1948460636)'
(FPCore (x)
:name "x * (1 - sqrt(1-0.6*x))"
(* x (- 1 (sqrt (- 1 (* 0.6 x))))))