CellModules
Simu Class Reference

Public Member Functions

 Simu (string params)
 
 Simu (string params, int seed)
 
void update ()
 Updates the simulation by one time step. More...
 
void update (int nbSteps)
 Updates the simulation by multiple time steps. More...
 
int getCurrentStep ()
 Gets the current number of time steps. More...
 
double getTime (char format)
 Gets the elapsed time in a given format. More...
 
vector< PrimoCell< CellBody > * > * _getCells ()
 Gets the cells in the simulation. More...
 

Public Attributes

CellPlugin< PrimoCell< CellBody > > * plugins
 Cell plugins. More...
 

Private Attributes

scenario_t scenario
 

Detailed Description

Simu - Main class of isiCell python wrapper

Parameters

: params : dict | str The simulation parameters in JSON format.

: seed : Optional[int] The seed for the random generators. If not provided, the seed is random.

Attributes

: cells : CellVector provides high-performance access to all cell properties.

it's also an iterator to access each cells.

: plugins : CellPlugin allows access to the plugin part of each module.

Definition at line 29 of file simu.cpp.

Constructor & Destructor Documentation

◆ Simu() [1/2]

Simu::Simu ( string  params)
inline

Definition at line 42 of file simu.cpp.

◆ Simu() [2/2]

Simu::Simu ( string  params,
int  seed 
)
inline

Definition at line 48 of file simu.cpp.

Member Function Documentation

◆ _getCells()

vector< PrimoCell< CellBody > * > * Simu::_getCells ( )
inline

Gets the cells in the simulation.

This method advances the simulation by a single time step.

Definition at line 115 of file simu.cpp.

◆ getCurrentStep()

int Simu::getCurrentStep ( )
inline

Gets the current number of time steps.

Returns
The current number of time steps in the simulation.

Definition at line 82 of file simu.cpp.

◆ getTime()

double Simu::getTime ( char  format)
inline

Gets the elapsed time in a given format.

Parameters
formatThe time format ('d' for days, 'h' for hours, 'm' for minutes, 's' for seconds).
Returns
The elapsed time in the given format.
Exceptions
std::invalid_argumentif the format is invalid.

Definition at line 96 of file simu.cpp.

◆ update() [1/2]

void Simu::update ( )
inline

Updates the simulation by one time step.

This method advances the simulation by a single time step.

Definition at line 61 of file simu.cpp.

◆ update() [2/2]

void Simu::update ( int  nbSteps)
inline

Updates the simulation by multiple time steps.

This method advances the simulation by a given number of time steps.

Parameters
nbStepsThe number of time steps to advance.

Definition at line 72 of file simu.cpp.

Member Data Documentation

◆ plugins

CellPlugin<PrimoCell<CellBody> >* Simu::plugins

Cell plugins.

allows access to the plugin part of each module.

Definition at line 40 of file simu.cpp.

◆ scenario

scenario_t Simu::scenario
private

Definition at line 31 of file simu.cpp.


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