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

LineSearchNocedalWright - NaN in Step 2 (Zooming) #27

Closed
MatthiasJeuthe opened this issue Sep 9, 2022 · 1 comment
Closed

LineSearchNocedalWright - NaN in Step 2 (Zooming) #27

MatthiasJeuthe opened this issue Sep 9, 2022 · 1 comment

Comments

@MatthiasJeuthe
Copy link

In LineSearchNocedalWright.h (line 145, 146):
step = (fx_hi - fx_lo) * step_lo - (step_hi * step_hi - step_lo * step_lo) * dg_lo / 2;
step /= (fx_hi - fx_lo) - (step_hi - step_lo) * dg_lo;

Step is not checked against division by zero.

@yixuan
Copy link
Owner

yixuan commented Apr 19, 2023

This has been fixed in 76ac83f.

@yixuan yixuan closed this as completed Apr 19, 2023
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

No branches or pull requests

2 participants