\frac{\sin ky}{\sqrt{{\left(\sin kx\right)}^{2} + {\left(\sin ky\right)}^{2}}} \cdot \sin th\sin th \cdot \frac{\sin ky}{\mathsf{hypot}\left(\sin ky, \sin kx\right)}double f(double kx, double ky, double th) {
double r43142 = ky;
double r43143 = sin(r43142);
double r43144 = kx;
double r43145 = sin(r43144);
double r43146 = 2.0;
double r43147 = pow(r43145, r43146);
double r43148 = pow(r43143, r43146);
double r43149 = r43147 + r43148;
double r43150 = sqrt(r43149);
double r43151 = r43143 / r43150;
double r43152 = th;
double r43153 = sin(r43152);
double r43154 = r43151 * r43153;
return r43154;
}
double f(double kx, double ky, double th) {
double r43155 = th;
double r43156 = sin(r43155);
double r43157 = ky;
double r43158 = sin(r43157);
double r43159 = kx;
double r43160 = sin(r43159);
double r43161 = hypot(r43158, r43160);
double r43162 = r43158 / r43161;
double r43163 = r43156 * r43162;
return r43163;
}



Bits error versus kx



Bits error versus ky



Bits error versus th
Results
Initial program 12.6
Taylor expanded around inf 12.6
Simplified8.7
rmApplied div-inv8.8
rmApplied *-un-lft-identity8.8
Applied associate-*l*8.8
Simplified8.7
Final simplification8.7
herbie shell --seed 2020083 +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)))