Does line search in "fminunc" use the directional derivatives? And can this be turned off?
Mostrar comentarios más antiguos
Hello!
I currently try to solve an unconstrained minimization problem where the objective is computed by simulating the system of interest. During simulation, I also compute the corresponding objective gradient, however, this is more expensive than just computing the objective value.
Currently, I use the following options for "fminunc":
options = optimoptions( 'fminunc', 'GradObj', 'on', 'Display', 'iter', 'Algorithm', 'quasi-newton' );
I tried using "nargsout" to query the number of requested output arguments and only compute the gradient if "nargsout > 1".
However, it seems that the gradient is also required during the line search, and thus, there is no speed up. Is there are way to change this behavior?
Any help is highly appreciated!
Best regards, Stefan
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Solver Outputs and Iterative Display en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!