SIMLIB/C++ 3.09
Loading...
Searching...
No Matches
simlib3::MultiStepMethod Class Reference

base for multi-step integration method More...

#include <simlib.h>

Inheritance diagram for simlib3::MultiStepMethod:
Collaboration diagram for simlib3::MultiStepMethod:

Public Member Functions

 MultiStepMethod (const char *name, const char *slave_name)
 initialize multistep method
 ~MultiStepMethod ()
 free dynamic data
virtual bool IsSingleStep (void) override
virtual void SetStarter (const char *slave_name)
 set starting method for the multi-step method
virtual bool PrepareStep (void) override
 prepare the object for the step of integration
virtual void TurnOff (void) override
 turn off integration method and its slave (starter)
Public Member Functions inherited from simlib3::IntegrationMethod
 IntegrationMethod (const char *name)
 register method to list of methods and name it
virtual ~IntegrationMethod ()
 destroy integration method (remove from list)
virtual void Integrate (void)=0
virtual void Resize (size_t size)
 resize all the memories to the given size

Static Public Member Functions

static void SetStarter (const char *name, const char *slave_name)
 set starting method for given multi-step method
static const char * GetStarter (const char *name)
 obtain the name of the starting method of given method
Static Public Member Functions inherited from simlib3::IntegrationMethod
static void StepSim (void)
 step of numerical integration method
static void IntegrationDone (void)
static void SetMethod (const char *name)
 set method which will be used
static const char * GetMethod (void)
static void InitStep (double step_frag)
 initialize step
static void FunCall (double step_frag)
static void SetOptStep (double opt_step)
static void SetStepSize (double step_size)
static bool IsConditionFlag (void)
static int GetErrNo (void)
static void SetErrNo (int num)

Protected Member Functions

SingleStepMethod * SlavePtr (void)
 return pointer to the starting method (initialize it also)

Private Attributes

char * SlaveName
SingleStepMethod * Slave_Ptr

Additional Inherited Members

Protected Types inherited from simlib3::IntegrationMethod
typedef IntegratorContainer::iterator Iterator
Static Protected Member Functions inherited from simlib3::IntegrationMethod
static Iterator FirstIntegrator (void)
static Iterator LastIntegrator (void)
static bool StateCond (void)
 check on changes of state conditions
static IntegrationMethod * SearchMethod (const char *name)
 search method in the list of registrated methods
Static Protected Attributes inherited from simlib3::IntegrationMethod
static bool IsEndStepEvent =false

Detailed Description

base for multi-step integration method

Definition at line 1167 of file simlib.h.

Constructor & Destructor Documentation

◆ MultiStepMethod()

simlib3::MultiStepMethod::MultiStepMethod ( const char * name,
const char * slave_name )

initialize multistep method

Definition at line 410 of file numint.cc.

References Dprintf, simlib3::IntegrationMethod::IntegrationMethod(), Slave_Ptr, and SlaveName.

Referenced by simlib3::ABM4::ABM4(), GetStarter(), and SetStarter().

◆ ~MultiStepMethod()

simlib3::MultiStepMethod::~MultiStepMethod ( )

free dynamic data

Definition at line 426 of file numint.cc.

References Dprintf, and SlaveName.

Member Function Documentation

◆ GetStarter()

const char * simlib3::MultiStepMethod::GetStarter ( const char * name)
static

obtain the name of the starting method of given method

Definition at line 503 of file numint.cc.

References Dprintf, MultiStepMethod(), simlib3::IntegrationMethod::SearchMethod(), and SlaveName.

Referenced by simlib3::GetStarter(), and simlib3::GetStarter().

◆ IsSingleStep()

virtual bool simlib3::MultiStepMethod::IsSingleStep ( void )
inlineoverridevirtual

Implements simlib3::IntegrationMethod.

Definition at line 1177 of file simlib.h.

◆ PrepareStep()

bool simlib3::MultiStepMethod::PrepareStep ( void )
overridevirtual

prepare the object for the step of integration

Reimplemented from simlib3::IntegrationMethod.

Reimplemented in simlib3::ABM4.

Definition at line 449 of file numint.cc.

References Dprintf, simlib3::IntegrationMethod::PrepareStep(), simlib3::SingleStepMethod::SetStartMode(), and SlavePtr().

Referenced by simlib3::ABM4::PrepareStep().

◆ SetStarter() [1/2]

void simlib3::MultiStepMethod::SetStarter ( const char * name,
const char * slave_name )
static

set starting method for given multi-step method

Definition at line 474 of file numint.cc.

References Dprintf, MultiStepMethod(), simlib3::NI_NotMultiStep, simlib3::IntegrationMethod::SearchMethod(), SetStarter(), and simlib3::SIMLIB_error().

Referenced by SetStarter(), simlib3::SetStarter(), and simlib3::SetStarter().

◆ SetStarter() [2/2]

void simlib3::MultiStepMethod::SetStarter ( const char * slave_name)
virtual

set starting method for the multi-step method

Definition at line 487 of file numint.cc.

References Dprintf, simlib3::NI_CantSetStarter, simlib3::SIMLIB_DynamicFlag, simlib3::SIMLIB_error(), Slave_Ptr, and SlaveName.

◆ SlavePtr()

SingleStepMethod * simlib3::MultiStepMethod::SlavePtr ( void )
protected

return pointer to the starting method (initialize it also)

Definition at line 435 of file numint.cc.

References simlib3::NI_NotSingleStep, simlib3::IntegrationMethod::SearchMethod(), simlib3::SIMLIB_error(), Slave_Ptr, and SlaveName.

Referenced by simlib3::ABM4::Integrate(), PrepareStep(), and TurnOff().

◆ TurnOff()

void simlib3::MultiStepMethod::TurnOff ( void )
overridevirtual

turn off integration method and its slave (starter)

Reimplemented from simlib3::IntegrationMethod.

Definition at line 463 of file numint.cc.

References Dprintf, simlib3::SingleStepMethod::SetStartMode(), SlavePtr(), and simlib3::IntegrationMethod::TurnOff().

Member Data Documentation

◆ Slave_Ptr

SingleStepMethod* simlib3::MultiStepMethod::Slave_Ptr
private

Definition at line 1170 of file simlib.h.

Referenced by MultiStepMethod(), SetStarter(), and SlavePtr().

◆ SlaveName

char* simlib3::MultiStepMethod::SlaveName
private

Definition at line 1169 of file simlib.h.

Referenced by GetStarter(), MultiStepMethod(), SetStarter(), SlavePtr(), and ~MultiStepMethod().


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