version 0.4.4
Ikarus::PathFollowing< NLS, PF, ASS > Class Template Reference

The PathFollowing control routine for path-following analysis. More...

#include <ikarus/controlroutines/pathfollowing.hh>

Inheritance diagram for Ikarus::PathFollowing< NLS, PF, ASS >:
[legend]

Public Types

using State = PathFollowingStateType< NLS::DifferentiableFunction >
 
using MessageType = ControlMessages
 
using Callback = std::function< void(ControlMessages, const State &)>
 
using Token = std::shared_ptr< Callback >
 

Public Member Functions

constexpr auto name () const
 The name of the PathFollowing method. More...
 
 PathFollowing (const std::shared_ptr< NLS > &nls, int steps, double stepSize, PF pathFollowingType=ArcLength{}, ASS adaptiveStepSizing={})
 Constructor for PathFollowing. More...
 
ControlInformation run (typename NLS::Domain &d)
 Executes the PathFollowing routine. More...
 
NLS & nonLinearSolver ()
 
Token registerListener (Callback callback)
 This method is used to register a Listener function. More...
 
void unregisterListener (Token token)
 deregisters a specific function More...
 
void notify (ControlMessages message, const State &data)
 This calls all the registered functions. More...
 

Detailed Description

template<typename NLS, typename PF = ArcLength, typename ASS = AdaptiveStepSizing::NoOp>
requires (Impl::checkPathFollowingTemplates<NLS, PF, ASS>())
class Ikarus::PathFollowing< NLS, PF, ASS >

This class represents the PathFollowing control routine, which utilizes a nonlinear solver, such as Newton's method with scalar subsidiary function, which has to be fulfilled for solving the system along a predefined path.

Consider a non-linear system of equations

\[\mathbf{R}: \require{cases}\begin{cases}\mathbb{R}^n \times \mathbb{R} &\rightarrow \mathbb{R}^n \\ (\mathbf{D},\lambda) &\mapsto \mathbf{R}(\mathbf{D},\lambda) \end{cases}.\]

Then in each step \(k+1\) of the path following algorithm, the following problem is solved

\[ \begin{align} \mathbf{R}(\mathbf{D}_k+ \mathrm{D}\mathbf{D}, \lambda_k+ \mathrm{D} \lambda) &= \mathbf{0} \\ f(\mathrm{D}\mathbf{D}, \mathrm{D} \lambda) &= 0 \end{align} \]

where \(\mathrm{D}\mathbf{D}\) is the increment of the solution vector and \(\mathrm{D} \lambda\) is the load factor increment. The subsidiary function \(f\) is provided by the user and needs to fulfill the concept Concepts::PathFollowingStrategy. This subsidiary function makes the given problem well-posed.

Currently the following subsidiary functions are implemented LoadControlSubsidiaryFunction, ArcLength and DisplacementControl

Template Parameters
NLSType of the nonlinear solver used in the control routine.
PFType of the path-following strategy.
ASSType of the adaptive step sizing strategy.

Member Typedef Documentation

◆ Callback

using Ikarus::Broadcaster< ControlMessages , PathFollowingStateType< NLS::DifferentiableFunction > >::Callback = std::function<void(ControlMessages , const State&)>
inherited

◆ MessageType

using Ikarus::Broadcaster< ControlMessages , PathFollowingStateType< NLS::DifferentiableFunction > >::MessageType = ControlMessages
inherited

◆ State

using Ikarus::ControlRoutineBase< NLS::DifferentiableFunction , PathFollowingStateType< NLS::DifferentiableFunction > , Args >::State = PathFollowingStateType< NLS::DifferentiableFunction >
inherited

◆ Token

using Ikarus::Broadcaster< ControlMessages , PathFollowingStateType< NLS::DifferentiableFunction > >::Token = std::shared_ptr<Callback>
inherited

Constructor & Destructor Documentation

◆ PathFollowing()

template<typename NLS , typename PF = ArcLength, typename ASS = AdaptiveStepSizing::NoOp>
Ikarus::PathFollowing< NLS, PF, ASS >::PathFollowing ( const std::shared_ptr< NLS > &  nls,
int  steps,
double  stepSize,
PF  pathFollowingType = ArcLength{},
ASS  adaptiveStepSizing = {} 
)
inline
Parameters
nlsThe non linear solver.
stepsNumber of steps in the control routine.
stepSizeSize of each step.
pathFollowingTypeType of the path-following function.
adaptiveStepSizingType of the adaptive step sizing strategy.

Member Function Documentation

◆ name()

template<typename NLS , typename PF = ArcLength, typename ASS = AdaptiveStepSizing::NoOp>
constexpr auto Ikarus::PathFollowing< NLS, PF, ASS >::name ( ) const
inlineconstexpr

◆ nonLinearSolver()

template<typename NLS , typename PF = ArcLength, typename ASS = AdaptiveStepSizing::NoOp>
NLS & Ikarus::PathFollowing< NLS, PF, ASS >::nonLinearSolver ( )
inline

◆ notify()

void Ikarus::Broadcaster< ControlMessages , PathFollowingStateType< NLS::DifferentiableFunction > >::notify ( ControlMessages  message,
const State data 
)
inlineinherited

◆ registerListener()

Token Ikarus::Broadcaster< ControlMessages , PathFollowingStateType< NLS::DifferentiableFunction > >::registerListener ( Callback  callback)
inlineinherited

The function that is passed in is first stored in a shared_ptr. After this, the shared_ptr is added to the vector of listener functions, which leads to a implicit conversion to a weak_ptr. The shared_ptr is then returned to the Listener that has called this function to be stored in a vector of shared_ptr<void> listener.hh.

Parameters
callbackthe callback function
Returns
Token

◆ run()

template<typename NLS , typename PF , typename ASS >
requires (Impl::checkPathFollowingTemplates<NLS, PF, ASS>())
ControlInformation Ikarus::PathFollowing< NLS, PF, ASS >::run ( typename NLS::Domain &  d)
  • Parameters
    dThe solution.
    Returns
    ControlInformation structure containing information about the control results.

Calculate predictor for a particular step

◆ unregisterListener()

void Ikarus::Broadcaster< ControlMessages , PathFollowingStateType< NLS::DifferentiableFunction > >::unregisterListener ( Token  token)
inlineinherited

The documentation for this class was generated from the following files: