The specialized Stepper to compute a step with the Newton-Raphson method.
More...
#include <stepper_def.hpp>
|
| | NewtonRaphsonStepper (std::function< double(double)> fun, bool aitken_mode, std::function< double(double)> der) |
| | The specialized constructor - initializes the function and the derivative.
|
| |
| Eigen::Vector2d | compute_step (Eigen::Vector2d previous_iteration) override |
| | Specialized method to compute and return a new step with NR.
|
| |
| | NewtonRaphsonStepper (std::function< double(double)> fun, bool aitken_mode, std::function< double(double)> der) |
| |
| Eigen::Vector2d | compute_step (Eigen::Vector2d previous_iteration) |
| | Virtual function to compute the step for the method -> overridden by all the methods.
|
| |
| | StepperBase (std::function< double(double)> fun, bool aitken_mode) |
| | Constructor for virtual Stepper class, which will be inherited by the daughters.
|
| |
| virtual | ~StepperBase ()=default |
| |
| Eigen::Vector2d | step (Eigen::Vector2d previous_step) |
| | Method handling all the steps involved in computing the new guess.
|
| |
|
| std::function< double(double)> | derivative |
| | Stores the derivative of the function.
|
| |
|
| Eigen::Vector2d | aitken_step (Eigen::Vector2d previous_iter) |
| | Method to handle the computation of a step using Aitken's acceleration.
|
| |
| std::function< double(double)> | function |
| | Function to compute the root of.
|
| |
| bool | aitken_requirement |
| | Option to use Aitken's acceleration.
|
| |
template<typename T>
class NewtonRaphsonStepper< T >
The specialized Stepper to compute a step with the Newton-Raphson method.
◆ NewtonRaphsonStepper() [1/2]
The specialized constructor - initializes the function and the derivative.
- Parameters
-
| fun | The function to compute the root of |
| aitken_mode | Option to use Aitken's acceleration |
| der | The derivative of the function, needed for NR method |
◆ NewtonRaphsonStepper() [2/2]
◆ compute_step() [1/2]
Virtual function to compute the step for the method -> overridden by all the methods.
- Parameters
-
| previous_iteration | 2-dimensional vector storing x(i-1) and f(x(i-1)) - previous guesses |
- Returns
- 2-dimensional vector storing x(i) and f(x(i)) - new guesses
Implements StepperBase< T >.
◆ compute_step() [2/2]
Specialized method to compute and return a new step with NR.
- Parameters
-
| previous_iteration | 2-dimensional vector storing x(i-1) and f(x(i-1)) - previous guesses |
- Returns
- 2-dimensional vector storing x(i) = x(i-1) - f(x(i-1)) / f'(x(i-1)) and f(x(i)) - new guesses
Implements StepperBase< T >.
◆ derivative
Stores the derivative of the function.
The documentation for this class was generated from the following file: