NetDEM v1.0
Loading...
Searching...
No Matches
netdem::Simulation Class Reference

Class for managing a DEM simulation. More...

#include <simulation.hpp>

Public Member Functions

 Simulation ()
 Constructor for the Simulation class.
 
void Init ()
 Initializes the simulation with default settings.
 
void AutoReadRestart (std::string const &path, int mech_cyc, int shape_info_case=0)
 Restarts the simulation using output files.
 
void SetTimeAndCycles (double t, int cycs)
 Sets the current time and cycles (usually invoked after AutoReadRestart).
 
void Run (double time)
 Runs the simulation for a specified period of time.
 
 ~Simulation ()
 Destructor for the Simulation class.
 

Public Attributes

InputProcessor input_processor
 Object for processing input commands defined in a JSON file.
 
DomainManager domain_manager
 Manager for domain and sub-domain calculations.
 
MPIManager mpi_manager
 Manages data exchange between sub-domains.
 
Scene scene
 Contains and manages basic DEM objects (e.g., shapes, particles, walls) for a DEM simulation.
 
DEMSolver dem_solver
 Implements DEM algorithms to solve the scene.
 
ModifierManager modifier_manager
 Manages add-on features (i.e., customized evaluations not hard-coded in the DEM calculation cycle).
 
double mech_time {0}
 The mechanical time in the simulation world.
 
int mech_cycles {0}
 The mechanical cycles. Each cycle accounts for a [timestep] time increment of the simulation mechanical time.
 
bool enable_logging {true}
 If true, output log information onto screen.
 

Detailed Description

Constructor & Destructor Documentation

◆ Simulation()

Simulation::Simulation ( )

Constructor for the Simulation class.

◆ ~Simulation()

Simulation::~Simulation ( )

Destructor for the Simulation class.

Member Function Documentation

◆ AutoReadRestart()

void Simulation::AutoReadRestart ( std::string const & path,
int mech_cyc,
int shape_info_case = 0 )

Restarts the simulation using output files.

Parameters
pathPath to the output files.
mech_cycNumber of mechanical cycles.
shape_info_caseShape information case. 0: 0-step json, 2: time-specific json.

◆ Init()

void Simulation::Init ( )

Initializes the simulation with default settings.

◆ Run()

◆ SetTimeAndCycles()

void Simulation::SetTimeAndCycles ( double t,
int cycs )

Sets the current time and cycles (usually invoked after AutoReadRestart).

Parameters
tTime for the simulation.
cycsNumber of cycles for the simulation.

Member Data Documentation

◆ dem_solver

◆ domain_manager

◆ enable_logging

bool netdem::Simulation::enable_logging {true}

If true, output log information onto screen.

Examples
02_energy_test.cpp.

◆ input_processor

InputProcessor netdem::Simulation::input_processor

Object for processing input commands defined in a JSON file.

◆ mech_cycles

int netdem::Simulation::mech_cycles {0}

The mechanical cycles. Each cycle accounts for a [timestep] time increment of the simulation mechanical time.

◆ mech_time

double netdem::Simulation::mech_time {0}

The mechanical time in the simulation world.

◆ modifier_manager

◆ mpi_manager

MPIManager netdem::Simulation::mpi_manager

Manages data exchange between sub-domains.

◆ scene


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