Changed alpha_init initialization to avoid infinite loop with 0 starting
value.
This commit is contained in:
committed by
Axel Kohlmeyer
parent
874f5577d4
commit
411574a39c
@ -690,7 +690,7 @@ int MinLineSearch::linemin_forcezero(double eoriginal, double &alpha)
|
||||
// choosing the initial alpha that we'll use
|
||||
// rough estimate that'll decrease energy to 1/10
|
||||
|
||||
alpha_init = 0.1*fabs(eoriginal)/fdothall;
|
||||
alpha_init = MAX(EPS_QUAD, 0.1*fabs(eoriginal)/fdothall);
|
||||
|
||||
// initialize aplha to 0.0
|
||||
|
||||
|
||||
Reference in New Issue
Block a user