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

#include <Nervous.h>

Inherits SENervousSystem, PulseNervousSystem, and PulseSystem.

Public Member Functions

virtual ~Nervous ()
 
void Clear ()
 
- Public Member Functions inherited from SENervousSystem
 SENervousSystem (Logger *logger)
 
virtual ~SENervousSystem ()
 
virtual const SEScalarGetScalar (const std::string &name)
 
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 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 ()
 
 Loggable (Logger *log)
 
virtual ~Loggable ()
 
virtual LoggerGetLogger () const
 
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
 

Protected Member Functions

 Nervous (PulseController &data)
 
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 ()
 Nervous Process Step. More...
 
void PostProcess ()
 Nervous PostProcess Step. More...
 
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...
 

Protected Attributes

PulseControllerm_data
 
double m_ArterialOxygenSetPoint_mmHg
 
double m_ArterialCarbonDioxideSetPoint_mmHg
 
bool m_FeedbackActive
 
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
 
- Protected Attributes inherited from SENervousSystem
SEScalarm_BaroreceptorHeartRateScale
 
SEScalarm_BaroreceptorHeartElastanceScale
 
SEScalarm_BaroreceptorResistanceScale
 
SEScalarm_BaroreceptorComplianceScale
 
SEPupillaryResponsem_LeftEyePupillaryResponse
 
SEPupillaryResponsem_RightEyePupillaryResponse
 
SEScalarm_ChemoreceptorHeartRateScale
 
SEScalarm_ChemoreceptorHeartElastanceScale
 
- Protected Attributes inherited from SESystem
std::stringstream m_ss
 
- Protected Attributes inherited from Loggable
Loggerm_Logger
 

Friends

class PBPulsePhysiology
 
class PulseController
 
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 ( PulseController data)
protected

◆ ~Nervous()

Nervous::~Nervous ( )
virtual

Member Function Documentation

◆ AtSteadyState()

void Nervous::AtSteadyState ( )
protectedvirtual

Notify systems that steady state has been achieved.

Reimplemented from 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.

Todo:
Add decompensation. Perhaps a reduction in the effect that is a function of blood volume below a threshold... and maybe time.

◆ 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.

◆ Initialize()

void Nervous::Initialize ( )
protectedvirtual

Initializes system properties to valid homeostatic values.

Reimplemented from PulseSystem.

◆ PostProcess()

void Nervous::PostProcess ( )
protectedvirtual

Nervous PostProcess Step.

Currently no nervous postprocess methods.

Implements PulseSystem.

◆ PreProcess()

void Nervous::PreProcess ( )
protectedvirtual

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 ( )
protectedvirtual

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 ( )
protectedvirtual

Initializes the nervous specific quantities.

Initializes the nervous system.

Implements PulseSystem.

Friends And Related Function Documentation

◆ PBPulsePhysiology

friend class PBPulsePhysiology
friend

◆ PulseController

friend class PulseController
friend

◆ PulseEngineTest

friend class PulseEngineTest
friend

Member Data Documentation

◆ m_ArterialCarbonDioxideSetPoint_mmHg

double Nervous::m_ArterialCarbonDioxideSetPoint_mmHg
protected
Todo:
Aaron these should be baselines.

◆ m_ArterialOxygenSetPoint_mmHg

double Nervous::m_ArterialOxygenSetPoint_mmHg
protected

◆ m_data

PulseController& Nervous::m_data
protected

◆ m_dt_s

double Nervous::m_dt_s
protected

◆ m_FeedbackActive

bool Nervous::m_FeedbackActive
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