Caribou
|
This class implements a generic Newton-Raphson solver for SOFA.
Let be a non-linear function. This component will try to solve
using the following iterative method:
where is the vector evaluated at the time step and Newton iteration . is the jacobian of , and is defined as
#include <NewtonRaphsonSolver.h>
Public Types | |
template<typename T > | |
using | Data = sofa::core::objectmodel::Data< T > |
template<typename T > | |
using | Link = sofa::core::objectmodel::SingleLink< NewtonRaphsonSolver, T, sofa::core::objectmodel::BaseLink::FLAG_STRONGLINK > |
Public Member Functions | |
SOFA_CLASS (NewtonRaphsonSolver, sofa::core::behavior::OdeSolver) | |
void | init () override |
void | solve (const sofa::core::ExecParams *params, SReal dt, sofa::core::MultiVecCoordId x_id, sofa::core::MultiVecDerivId v_id) override |
auto | iteration_times () const -> const std::vector< UNSIGNED_INTEGER_TYPE > & |
List of times (in nanoseconds) that each Newton-Raphson iteration took to compute in the last call to Solve(). | |
auto | squared_residuals () const -> const std::vector< FLOATING_POINT_TYPE > & |
The list of squared residual norms (||r||^2) of every newton iterations of the last solve call. | |
auto | squared_initial_residual () const -> const FLOATING_POINT_TYPE & |
The initial squared residual (||r0||^2) of the last solve call. | |