#include <SteepestDescent.hpp>
Public Member Functions | |
SteepestDescent (DifferentiableEnergyInterface &energy, float_t min_gradient_norm, float_t step_size) | |
bool | minimize (size_t n_max_steps, size_t &n_actual_steps) |
Minimizes a given energy which is initialized to a vector by iteratively computing
for a step size .
imaging::SteepestDescent::SteepestDescent | ( | DifferentiableEnergyInterface & | energy, | |
float_t | min_gradient_norm, | |||
float_t | step_size | |||
) |
Construct a SteepestDescent object to minimize energy. If the L2-norm of the gradient of the functional falls below min_gradient_norm the algorithm stops. The parameter step_size refers to the step size . To actually start the minimization the user must call minimize().
Start the minimization process. At most n_max_steps will be performed. If the convergence criterion (as set in the constructor) is met before the number of maximal steps is reached the function returns true. Otherwise it returns false. The actual number of performed stops is stored in n_steps. Upon return, the energy (as set in the constructor) will have the solution as its current argument.
Implements imaging::MinimizerInterface.
References imaging::EnergyInterface::current_argument(), imaging::EnergyInterface::current_energy(), imaging::DifferentiableEnergyInterface::current_gradient(), imaging::MessageInterface::DEBUG_ONLY, imaging::MessageInterface::out, and imaging::DifferentiableEnergyInterface::set_argument_with_gradient().