Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

powf returns NaN for small bases #2

Open
mb64 opened this issue Jul 10, 2018 · 0 comments · May be fixed by #3
Open

powf returns NaN for small bases #2

mb64 opened this issue Jul 10, 2018 · 0 comments · May be fixed by #3

Comments

@mb64
Copy link

mb64 commented Jul 10, 2018

When trying to port palette to support #[no_std], its extensive tests found some scenarios where mish functions returned NaN.

powf returns NaN fairly consistently, no matter the exponent, for bases smaller than 0.08518821616297091.

Ex:

extern crate mish;
for &power in [0.00001, 0.3, 0.9999, 1.0, 2.0, 10000.0].iter() {
    assert!(mish::pow::<f64>(0.085, power).is_nan());
}
@mb64 mb64 linked a pull request Jul 10, 2018 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant