Manages and controls execution of all data/systems in BioGears. More...

#include <BioGears.h>

Inherits Loggable, and LoggerForward.

Inherited by BioGearsEngine.

Public Member Functions

 BioGears (Logger *logger)
 
 BioGears (const std::string &logfileName)
 
virtual ~BioGears ()
 
EngineState GetState ()
 
DataTrackGetDataTrack ()
 
SaturationCalculatorGetSaturationCalculator ()
 
BioGearsSubstancesGetSubstances ()
 
SEPatientGetPatient ()
 
bool GetPatientAssessment (SEPatientAssessment &assessment)
 
SEBloodChemistrySystemGetBloodChemistry ()
 
SECardiovascularSystemGetCardiovascular ()
 
SEDrugSystemGetDrugs ()
 
SEEndocrineSystemGetEndocrine ()
 
SEEnergySystemGetEnergy ()
 
SEGastrointestinalSystemGetGastrointestinal ()
 
SEHepaticSystemGetHepatic ()
 
SENervousSystemGetNervous ()
 
SERenalSystemGetRenal ()
 
SERespiratorySystemGetRespiratory ()
 
SETissueSystemGetTissue ()
 
SEEnvironmentGetEnvironment ()
 
SEAnesthesiaMachineGetAnesthesiaMachine ()
 
SEElectroCardioGramGetECG ()
 
SEInhalerGetInhaler ()
 
SEActionManagerGetActions ()
 
SEConditionManagerGetConditions ()
 
BioGearsCircuitsGetCircuits ()
 
BioGearsCompartmentsGetCompartments ()
 
const BioGearsConfigurationGetConfiguration ()
 
const SEScalarTimeGetEngineTime ()
 
const SEScalarTimeGetSimulationTime ()
 
const SEScalarTimeGetTimeStep ()
 
CDM::enumBioGearsAirwayMode::value GetAirwayMode ()
 
void SetAirwayMode (CDM::enumBioGearsAirwayMode::value mode)
 
CDM::enumOnOff::value GetIntubation ()
 
void SetIntubation (CDM::enumOnOff::value s)
 
bool CreateCircuitsAndCompartments ()
 
- Public Member Functions inherited from Loggable
 Loggable ()
 
 Loggable (Logger *log)
 
virtual ~Loggable ()
 
virtual LoggerGetLogger () const
 

Protected Member Functions

void SetupCardiovascular ()
 
void SetupRenal ()
 
void SetupTissue ()
 
void SetupGastrointestinal ()
 
void SetupRespiratory ()
 
void SetupAnesthesiaMachine ()
 
void SetupInhaler ()
 
void SetupMechanicalVentilator ()
 
void SetupExternalTemperature ()
 
void SetupInternalTemperature ()
 
bool Initialize (const PhysiologyEngineConfiguration *config)
 
bool SetupPatient ()
 
virtual void AtSteadyState (EngineState state)
 
void PreProcess ()
 
void Process ()
 
void PostProcess ()
 
void ForwardFatal (const std::string &msg, const std::string &origin)
 
- Protected Member Functions inherited from Loggable
virtual void Debug (const std::string &msg, const std::string &origin=empty) const
 
virtual void Debug (std::stringstream &msg, const std::string &origin=empty) const
 
virtual void Debug (std::ostream &msg, const std::string &origin=empty) const
 
virtual void Info (const std::string &msg, const std::string &origin=empty) const
 
virtual void Info (std::stringstream &msg, const std::string &origin=empty) const
 
virtual void Info (const std::stringstream &msg, const std::string &origin=empty) const
 
virtual void Info (std::ostream &msg, const std::string &origin=empty) const
 
virtual void Warning (const std::string &msg, const std::string &origin=empty) const
 
virtual void Warning (std::stringstream &msg, const std::string &origin=empty) const
 
virtual void Warning (std::ostream &msg, const std::string &origin=empty) const
 
virtual void Error (const std::string &msg, const std::string &origin=empty) const
 
virtual void Error (std::stringstream &msg, const std::string &origin=empty) const
 
virtual void Error (std::ostream &msg, const std::string &origin=empty) const
 
virtual void Fatal (const std::string &msg, const std::string &origin=empty) const
 
virtual void Fatal (std::stringstream &msg, const std::string &origin=empty) const
 
virtual void Fatal (std::ostream &msg, const std::string &origin=empty) const
 
- Protected Member Functions inherited from LoggerForward
virtual void ForwardDebug (const std::string &msg, const std::string &origin)
 
virtual void ForwardInfo (const std::string &msg, const std::string &origin)
 
virtual void ForwardWarning (const std::string &msg, const std::string &origin)
 
virtual void ForwardError (const std::string &msg, const std::string &origin)
 

Protected Attributes

EngineState m_State
 
DataTrackm_DataTrack
 
std::unique_ptr< SEScalarTimem_CurrentTime
 
std::unique_ptr< SEScalarTimem_SimulationTime
 
CDM::enumBioGearsAirwayMode::value m_AirwayMode
 
CDM::enumOnOff::value m_Intubation
 
std::unique_ptr< BioGearsConfigurationm_Config
 
std::unique_ptr< SaturationCalculatorm_SaturationCalculator
 
std::unique_ptr< BioGearsSubstancesm_Substances
 
std::unique_ptr< SEActionManagerm_Actions
 
std::unique_ptr< SEConditionManagerm_Conditions
 
std::unique_ptr< BioGearsCircuitsm_Circuits
 
std::unique_ptr< BioGearsCompartmentsm_Compartments
 
std::unique_ptr< Environmentm_Environment
 
std::unique_ptr< BloodChemistrym_BloodChemistrySystem
 
std::unique_ptr< Cardiovascularm_CardiovascularSystem
 
std::unique_ptr< Endocrinem_EndocrineSystem
 
std::unique_ptr< Energym_EnergySystem
 
std::unique_ptr< Gastrointestinalm_GastrointestinalSystem
 
std::unique_ptr< Hepaticm_HepaticSystem
 
std::unique_ptr< Nervousm_NervousSystem
 
std::unique_ptr< Renalm_RenalSystem
 
std::unique_ptr< Respiratorym_RespiratorySystem
 
std::unique_ptr< Drugsm_DrugSystem
 
std::unique_ptr< Tissuem_TissueSystem
 
std::unique_ptr< ECGm_ECG
 
std::unique_ptr< AnesthesiaMachinem_AnesthesiaMachine
 
std::unique_ptr< Inhalerm_Inhaler
 
std::unique_ptr< SEPatientm_Patient
 
bool myLogger
 
- Protected Attributes inherited from Loggable
Loggerm_Logger
 

Friends

class BioGearsEngineTest
 
class BioGearsScenarioExec
 

Additional Inherited Members

- Static Public Attributes inherited from Loggable
static const std::string empty
 

Detailed Description

Manages and controls execution of all data/systems in BioGears.

Constructor & Destructor Documentation

BioGears::BioGears ( Logger logger)
BioGears::BioGears ( const std::string &  logfileName)
BioGears::~BioGears ( )
virtual

Member Function Documentation

void BioGears::AtSteadyState ( EngineState  state)
protectedvirtual
bool BioGears::CreateCircuitsAndCompartments ( )
void BioGears::ForwardFatal ( const std::string &  msg,
const std::string &  origin 
)
protectedvirtual

Reimplemented from LoggerForward.

SEActionManager& BioGears::GetActions ( )
inline
CDM::enumBioGearsAirwayMode::value BioGears::GetAirwayMode ( )
inline
SEAnesthesiaMachine& BioGears::GetAnesthesiaMachine ( )
inline
SEBloodChemistrySystem& BioGears::GetBloodChemistry ( )
inline
SECardiovascularSystem& BioGears::GetCardiovascular ( )
inline
BioGearsCircuits& BioGears::GetCircuits ( )
inline
BioGearsCompartments& BioGears::GetCompartments ( )
inline
SEConditionManager& BioGears::GetConditions ( )
inline
const BioGearsConfiguration& BioGears::GetConfiguration ( )
inline
DataTrack & BioGears::GetDataTrack ( )
SEDrugSystem& BioGears::GetDrugs ( )
inline
SEElectroCardioGram& BioGears::GetECG ( )
inline
SEEndocrineSystem& BioGears::GetEndocrine ( )
inline
SEEnergySystem& BioGears::GetEnergy ( )
inline
const SEScalarTime& BioGears::GetEngineTime ( )
inline
SEEnvironment& BioGears::GetEnvironment ( )
inline
SEGastrointestinalSystem& BioGears::GetGastrointestinal ( )
inline
SEHepaticSystem& BioGears::GetHepatic ( )
inline
SEInhaler& BioGears::GetInhaler ( )
inline
CDM::enumOnOff::value BioGears::GetIntubation ( )
inline
SENervousSystem& BioGears::GetNervous ( )
inline
SEPatient& BioGears::GetPatient ( )
inline
bool BioGears::GetPatientAssessment ( SEPatientAssessment assessment)
SERenalSystem& BioGears::GetRenal ( )
inline
SERespiratorySystem& BioGears::GetRespiratory ( )
inline
SaturationCalculator& BioGears::GetSaturationCalculator ( )
inline
const SEScalarTime& BioGears::GetSimulationTime ( )
inline
EngineState BioGears::GetState ( )
inline
BioGearsSubstances& BioGears::GetSubstances ( )
inline
const SEScalarTime& BioGears::GetTimeStep ( )
inline
SETissueSystem& BioGears::GetTissue ( )
inline
bool BioGears::Initialize ( const PhysiologyEngineConfiguration config)
protected
void BioGears::PostProcess ( )
protected
void BioGears::PreProcess ( )
protected
void BioGears::Process ( )
protected
void BioGears::SetAirwayMode ( CDM::enumBioGearsAirwayMode::value  mode)
void BioGears::SetIntubation ( CDM::enumOnOff::value  s)
void BioGears::SetupAnesthesiaMachine ( )
protected
void BioGears::SetupCardiovascular ( )
protected
Todo:
Make these a function of the systolic and diastolic pressure by fitting a curve to the data from the variations test
void BioGears::SetupExternalTemperature ( )
protected
void BioGears::SetupGastrointestinal ( )
protected
void BioGears::SetupInhaler ( )
protected
void BioGears::SetupInternalTemperature ( )
protected
void BioGears::SetupMechanicalVentilator ( )
protected
bool BioGears::SetupPatient ( )
protected

[108]

[242]

[225]

[312] [34]

[114]

[116]

[272]

cite ganong1995review

[78]

[288]

void BioGears::SetupRenal ( )
protected
Todo:
The bladder is currently not being modeled as a compliance
Todo:
Use a compliance here - make sure you remove the current handling of bladder volume in the renal system as a pressure source
void BioGears::SetupRespiratory ( )
protected
void BioGears::SetupTissue ( )
protected
Todo:
Put Initial Circuit/Compartment data values into the configuration file.

Friends And Related Function Documentation

friend class BioGearsEngineTest
friend
friend class BioGearsScenarioExec
friend

Member Data Documentation

std::unique_ptr<SEActionManager> BioGears::m_Actions
protected
CDM::enumBioGearsAirwayMode::value BioGears::m_AirwayMode
protected
std::unique_ptr<AnesthesiaMachine> BioGears::m_AnesthesiaMachine
protected
std::unique_ptr<BloodChemistry> BioGears::m_BloodChemistrySystem
protected
std::unique_ptr<Cardiovascular> BioGears::m_CardiovascularSystem
protected
std::unique_ptr<BioGearsCircuits> BioGears::m_Circuits
protected
std::unique_ptr<BioGearsCompartments> BioGears::m_Compartments
protected
std::unique_ptr<SEConditionManager> BioGears::m_Conditions
protected
std::unique_ptr<BioGearsConfiguration> BioGears::m_Config
protected
std::unique_ptr<SEScalarTime> BioGears::m_CurrentTime
protected
DataTrack* BioGears::m_DataTrack
protected
std::unique_ptr<Drugs> BioGears::m_DrugSystem
protected
std::unique_ptr<ECG> BioGears::m_ECG
protected
std::unique_ptr<Endocrine> BioGears::m_EndocrineSystem
protected
std::unique_ptr<Energy> BioGears::m_EnergySystem
protected
std::unique_ptr<Environment> BioGears::m_Environment
protected
std::unique_ptr<Gastrointestinal> BioGears::m_GastrointestinalSystem
protected
std::unique_ptr<Hepatic> BioGears::m_HepaticSystem
protected
std::unique_ptr<Inhaler> BioGears::m_Inhaler
protected
CDM::enumOnOff::value BioGears::m_Intubation
protected
std::unique_ptr<Nervous> BioGears::m_NervousSystem
protected
std::unique_ptr<SEPatient> BioGears::m_Patient
protected
std::unique_ptr<Renal> BioGears::m_RenalSystem
protected
std::unique_ptr<Respiratory> BioGears::m_RespiratorySystem
protected
std::unique_ptr<SaturationCalculator> BioGears::m_SaturationCalculator
protected
std::unique_ptr<SEScalarTime> BioGears::m_SimulationTime
protected
EngineState BioGears::m_State
protected
std::unique_ptr<BioGearsSubstances> BioGears::m_Substances
protected
std::unique_ptr<Tissue> BioGears::m_TissueSystem
protected
bool BioGears::myLogger
protected