\frac{\sin ky}{\sqrt{{\left(\sin kx\right)}^{2} + {\left(\sin ky\right)}^{2}}} \cdot \sin th\sin ky \cdot \frac{\sin th}{\mathsf{hypot}\left({\left(\sin kx\right)}^{\left(\frac{2}{2}\right)}, {\left(\sin ky\right)}^{\left(\frac{2}{2}\right)}\right)}double f(double kx, double ky, double th) {
double r53399 = ky;
double r53400 = sin(r53399);
double r53401 = kx;
double r53402 = sin(r53401);
double r53403 = 2.0;
double r53404 = pow(r53402, r53403);
double r53405 = pow(r53400, r53403);
double r53406 = r53404 + r53405;
double r53407 = sqrt(r53406);
double r53408 = r53400 / r53407;
double r53409 = th;
double r53410 = sin(r53409);
double r53411 = r53408 * r53410;
return r53411;
}
double f(double kx, double ky, double th) {
double r53412 = ky;
double r53413 = sin(r53412);
double r53414 = th;
double r53415 = sin(r53414);
double r53416 = kx;
double r53417 = sin(r53416);
double r53418 = 2.0;
double r53419 = 2.0;
double r53420 = r53418 / r53419;
double r53421 = pow(r53417, r53420);
double r53422 = pow(r53413, r53420);
double r53423 = hypot(r53421, r53422);
double r53424 = r53415 / r53423;
double r53425 = r53413 * r53424;
return r53425;
}



Bits error versus kx



Bits error versus ky



Bits error versus th
Results
Initial program 13.0
rmApplied sqr-pow13.0
Applied sqr-pow13.0
Applied hypot-def9.1
rmApplied div-inv9.2
Applied associate-*l*9.3
Simplified9.2
Final simplification9.2
herbie shell --seed 2020047 +o rules:numerics
(FPCore (kx ky th)
:name "Toniolo and Linder, Equation (3b), real"
:precision binary64
(* (/ (sin ky) (sqrt (+ (pow (sin kx) 2) (pow (sin ky) 2)))) (sin th)))