Pulse adds COVID-19 Simulation Support
×

The nervous class holds models of the peripheral and central nervous system. Currently, on the baroreceptor reflex is modeled. More...

#include <Nervous.h>

Inherits PulseNervousSystem.

Public Member Functions

virtual ~Nervous ()
 
void Clear ()
 
void Initialize ()
 Initializes system properties to valid homeostatic values. More...
 
void SetUp ()
 Initializes the nervous specific quantities. More...
 
void AtSteadyState ()
 Notify systems that steady state has been achieved. More...
 
void PreProcess ()
 Preprocess methods for the nervous system. More...
 
void Process (bool solve_and_transport=true)
 Nervous Process Step. More...
 
void PostProcess (bool solve_and_transport=true)
 Nervous PostProcess Step. More...
 
- Public Member Functions inherited from PulseNervousSystem
 PulseNervousSystem (Logger *logger)
 
virtual ~PulseNervousSystem ()=default
 
virtual const SEScalarGetScalar (const std::string &name) override
 
- Public Member Functions inherited from SENervousSystem
 SENervousSystem (Logger *logger)
 
virtual ~SENervousSystem ()
 
virtual eSwitch GetBaroreceptorFeedback () const
 
virtual void SetBaroreceptorFeedback (eSwitch s)
 
virtual bool HasBaroreceptorHeartRateScale () const
 
virtual SEScalarGetBaroreceptorHeartRateScale ()
 
virtual double GetBaroreceptorHeartRateScale () const
 
virtual bool HasBaroreceptorHeartElastanceScale () const
 
virtual SEScalarGetBaroreceptorHeartElastanceScale ()
 
virtual double GetBaroreceptorHeartElastanceScale () const
 
virtual bool HasBaroreceptorResistanceScale () const
 
virtual SEScalarGetBaroreceptorResistanceScale ()
 
virtual double GetBaroreceptorResistanceScale () const
 
virtual bool HasBaroreceptorComplianceScale () const
 
virtual SEScalarGetBaroreceptorComplianceScale ()
 
virtual double GetBaroreceptorComplianceScale () const
 
virtual eSwitch GetChemoreceptorFeedback () const
 
virtual void SetChemoreceptorFeedback (eSwitch s)
 
virtual bool HasChemoreceptorHeartRateScale () const
 
virtual SEScalarGetChemoreceptorHeartRateScale ()
 
virtual double GetChemoreceptorHeartRateScale () const
 
virtual bool HasChemoreceptorHeartElastanceScale () const
 
virtual SEScalarGetChemoreceptorHeartElastanceScale ()
 
virtual double GetChemoreceptorHeartElastanceScale () const
 
virtual bool HasLeftEyePupillaryResponse () const
 
virtual SEPupillaryResponseGetLeftEyePupillaryResponse ()
 
virtual const SEPupillaryResponseGetLeftEyePupillaryResponse () const
 
virtual void RemoveLeftEyePupillaryResponse ()
 
virtual bool HasRightEyePupillaryResponse () const
 
virtual SEPupillaryResponseGetRightEyePupillaryResponse ()
 
virtual const SEPupillaryResponseGetRightEyePupillaryResponse () const
 
virtual void RemoveRightEyePupillaryResponse ()
 
- Public Member Functions inherited from SESystem
 SESystem (Logger *logger)
 
virtual ~SESystem ()
 
- Public Member Functions inherited from Loggable
 Loggable (Logger *logger=nullptr)
 
 Loggable (std::string const &logfile)
 
virtual ~Loggable ()
 
virtual LoggerGetLogger () const
 
virtual void SetLogger (Logger &logger)
 
virtual void Debug (std::string const &msg, std::string const &origin=empty) const
 
virtual void Debug (std::stringstream &msg, std::string const &origin=empty) const
 
virtual void Debug (std::ostream &msg, std::string const &origin=empty) const
 
virtual void Info (std::string const &msg, std::string const &origin=empty) const
 
virtual void Info (std::stringstream &msg, std::string const &origin=empty) const
 
virtual void Info (const std::stringstream &msg, std::string const &origin=empty) const
 
virtual void Info (std::ostream &msg, std::string const &origin=empty) const
 
virtual void Warning (std::string const &msg, std::string const &origin=empty) const
 
virtual void Warning (std::stringstream &msg, std::string const &origin=empty) const
 
virtual void Warning (std::ostream &msg, std::string const &origin=empty) const
 
virtual void Error (std::string const &msg, std::string const &origin=empty) const
 
virtual void Error (std::stringstream &msg, std::string const &origin=empty) const
 
virtual void Error (std::ostream &msg, std::string const &origin=empty) const
 
virtual void Fatal (std::string const &msg, std::string const &origin=empty) const
 
virtual void Fatal (std::stringstream &msg, std::string const &origin=empty) const
 
virtual void Fatal (std::ostream &msg, std::string const &origin=empty) const
 
std::string to_string (int i)
 
std::string to_string (unsigned int i)
 
std::string to_string (size_t t)
 
std::string to_string (float f)
 
std::string to_string (double d)
 

Protected Member Functions

 Nervous (PulseData &data)
 
void ComputeExposedModelParameters () override
 
void BaroreceptorFeedback ()
 Calculates the baroreceptor feedback and sets the scaling parameters in the CDM. More...
 
void CheckBrainStatus ()
 Checks metrics in the brain to determine events to be thrown. More...
 
void ChemoreceptorFeedback ()
 Calculates the chemoreceptor feedback and sets the scaling parameters in the CDM. More...
 
void SetPupilEffects ()
 Sets pupil size and reactivity modifiers based on drug and TBI effects. More...
 
void CerebralSpinalFluidUpdates ()
 The CSF pressure application function calculates the pressure applied to the brain due to CSF pressure. More...
 

Protected Attributes

PulseDatam_data
 
bool m_BaroreceptorFeedbackStatus
 
bool m_BaroreceptorSaturationStatus
 
double m_ArterialOxygenBaseline_mmHg
 
double m_ArterialCarbonDioxideBaseline_mmHg
 
double m_BaroreceptorActiveTime_s
 
double m_BaroreceptorEffectivenessParameter
 
double m_BaroreceptorMeanArterialPressureBaseline_mmHg
 
double m_BaroreceptorSaturationTime_s
 
double m_LastMeanArterialPressure_mmHg
 
double m_PreviousBloodVolume_mL
 
double m_TotalSympatheticFraction
 
double m_CSFAbsorptionRate_mLPermin
 
double m_CSFProductionRate_mlPermin
 
double m_dt_s
 
double m_NormalizedGammaHeartRate
 
double m_NormalizedGammaElastance
 
double m_NormalizedGammaCompliance
 
double m_NormalizedGammaResistance
 
double m_NormalizedAlphaHeartRate
 
double m_NormalizedAlphaElastance
 
double m_NormalizedAlphaCompliance
 
double m_NormalizedAlphaResistance
 
double m_NormalizedBetaHeartRate
 
SEFluidCircuitNodem_IntracranialSpace
 
SEFluidCircuitPathm_CSFProductAbsorptionPath
 
SEFluidCircuitPathm_BrainVasculatureCompliancePath
 
SEFluidCircuitPathm_BrainVasculatureResistancePath
 
- Protected Attributes inherited from SENervousSystem
eSwitch m_BaroreceptorFeedback
 
SEScalarm_BaroreceptorHeartRateScale
 
SEScalarm_BaroreceptorHeartElastanceScale
 
SEScalarm_BaroreceptorResistanceScale
 
SEScalarm_BaroreceptorComplianceScale
 
eSwitch m_ChemoreceptorFeedback
 
SEScalarm_ChemoreceptorHeartRateScale
 
SEScalarm_ChemoreceptorHeartElastanceScale
 
SEPupillaryResponsem_LeftEyePupillaryResponse
 
SEPupillaryResponsem_RightEyePupillaryResponse
 
- Protected Attributes inherited from SESystem
std::stringstream m_ss
 
- Protected Attributes inherited from Loggable
bool myLogger
 
Loggerm_Logger
 

Friends

class PulseData
 
class PBPulsePhysiology
 
class PulseEngineTest
 

Additional Inherited Members

- Static Public Member Functions inherited from SESystem
static const SEScalarGetScalar (const std::string &name, std::vector< SESystem *> *systems)
 
- Static Public Attributes inherited from Loggable
static const std::string empty
 

Detailed Description

The nervous class holds models of the peripheral and central nervous system. Currently, on the baroreceptor reflex is modeled.

Constructor & Destructor Documentation

◆ Nervous()

Nervous::Nervous ( PulseData data)
protected

◆ ~Nervous()

Nervous::~Nervous ( )
virtual

Member Function Documentation

◆ AtSteadyState()

void Nervous::AtSteadyState ( )
virtual

Notify systems that steady state has been achieved.

Implements PulseSystem.

◆ BaroreceptorFeedback()

void Nervous::BaroreceptorFeedback ( )
protected

Calculates the baroreceptor feedback and sets the scaling parameters in the CDM.

The baroreceptor feedback function uses the current mean arterial pressure relative to the mean arterial pressure set-point in order to calculate the sympathetic and parasympathetic response fractions. These fractions are used to update the scaling parameters of heart rate, heart elastance, resistance and compliance for each time step.

◆ CerebralSpinalFluidUpdates()

void Nervous::CerebralSpinalFluidUpdates ( )
protected

The CSF pressure application function calculates the pressure applied to the brain due to CSF pressure.

The pressure applied to the brain is dictated by the pressure in the intranial space.

◆ CheckBrainStatus()

void Nervous::CheckBrainStatus ( )
protected

Checks metrics in the brain to determine events to be thrown.

Intracranial pressure is checked to determine if the patient has Intracranial Hyper/hypotension

Event:
Patient: Intracranial Hypertension. The intracranial pressure has risen above 25 mmHg.
Event:
Patient: End Intracranial Hypertension. The intracranial pressure has fallen below 24 mmHg.
Event:
Patient: Intracranial Hypotension. The intracranial pressure has fallen below 7 mmHg.
Event:
Patient: End Intracranial Hypotension. The intracranial pressure has risen above 7.5 mmHg.

◆ ChemoreceptorFeedback()

void Nervous::ChemoreceptorFeedback ( )
protected

Calculates the chemoreceptor feedback and sets the scaling parameters in the CDM.

The chemoreceptor feedback function uses the current arterial partial pressure of oxygen and carbon dioxide relative to the partial pressure set-points in order to calculate response signal. The affected systems identify the signal and adjust accordingly. Note that chemoreception is currently built into the respiratory driver; therefore, the chemoreceptor feedback only sets CV modifiers.

Todo:
Compute and apply chemoreceptor-mediated contractility changes

◆ Clear()

void Nervous::Clear ( )
virtual

Reimplemented from SENervousSystem.

◆ ComputeExposedModelParameters()

void Nervous::ComputeExposedModelParameters ( )
overrideprotectedvirtual

Implements PulseNervousSystem.

◆ Initialize()

void Nervous::Initialize ( )
virtual

Initializes system properties to valid homeostatic values.

For stabilization only! Called AFTER Setup when stabilizing a new patient

Reimplemented from PulseSystem.

◆ PostProcess()

void Nervous::PostProcess ( bool  solve_and_transport = true)
virtual

Nervous PostProcess Step.

Currently no nervous postprocess methods.

Implements PulseSystem.

◆ PreProcess()

void Nervous::PreProcess ( )
virtual

Preprocess methods for the nervous system.

Computes nervous system regulation of the body. Baroreceptor and chemoreceptor feedback is computed and modifiers set in preparation for systems processing.

Implements PulseSystem.

◆ Process()

void Nervous::Process ( bool  solve_and_transport = true)
virtual

Nervous Process Step.

The only current Process-specific function checks the brain status to set events.

Implements PulseSystem.

◆ SetPupilEffects()

void Nervous::SetPupilEffects ( )
protected

Sets pupil size and reactivity modifiers based on drug and TBI effects.

Modifiers are on a scale between -1 (for reduction in size/reactivity) and 1 (for increase) TBI effects are applied to the eye on the same side of the injury if localized or both if diffuse Drug and TBI pupil effects are simply summed together

◆ SetUp()

void Nervous::SetUp ( )
virtual

Initializes the nervous specific quantities.

Called during both State loading and Patient Stabilization Pull and setup up our data (can be from other systems) Initialize will be called after this and can overwrite any of this data (only if stabilizing)

Implements PulseSystem.

Friends And Related Function Documentation

◆ PBPulsePhysiology

friend class PBPulsePhysiology
friend

◆ PulseData

friend class PulseData
friend

◆ PulseEngineTest

friend class PulseEngineTest
friend

Member Data Documentation

◆ m_ArterialCarbonDioxideBaseline_mmHg

double Nervous::m_ArterialCarbonDioxideBaseline_mmHg
protected

◆ m_ArterialOxygenBaseline_mmHg

double Nervous::m_ArterialOxygenBaseline_mmHg
protected

◆ m_BaroreceptorActiveTime_s

double Nervous::m_BaroreceptorActiveTime_s
protected

◆ m_BaroreceptorEffectivenessParameter

double Nervous::m_BaroreceptorEffectivenessParameter
protected

◆ m_BaroreceptorFeedbackStatus

bool Nervous::m_BaroreceptorFeedbackStatus
protected

◆ m_BaroreceptorMeanArterialPressureBaseline_mmHg

double Nervous::m_BaroreceptorMeanArterialPressureBaseline_mmHg
protected

◆ m_BaroreceptorSaturationStatus

bool Nervous::m_BaroreceptorSaturationStatus
protected

◆ m_BaroreceptorSaturationTime_s

double Nervous::m_BaroreceptorSaturationTime_s
protected

◆ m_BrainVasculatureCompliancePath

SEFluidCircuitPath* Nervous::m_BrainVasculatureCompliancePath
protected

◆ m_BrainVasculatureResistancePath

SEFluidCircuitPath* Nervous::m_BrainVasculatureResistancePath
protected

◆ m_CSFAbsorptionRate_mLPermin

double Nervous::m_CSFAbsorptionRate_mLPermin
protected

◆ m_CSFProductAbsorptionPath

SEFluidCircuitPath* Nervous::m_CSFProductAbsorptionPath
protected

◆ m_CSFProductionRate_mlPermin

double Nervous::m_CSFProductionRate_mlPermin
protected

◆ m_data

PulseData& Nervous::m_data
protected

◆ m_dt_s

double Nervous::m_dt_s
protected

◆ m_IntracranialSpace

SEFluidCircuitNode* Nervous::m_IntracranialSpace
protected

◆ m_LastMeanArterialPressure_mmHg

double Nervous::m_LastMeanArterialPressure_mmHg
protected

◆ m_NormalizedAlphaCompliance

double Nervous::m_NormalizedAlphaCompliance
protected

◆ m_NormalizedAlphaElastance

double Nervous::m_NormalizedAlphaElastance
protected

◆ m_NormalizedAlphaHeartRate

double Nervous::m_NormalizedAlphaHeartRate
protected

◆ m_NormalizedAlphaResistance

double Nervous::m_NormalizedAlphaResistance
protected

◆ m_NormalizedBetaHeartRate

double Nervous::m_NormalizedBetaHeartRate
protected

◆ m_NormalizedGammaCompliance

double Nervous::m_NormalizedGammaCompliance
protected

◆ m_NormalizedGammaElastance

double Nervous::m_NormalizedGammaElastance
protected

◆ m_NormalizedGammaHeartRate

double Nervous::m_NormalizedGammaHeartRate
protected

◆ m_NormalizedGammaResistance

double Nervous::m_NormalizedGammaResistance
protected

◆ m_PreviousBloodVolume_mL

double Nervous::m_PreviousBloodVolume_mL
protected

◆ m_TotalSympatheticFraction

double Nervous::m_TotalSympatheticFraction
protected

Distributed under the Apache License, Version 2.0.

See accompanying NOTICE file for details.