Initial program 0.1
\[\left(a - \frac{1}{3}\right) \cdot \left(1 + \frac{1}{\sqrt{9 \cdot \left(a - \frac{1}{3}\right)}} \cdot rand\right)
\]
Taylor expanded in rand around 0 0.2
\[\leadsto \color{blue}{\left(0.3333333333333333 \cdot \left(\sqrt{a - 0.3333333333333333} \cdot rand\right) + a\right) - 0.3333333333333333}
\]
Simplified0.1
\[\leadsto \color{blue}{\mathsf{fma}\left(\sqrt{a + -0.3333333333333333}, 0.3333333333333333 \cdot rand, a + -0.3333333333333333\right)}
\]
Proof
(fma.f64 (sqrt.f64 (+.f64 a -1/3)) (*.f64 1/3 rand) (+.f64 a -1/3)): 0 points increase in error, 0 points decrease in error
(fma.f64 (sqrt.f64 (+.f64 a (Rewrite<= metadata-eval (neg.f64 1/3)))) (*.f64 1/3 rand) (+.f64 a -1/3)): 0 points increase in error, 0 points decrease in error
(fma.f64 (sqrt.f64 (Rewrite<= sub-neg_binary64 (-.f64 a 1/3))) (*.f64 1/3 rand) (+.f64 a -1/3)): 0 points increase in error, 0 points decrease in error
(fma.f64 (sqrt.f64 (-.f64 a 1/3)) (*.f64 1/3 rand) (+.f64 a (Rewrite<= metadata-eval (neg.f64 1/3)))): 0 points increase in error, 0 points decrease in error
(fma.f64 (sqrt.f64 (-.f64 a 1/3)) (*.f64 1/3 rand) (Rewrite<= sub-neg_binary64 (-.f64 a 1/3))): 0 points increase in error, 0 points decrease in error
(Rewrite<= fma-def_binary64 (+.f64 (*.f64 (sqrt.f64 (-.f64 a 1/3)) (*.f64 1/3 rand)) (-.f64 a 1/3))): 2 points increase in error, 1 points decrease in error
(+.f64 (*.f64 (sqrt.f64 (-.f64 a 1/3)) (Rewrite=> *-commutative_binary64 (*.f64 rand 1/3))) (-.f64 a 1/3)): 0 points increase in error, 0 points decrease in error
(+.f64 (Rewrite<= associate-*l*_binary64 (*.f64 (*.f64 (sqrt.f64 (-.f64 a 1/3)) rand) 1/3)) (-.f64 a 1/3)): 9 points increase in error, 4 points decrease in error
(+.f64 (Rewrite<= *-commutative_binary64 (*.f64 1/3 (*.f64 (sqrt.f64 (-.f64 a 1/3)) rand))) (-.f64 a 1/3)): 0 points increase in error, 0 points decrease in error
(Rewrite<= associate--l+_binary64 (-.f64 (+.f64 (*.f64 1/3 (*.f64 (sqrt.f64 (-.f64 a 1/3)) rand)) a) 1/3)): 0 points increase in error, 0 points decrease in error
Final simplification0.1
\[\leadsto \mathsf{fma}\left(\sqrt{a + -0.3333333333333333}, 0.3333333333333333 \cdot rand, a + -0.3333333333333333\right)
\]