The drug system contains the physiologically based pharmacokinetic (PBPK) model and the pharmacodynamic (PD) model. More...

#include <Drugs.h>

Inheritance diagram for biogears::Drugs:

Public Member Functions

virtual ~Drugs () override
 
const char * classname () const override
 
size_t hash_code () const override
 
void Clear () override
 
void Initialize () override
 Initializes system properties to valid homeostatic values. More...
 
virtual bool Load (const CDM::BioGearsDrugSystemData &in)
 
virtual CDM::BioGearsDrugSystemDataUnload () const override
 
void AtSteadyState () override
 Determines if the engine is stable. More...
 
void PreProcess () override
 Substance Preprocess function. More...
 
void Process () override
 Substances process function. More...
 
void PostProcess () override
 
- Public Member Functions inherited from biogears::SEDrugSystem
 SEDrugSystem (Logger *logger)
 
 ~SEDrugSystem () override
 
const SEScalarGetScalar (const char *name) override
 
const SEScalarGetScalar (const std::string &name) override
 
bool Load (const CDM::DrugSystemData &in)
 
Tree< const char * > GetPhysiologyRequestGraph () const override
 
bool HasAntibioticActivity () const
 
SEScalarGetAntibioticActivity ()
 
double GetAntibioticActivity () const
 
bool HasBronchodilationLevel () const
 
SEScalarFractionGetBronchodilationLevel ()
 
double GetBronchodilationLevel () const
 
bool HasFeverChange () const
 
SEScalarTemperatureGetFeverChange ()
 
double GetFeverChange (const TemperatureUnit &unit) const
 
bool HasHeartRateChange () const
 
SEScalarFrequencyGetHeartRateChange ()
 
double GetHeartRateChange (const FrequencyUnit &unit) const
 
bool HasHemorrhageChange () const
 
SEScalarFractionGetHemorrhageChange ()
 
double GetHemorrhageChange () const
 
bool HasMeanBloodPressureChange () const
 
SEScalarPressureGetMeanBloodPressureChange ()
 
double GetMeanBloodPressureChange (const PressureUnit &unit) const
 
bool HasNeuromuscularBlockLevel () const
 
SEScalarFractionGetNeuromuscularBlockLevel ()
 
double GetNeuromuscularBlockLevel () const
 
bool HasPainToleranceChange () const
 
SEScalarFractionGetPainToleranceChange ()
 
double GetPainToleranceChange () const
 
bool HasPulsePressureChange () const
 
SEScalarPressureGetPulsePressureChange ()
 
double GetPulsePressureChange (const PressureUnit &unit) const
 
bool HasRespirationRateChange () const
 
SEScalarFrequencyGetRespirationRateChange ()
 
double GetRespirationRateChange (const FrequencyUnit &unit) const
 
bool HasSedationLevel () const
 
SEScalarFractionGetSedationLevel ()
 
double GetSedationLevel () const
 
bool HasTidalVolumeChange () const
 
SEScalarVolumeGetTidalVolumeChange ()
 
double GetTidalVolumeChange (const VolumeUnit &unit) const
 
bool HasTubularPermeabilityChange () const
 
SEScalarFractionGetTubularPermeabilityChange ()
 
double GetTubularPermeabilityChange () const
 
bool HasCentralNervousResponse () const
 
SEScalarFractionGetCentralNervousResponse ()
 
double GetCentralNervousResponse () const
 
- Public Member Functions inherited from biogears::SESystem
 SESystem (Logger *logger)
 
virtual ~SESystem ()
 
bool Load (const CDM::SystemData &in)
 
- Public Member Functions inherited from biogears::Loggable
 Loggable ()
 
 Loggable (Logger *log)
 
virtual ~Loggable ()
 
virtual LoggerGetLogger () const
 

Static Public Member Functions

static size_t TypeHash ()
 
static constexpr char const *const TypeTag ()
 Hopefully this returns a unique ID for every type. More...
 
- Static Public Member Functions inherited from biogears::SEDrugSystem
static size_t TypeHash ()
 
static constexpr char const *const TypeTag ()
 
- Static Public Member Functions inherited from biogears::SESystem
static const SEScalarGetScalar (const char *name, std::vector< SESystem * > *systems)
 
static const SEScalarGetScalar (const std::string &name, std::vector< SESystem * > *systems)
 

Protected Member Functions

 Drugs (BioGears &bg)
 
virtual void Unload (CDM::BioGearsDrugSystemData &data) const
 
void SetUp () override
 Initializes parameters for the Drugs Class. More...
 
void AdministerSubstanceBolus ()
 Increments the mass of a substance to represent drug injection. More...
 
void AdministerSubstanceInfusion ()
 Increments the mass of a substance to represent drug infusion. More...
 
void AdministerSubstanceCompoundInfusion ()
 Increases the substance masses for compounds. More...
 
void AdministerSubstanceNasal ()
 Administer drugs via nasal route. More...
 
void AdministerSubstanceOral ()
 Administer drugs via transmucosal and gastrointestinal routes. More...
 
void CalculatePartitionCoefficients ()
 Calculate partition coefficients for the PK Model. More...
 
void CalculateSubstanceClearance ()
 Calculates the substance mass cleared. More...
 
void CalculatePlasmaSubstanceConcentration ()
 Calculates the concentration of a substance in the plasma. More...
 
void CalculateDrugEffects ()
 Calculates the drug effects on other system parameters. More...
 
void SarinKinetics ()
 Calculates the inhibition of erythrocyte bound acetylcholinesterase by the nerve agent Sarin using reaction kinetics. More...
 
double OralTransmucosalModel (const SESubstance *sub, SETransmucosalState *ot)
 Calculates the transport of drugs across the transmucosal lining into circulation Returns the total drug mass remaining in the mouth. More...
 
- Protected Member Functions inherited from biogears::SEDrugSystem
void Unload (CDM::DrugSystemData &data) const
 
- Protected Member Functions inherited from biogears::SESystem
void Unload (CDM::SystemData &data) const
 
- Protected Member Functions inherited from biogears::Loggable
virtual void Debug (const char *msg, const char *origin="") const
 
virtual void Debug (const std::string &msg, const std::string &origin=empty) const
 
virtual void Debug (std::ostream &msg, const std::string &origin=empty) const
 
virtual void Info (const char *msg, const char *origin="") const
 
virtual void Info (const std::string &msg, const std::string &origin=empty) const
 
virtual void Info (std::ostream &msg, const std::string &origin=empty) const
 
virtual void Warning (const char *msg, const char *origin="") const
 
virtual void Warning (const std::string &msg, const std::string &origin=empty) const
 
virtual void Warning (std::ostream &msg, const std::string &origin=empty) const
 
virtual void Error (const char *msg, const char *origin="") const
 
virtual void Error (const std::string msg, const std::string origin=empty) const
 
virtual void Error (std::ostream &msg, const std::string &origin=empty) const
 
virtual void Fatal (const char *msg, const char *origin="") const
 
virtual void Fatal (const std::string &msg, const std::string &origin=empty) const
 
virtual void Fatal (std::ostream &msg, const std::string &origin=empty) const
 
- Protected Member Functions inherited from biogears::BioGearsSystem
virtual void LoadState ()
 

Static Protected Member Functions

static auto make_unique (BioGears &bg) -> std::unique_ptr< Drugs >
 

Protected Attributes

BioGearsm_data
 
std::map< const SESubstance *, SESubstanceBolusState * > m_BolusAdministrations
 
std::map< const SESubstance *, SENasalState * > m_NasalStates
 
std::map< const SESubstance *, SETransmucosalState * > m_TransmucosalStates
 
double m_SarinRbcAcetylcholinesteraseComplex_nM
 
double m_AgedRbcAcetylcholinesterase_nM
 
double m_dt_s
 
double m_totalAdministered_uL
 
double m_RbcAcetylcholinesteraseFractionInhibited
 
SELiquidCompartmentm_aortaVascular
 
SELiquidCompartmentm_venaCavaVascular
 
SELiquidCompartmentm_muscleIntracellular
 
SELiquidCompartmentm_liverVascular
 
SETissueCompartmentm_liverTissue
 
SEFluidCircuitPathm_IVToVenaCava
 
SETissueCompartmentm_fatTissue
 
SESubstancem_Sarin
 
SESubstancem_Pralidoxime
 
- Protected Attributes inherited from biogears::SEDrugSystem
SEScalarm_AntibioticActivity
 
SEScalarFractionm_BronchodilationLevel
 
SEScalarTemperaturem_FeverChange
 
SEScalarFrequencym_HeartRateChange
 
SEScalarFractionm_HemorrhageChange
 
SEScalarPressurem_MeanBloodPressureChange
 
SEScalarFractionm_NeuromuscularBlockLevel
 
SEScalarFractionm_PainToleranceChange
 
SEScalarPressurem_PulsePressureChange
 
SEScalarFrequencym_RespirationRateChange
 
SEScalarFractionm_SedationLevel
 
SEScalarVolumem_TidalVolumeChange
 
SEScalarFractionm_TubularPermeabilityChange
 
SEScalarFractionm_CentralNervousResponse
 
- Protected Attributes inherited from biogears::SESystem
std::stringstream m_ss
 
- Protected Attributes inherited from biogears::Loggable
Loggerm_Logger
 

Friends

class BioGears
 
class BioGearsEngineTest
 

Additional Inherited Members

- Static Public Attributes inherited from biogears::Loggable
static const std::string empty
 
static const char * empty_cStr
 

Detailed Description

The drug system contains the physiologically based pharmacokinetic (PBPK) model and the pharmacodynamic (PD) model.

Drug transvascular transport is modeled with a physiologically-based pharmacokinetic (PBPK) model, and the physiologic effects on the body are modeled with a low-fidelity pharmacodynamic (PD) model.

Constructor & Destructor Documentation

biogears::Drugs::Drugs ( BioGears bg)
protected
biogears::Drugs::~Drugs ( )
overridevirtual

Member Function Documentation

void biogears::Drugs::AdministerSubstanceBolus ( )
protected

Increments the mass of a substance to represent drug injection.

The mass of a substance is increased based on the administration of a substance. For a bolus administration, the user specifies a dose (amount), a concentration, and a substance. The calculated mass is then incrementally added to the vena cava over two seconds.

Error:
Error: Unavailable Administration Route
Todo:
Add fluid amount to fluid system
void biogears::Drugs::AdministerSubstanceCompoundInfusion ( )
protected

Increases the substance masses for compounds.

The masses of all substances associated with the compound substance are increased. The mass of each substance is incremented in the vena cava based on the rate specified by the user and a concentration specified in the compound substance file.

: Re. Sepsis - How does rate compare to that cited in literature? ///@cite malbrain2014fluid, [397]

void biogears::Drugs::AdministerSubstanceInfusion ( )
protected

Increments the mass of a substance to represent drug infusion.

The mass of a substance is increased based on the administration of a substance. For an infusion, the user specifies a concentration and a rate. The calculated mass is then added to the vena cava every time step until the infusion is stopped.

Todo:
sub needs to be const
void biogears::Drugs::AdministerSubstanceNasal ( )
protected

Administer drugs via nasal route.

This function administers drug into the nose as substance that can interact with three different sections: anterior, posterior, and gastrointestinal. Drug is initially deposited in the anterior and posterior sections and goes through rate constant-determined translocation into either uptake or excretion through the GI section. This administration path is generalized and assumes that the drug has a carrier, however, adjustment of drug release constants allows for administration with non-carrier drugs

void biogears::Drugs::AdministerSubstanceOral ( )
protected

Administer drugs via transmucosal and gastrointestinal routes.

This function adminsters drug as lozenges which dissolve in the mouth (transmucosal) or as pills that are swallowed and dissolve in the stomarch (gastrointestinal). The transmucosal route takes into account dissolved drug that is swallowed and enters circulation through the GI and thus intitiates a GI drug state. This function intiates the transmucosal and oral states–other functions (Drugs::ProcessOralTransmucosalModel, Gastrointestinal::ProcessCATModel) handle the actual substance transport and absorption.

void biogears::Drugs::AtSteadyState ( )
overridevirtual

Determines if the engine is stable.

When the engine is stable, the CDM makes this call to update the member variable.

Reimplemented from biogears::BioGearsSystem.

void biogears::Drugs::CalculateDrugEffects ( )
protected

Calculates the drug effects on other system parameters.

If the substance is a drug with an EC50 value, the effects on heart rate, blood pressure, respiration rate, tidal volume, neuromuscular block level, sedation level, bronchodilation level, and pupillary state are calculated using the current plasma concentration, the EC50, and the maximum drug response.

Todo:
The drug effect is being applied to the baseline, so if the baseline changes the delta heart rate changes.

\ [Regoes2004Pharmacodynamics]

void biogears::Drugs::CalculatePartitionCoefficients ( )
protected

Calculate partition coefficients for the PK Model.

Parameters
vSubstancesCoefficients are calculated for the substances in the vector with IonicState.

The partition coefficients are calculated for each substance in the input vector (active substances). To ensure the diffusion is modeled with PK for the substance, a check is performed for Ionic State. If the property is present the coefficients are calculated. They are calculated for all tissue compartments. coefficients are set on the substance compartment effects for use during the diffusion calculation.

Error:
Fatal: Binding Protein not supported
void biogears::Drugs::CalculatePlasmaSubstanceConcentration ( )
protected

Calculates the concentration of a substance in the plasma.

If the substance has PK properties, the concentration of the substance in the plasma is calculated. PlasmaConcentration = TotalMassInTheBlood / PlasmaVolume. The plasma concentration is then set on the substance. The concentration computation is obviously erroneous. This is a known issue. See pharmacokinetics

void biogears::Drugs::CalculateSubstanceClearance ( )
protected

Calculates the substance mass cleared.

If the substance has PK properties, the substance clearance is calculated. The renal, liver, and systemic clearance terms are applied to each anatomy compartment per substance. The amount of mass is then removed from the tissue node each time step. The tissue node mass and concentration are then updated. Sets the amount of substance cleared as a compartment effect for each substance.

const char* biogears::Drugs::classname ( ) const
inlineoverridevirtual

Reimplemented from biogears::SEDrugSystem.

void biogears::Drugs::Clear ( )
overridevirtual

Reimplemented from biogears::SEDrugSystem.

size_t biogears::Drugs::hash_code ( ) const
inlineoverridevirtual

Reimplemented from biogears::SEDrugSystem.

void biogears::Drugs::Initialize ( )
overridevirtual

Initializes system properties to valid homeostatic values.

Reimplemented from biogears::BioGearsSystem.

bool biogears::Drugs::Load ( const CDM::BioGearsDrugSystemData in)
virtual
Error:
Error: Unable to find substance for IV bolus administration
auto biogears::Drugs::make_unique ( BioGears bg) -> std::unique_ptr<Drugs>
staticprotected
double biogears::Drugs::OralTransmucosalModel ( const SESubstance sub,
SETransmucosalState ot 
)
protected

Calculates the transport of drugs across the transmucosal lining into circulation Returns the total drug mass remaining in the mouth.

This model assumes that drug has been given as a lozenge that dissolves completely in the mouth and enters circulation by diffusing across the mucosal layer. The diffusion model assumes that drug can cross the sublingual and buccal mucosa, which are the most permeable sections of the mouth to drugs. The sublingual and buccal layers are discretized into seven compartments so that the diffusion equation can be estimated across them using finite difference methods. This number of compartments was used in study of Xia The model was designed originally by Xia2015Development. This mode was designed for oral transmucosal fentanyl citrate (OTFC), and thus many paramters are optimized for it. If more drugs utilize this route, the fentanyl specific parameters may need to be changed to substance CDM parameters.

void biogears::Drugs::PostProcess ( )
inlineoverridevirtual
void biogears::Drugs::PreProcess ( )
overridevirtual

Substance Preprocess function.

The AdminsterSubstances, AdministerIVSubstances, and Hemorrhage actions are processed in this step. The masses of the substances associated with these actions are updated as the actions are processed.

Implements biogears::BioGearsSystem.

void biogears::Drugs::Process ( )
overridevirtual

Substances process function.

For any drugs circulating in the system the renal and hepatic clearance factors and metabolic factors are assigned to the appropriate compartments. The drug effects categories and system level drug effects are calculated and the values are set on the common data model for use in other systems. Drug effects are only calculated if the PD is enabled.

Implements biogears::BioGearsSystem.

void biogears::Drugs::SarinKinetics ( )
protected

Calculates the inhibition of erythrocyte bound acetylcholinesterase by the nerve agent Sarin using reaction kinetics.

Unlike other drugs in BioGears, the PD effects of Sarin are not based directly on agent plasma concentration. Instead, we model Sarin binding to red blood cell acetylcholinesterase (Rbc-Ache) and link the inhibition of this enzyme to Sarin pharmacodynamics. This calculation utilizies a kinetic model that incorporates irreversible aging of Rbc-Ache and the salvaging effect of Pralidoxime. As such, this strategy represents a more mechanistic, receptor-target approach to pharmacodynamics

[24] [289]

[24] [289]

[125]

[289]

[289]

[289]

[289]

[289] and [24]

void biogears::Drugs::SetUp ( )
overrideprotectedvirtual

Initializes parameters for the Drugs Class.

Initializes member variables and system level values on the common data model.

Implements biogears::BioGearsSystem.

static size_t biogears::Drugs::TypeHash ( )
inlinestatic
static constexpr char const* const biogears::Drugs::TypeTag ( )
inlinestatic

Hopefully this returns a unique ID for every type.

CDM::BioGearsDrugSystemData * biogears::Drugs::Unload ( ) const
overridevirtual

Reimplemented from biogears::SEDrugSystem.

void biogears::Drugs::Unload ( CDM::BioGearsDrugSystemData data) const
protectedvirtual

Friends And Related Function Documentation

friend class BioGears
friend
friend class BioGearsEngineTest
friend

Member Data Documentation

double biogears::Drugs::m_AgedRbcAcetylcholinesterase_nM
protected
SELiquidCompartment* biogears::Drugs::m_aortaVascular
protected
std::map<const SESubstance*, SESubstanceBolusState*> biogears::Drugs::m_BolusAdministrations
protected
BioGears& biogears::Drugs::m_data
protected
double biogears::Drugs::m_dt_s
protected
SETissueCompartment* biogears::Drugs::m_fatTissue
protected
SEFluidCircuitPath* biogears::Drugs::m_IVToVenaCava
protected
SETissueCompartment* biogears::Drugs::m_liverTissue
protected
SELiquidCompartment* biogears::Drugs::m_liverVascular
protected
SELiquidCompartment* biogears::Drugs::m_muscleIntracellular
protected
std::map<const SESubstance*, SENasalState*> biogears::Drugs::m_NasalStates
protected
SESubstance* biogears::Drugs::m_Pralidoxime
protected
double biogears::Drugs::m_RbcAcetylcholinesteraseFractionInhibited
protected
SESubstance* biogears::Drugs::m_Sarin
protected
double biogears::Drugs::m_SarinRbcAcetylcholinesteraseComplex_nM
protected
double biogears::Drugs::m_totalAdministered_uL
protected
std::map<const SESubstance*, SETransmucosalState*> biogears::Drugs::m_TransmucosalStates
protected
SELiquidCompartment* biogears::Drugs::m_venaCavaVascular
protected