BioCMAMC-ST
Simulation::SimulationUnit Class Reference

#include <simulation.hpp>

Collaboration diagram for Simulation::SimulationUnit:
[legend]

Public Member Functions

 SimulationUnit (std::unique_ptr< MC::MonteCarloUnit > &&_unit, const ScalarInitializer &scalar_init, std::optional< Feed::SimulationFeed > _feed=std::nullopt)
 
 ~SimulationUnit ()
 
 SimulationUnit (SimulationUnit &&other) noexcept
 
 SimulationUnit (const SimulationUnit &other)=delete
 
SimulationUnitoperator= (SimulationUnit &&rhs)=delete
 
SimulationUnitoperator= (const SimulationUnit &rhs)=delete
 
Kokkos::View< const double **, Kokkos::LayoutLeft, ComputeSpace, Kokkos::MemoryTraits< Kokkos::RandomAccess > > getkernel_concentration () const
 
std::span< double > getCliqData () const
 
std::optional< std::span< const double > > getCgasData () const
 
std::optional< std::span< const double > > getMTRData () const
 
Dimensions getDimensions () const noexcept
 
std::span< const double > getContributionData () const
 
std::span< double > getContributionData_mut ()
 
const Simulation::Feed::SimulationFeedget_feed () const
 
ProbeAutogeneratedBufferget_probes ()
 
void set_probes (ProbeAutogeneratedBuffer &&_probes)
 
void cycleProcess (auto &&container, double d_t)
 
void step (double d_t) const
 
void reduceContribs (std::span< const double > data, size_t n_rank) const
 
void reduceContribs_per_rank (std::span< const double > data) const
 
void clearContribution () const noexcept
 
void update_feed (double t, double d_t, bool update_scalar=true) noexcept
 
bool two_phase_flow () const
 
std::size_t counter () const
 
double & get_start_time_mut ()
 
double & get_end_time_mut ()
 
void update (CmaUtils::IterationState &&new_state)
 
const CmaUtils::IterationStateget_state () const
 
void clear_mc ()
 
void reset ()
 
void post_init_compartments ()
 

Public Attributes

std::unique_ptr< MC::MonteCarloUnitmc_unit
 

Private Member Functions

void setVolumes () const
 
void setLiquidFlow (CmaUtils::PreCalculatedHydroState *_flows_l)
 
void setGasFlow (CmaUtils::PreCalculatedHydroState *_flows_g)
 
DiagonalView< ComputeSpace > get_kernel_diagonal () const
 
CumulativeProbabilityView< ComputeSpace > get_kernel_cumulative_proba () const
 
kernelContribution get_kernel_contribution () const
 
void set_kernel_contribs_to_host ()
 
void post_init_concentration (const ScalarInitializer &scalar_init)
 
void post_init_concentration_functor (const ScalarInitializer &scalar_init)
 
void post_init_concentration_file (const ScalarInitializer &scalar_init)
 

Private Attributes

Kokkos::TeamPolicy< ComputeSpace > _policy
 
bool set_policy = false
 
std::size_t internal_counter_dead
 
ProbeAutogeneratedBuffer probes
 
Simulation::Feed::SimulationFeed feed
 
CmaUtils::IterationState state
 
bool const_number_simulation = true
 
const bool is_two_phase_flow
 
double starting_time = 0.
 
double end_time {}
 
std::shared_ptr< ScalarSimulationliquid_scalar
 
std::shared_ptr< ScalarSimulationgas_scalar
 
MassTransfer::MassTransferModel mt_model
 
KernelInline::MoveInfo< ComputeSpace > move_info
 

Constructor & Destructor Documentation

◆ SimulationUnit() [1/3]

Simulation::SimulationUnit::SimulationUnit ( std::unique_ptr< MC::MonteCarloUnit > && _unit,
const ScalarInitializer & scalar_init,
std::optional< Feed::SimulationFeed > _feed = std::nullopt )
Here is the call graph for this function:

◆ ~SimulationUnit()

Simulation::SimulationUnit::~SimulationUnit ( )
default

◆ SimulationUnit() [2/3]

Simulation::SimulationUnit::SimulationUnit ( SimulationUnit && other)
defaultnoexcept

◆ SimulationUnit() [3/3]

Simulation::SimulationUnit::SimulationUnit ( const SimulationUnit & other)
delete

Member Function Documentation

◆ clear_mc()

void Simulation::SimulationUnit::clear_mc ( )

◆ clearContribution()

void Simulation::SimulationUnit::clearContribution ( ) const
noexcept

◆ counter()

std::size_t Simulation::SimulationUnit::counter ( ) const
nodiscard

◆ cycleProcess()

void Simulation::SimulationUnit::cycleProcess ( auto && container,
double d_t )
Here is the call graph for this function:

◆ get_end_time_mut()

double & Simulation::SimulationUnit::get_end_time_mut ( )
nodiscard

◆ get_feed()

const Simulation::Feed::SimulationFeed & Simulation::SimulationUnit::get_feed ( ) const
nodiscard

◆ get_kernel_contribution()

kernelContribution Simulation::SimulationUnit::get_kernel_contribution ( ) const
nodiscardprivate
Here is the caller graph for this function:

◆ get_kernel_cumulative_proba()

CumulativeProbabilityView< ComputeSpace > Simulation::SimulationUnit::get_kernel_cumulative_proba ( ) const
private
Here is the caller graph for this function:

◆ get_kernel_diagonal()

DiagonalView< ComputeSpace > Simulation::SimulationUnit::get_kernel_diagonal ( ) const
nodiscardprivate
Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_probes()

ProbeAutogeneratedBuffer & Simulation::SimulationUnit::get_probes ( )
inline
Here is the caller graph for this function:

◆ get_start_time_mut()

double & Simulation::SimulationUnit::get_start_time_mut ( )
nodiscard

◆ get_state()

const CmaUtils::IterationState & Simulation::SimulationUnit::get_state ( ) const
inline

◆ getCgasData()

std::optional< std::span< const double > > Simulation::SimulationUnit::getCgasData ( ) const
nodiscard
Here is the caller graph for this function:

◆ getCliqData()

std::span< double > Simulation::SimulationUnit::getCliqData ( ) const
nodiscard
Here is the caller graph for this function:

◆ getContributionData()

std::span< const double > Simulation::SimulationUnit::getContributionData ( ) const
nodiscard

◆ getContributionData_mut()

std::span< double > Simulation::SimulationUnit::getContributionData_mut ( )

◆ getDimensions()

Dimensions Simulation::SimulationUnit::getDimensions ( ) const
nodiscardnoexcept
Here is the caller graph for this function:

◆ getkernel_concentration()

Kokkos::View< const double **, Kokkos::LayoutLeft, ComputeSpace, Kokkos::MemoryTraits< Kokkos::RandomAccess > > Simulation::SimulationUnit::getkernel_concentration ( ) const
nodiscard
Here is the caller graph for this function:

◆ getMTRData()

std::optional< std::span< const double > > Simulation::SimulationUnit::getMTRData ( ) const
nodiscard
Here is the call graph for this function:

◆ operator=() [1/2]

SimulationUnit & Simulation::SimulationUnit::operator= ( const SimulationUnit & rhs)
delete

◆ operator=() [2/2]

SimulationUnit & Simulation::SimulationUnit::operator= ( SimulationUnit && rhs)
delete

◆ post_init_compartments()

void Simulation::SimulationUnit::post_init_compartments ( )
Here is the caller graph for this function:

◆ post_init_concentration()

void Simulation::SimulationUnit::post_init_concentration ( const ScalarInitializer & scalar_init)
private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ post_init_concentration_file()

void Simulation::SimulationUnit::post_init_concentration_file ( const ScalarInitializer & scalar_init)
private
Here is the caller graph for this function:

◆ post_init_concentration_functor()

void Simulation::SimulationUnit::post_init_concentration_functor ( const ScalarInitializer & scalar_init)
private
Here is the caller graph for this function:

◆ reduceContribs()

void Simulation::SimulationUnit::reduceContribs ( std::span< const double > data,
size_t n_rank ) const
Here is the call graph for this function:

◆ reduceContribs_per_rank()

void Simulation::SimulationUnit::reduceContribs_per_rank ( std::span< const double > data) const

◆ reset()

void Simulation::SimulationUnit::reset ( )

◆ set_kernel_contribs_to_host()

void Simulation::SimulationUnit::set_kernel_contribs_to_host ( )
private
Here is the caller graph for this function:

◆ set_probes()

void Simulation::SimulationUnit::set_probes ( ProbeAutogeneratedBuffer && _probes)

◆ setGasFlow()

void Simulation::SimulationUnit::setGasFlow ( CmaUtils::PreCalculatedHydroState * _flows_g)
private

◆ setLiquidFlow()

void Simulation::SimulationUnit::setLiquidFlow ( CmaUtils::PreCalculatedHydroState * _flows_l)
private

◆ setVolumes()

void Simulation::SimulationUnit::setVolumes ( ) const
private
Here is the caller graph for this function:

◆ step()

void Simulation::SimulationUnit::step ( double d_t) const
Here is the call graph for this function:

◆ two_phase_flow()

bool Simulation::SimulationUnit::two_phase_flow ( ) const
nodiscard

◆ update()

void Simulation::SimulationUnit::update ( CmaUtils::IterationState && new_state)
Here is the call graph for this function:

◆ update_feed()

void Simulation::SimulationUnit::update_feed ( double t,
double d_t,
bool update_scalar = true )
noexcept

Member Data Documentation

◆ _policy

Kokkos::TeamPolicy<ComputeSpace> Simulation::SimulationUnit::_policy
private

◆ const_number_simulation

bool Simulation::SimulationUnit::const_number_simulation = true
private

◆ end_time

double Simulation::SimulationUnit::end_time {}
private

◆ feed

Simulation::Feed::SimulationFeed Simulation::SimulationUnit::feed
private

◆ gas_scalar

std::shared_ptr<ScalarSimulation> Simulation::SimulationUnit::gas_scalar
private

◆ internal_counter_dead

std::size_t Simulation::SimulationUnit::internal_counter_dead
private

◆ is_two_phase_flow

const bool Simulation::SimulationUnit::is_two_phase_flow
private

◆ liquid_scalar

std::shared_ptr<ScalarSimulation> Simulation::SimulationUnit::liquid_scalar
private

◆ mc_unit

std::unique_ptr<MC::MonteCarloUnit> Simulation::SimulationUnit::mc_unit

◆ move_info

KernelInline::MoveInfo<ComputeSpace> Simulation::SimulationUnit::move_info
private

◆ mt_model

MassTransfer::MassTransferModel Simulation::SimulationUnit::mt_model
private

◆ probes

ProbeAutogeneratedBuffer Simulation::SimulationUnit::probes
private

◆ set_policy

bool Simulation::SimulationUnit::set_policy = false
private

◆ starting_time

double Simulation::SimulationUnit::starting_time = 0.
private

◆ state

CmaUtils::IterationState Simulation::SimulationUnit::state
private

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