Input-checking inverse sine. Clamps the input to the domain of acos [-1..1] before evaluating, instead of returning a silent NaN like java.lang.Math.asin. Useful when there's a fear of rounding errors pushing the arg beyond 1 or -1.
(double sin_theta)
| 59 | * rounding errors pushing the arg beyond 1 or -1. |
| 60 | */ |
| 61 | public static final double asin(double sin_theta) { |
| 62 | return Math.asin(clamp(sin_theta, -1.0, 1.0)); |
| 63 | } |
| 64 | |
| 65 | /** |
| 66 | * a sign safe version of pow, _always_ monotically increasing for positive pow |
no test coverage detected