\sin^{-1} \left(\mathsf{hypot}\left(\mathsf{hypot}\left(X \cdot \sin \left(\frac{a}{2}\right), Y \cdot \sin \left(\frac{a}{2}\right)\right), Z \cdot \sin \left(\frac{a}{2}\right)\right)\right)\sin^{-1} \left(\mathsf{hypot}\left(\mathsf{hypot}\left(X \cdot \sin \left(\frac{a}{2}\right), Y \cdot \sin \left(\frac{a}{2}\right)\right), Z \cdot \sin \left(\frac{a}{2}\right)\right)\right)double code(double X, double a, double Y, double Z) {
return ((double) asin(((double) hypot(((double) hypot(((double) (X * ((double) sin(((double) (a / 2.0)))))), ((double) (Y * ((double) sin(((double) (a / 2.0)))))))), ((double) (Z * ((double) sin(((double) (a / 2.0))))))))));
}
double code(double X, double a, double Y, double Z) {
return ((double) asin(((double) hypot(((double) hypot(((double) (X * ((double) sin(((double) (a / 2.0)))))), ((double) (Y * ((double) sin(((double) (a / 2.0)))))))), ((double) (Z * ((double) sin(((double) (a / 2.0))))))))));
}



Bits error versus X



Bits error versus a



Bits error versus Y



Bits error versus Z
Results
Initial program 0.1
Final simplification0.1
herbie shell --seed 2020153
(FPCore (X a Y Z)
:name "(asin (hypot (hypot (* X (sin (/ a 2))) (* Y (sin (/ a 2)))) (* Z (sin (/ a 2)))))"
:precision binary64
(asin (hypot (hypot (* X (sin (/ a 2.0))) (* Y (sin (/ a 2.0)))) (* Z (sin (/ a 2.0))))))