Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Pulse Physiology Suite
engine
Commits
975ec87f
Commit
975ec87f
authored
Jun 25, 2020
by
Aaron Bray
Browse files
Disable CSF by default for now
parent
edb2cea2
Changes
3
Hide whitespace changes
Inline
Side-by-side
src/cpp/cpm/PulseConfiguration.cpp
View file @
975ec87f
...
...
@@ -121,7 +121,7 @@ PulseConfiguration::PulseConfiguration(Logger* logger) : SEEngineConfiguration(l
m_WaterDigestionRate
=
nullptr
;
// Nervous
m_CerebrospinalFluidEnabled
=
eSwitch
::
O
n
;
m_CerebrospinalFluidEnabled
=
eSwitch
::
O
ff
;
m_BaroreceptorFeedback
=
eSwitch
::
On
;
m_ChemoreceptorFeedback
=
eSwitch
::
On
;
m_HeartElastanceDistributedTimeDelay
=
nullptr
;
...
...
@@ -255,7 +255,7 @@ void PulseConfiguration::Clear()
SAFE_DELETE
(
m_WaterDigestionRate
);
// Nervous
m_CerebrospinalFluidEnabled
=
eSwitch
::
O
n
;
m_CerebrospinalFluidEnabled
=
eSwitch
::
O
ff
;
m_BaroreceptorFeedback
=
eSwitch
::
On
;
m_ChemoreceptorFeedback
=
eSwitch
::
On
;
SAFE_DELETE
(
m_HeartElastanceDistributedTimeDelay
);
...
...
@@ -412,7 +412,7 @@ void PulseConfiguration::Initialize(const std::string& dataDir, SESubstanceManag
GetWaterDigestionRate
().
SetValue
(
0.417
,
VolumePerTimeUnit
::
mL_Per_s
);
// Peronnet2012Pharmacokinetic, Estimated from 300mL H20 being absorbed in 9.5-12m
// Nervous
m_CerebrospinalFluidEnabled
=
eSwitch
::
O
n
;
m_CerebrospinalFluidEnabled
=
eSwitch
::
O
ff
;
m_BaroreceptorFeedback
=
eSwitch
::
On
;
m_ChemoreceptorFeedback
=
eSwitch
::
On
;
GetHeartElastanceDistributedTimeDelay
().
SetValue
(
20.0
,
TimeUnit
::
s
);
...
...
src/cpp/cpm/io/protobuf/PBPulseConfiguration.cpp
View file @
975ec87f
...
...
@@ -240,6 +240,8 @@ void PBPulseConfiguration::Serialize(const PULSE_BIND::ConfigurationData& src, P
if
(
src
.
has_nervousconfiguration
())
{
const
PULSE_BIND
::
ConfigurationData_NervousConfigurationData
&
config
=
src
.
nervousconfiguration
();
if
(
config
.
enablecerebrospinalfluid
()
!=
CDM_BIND
::
eSwitch
::
NullSwitch
)
dst
.
EnableCerebrospinalFluid
((
eSwitch
)
config
.
enablecerebrospinalfluid
());
if
(
config
.
baroreceptorfeedback
()
!=
CDM_BIND
::
eSwitch
::
NullSwitch
)
dst
.
SetBaroreceptorFeedback
((
eSwitch
)
config
.
baroreceptorfeedback
());
if
(
config
.
chemoreceptorfeedback
()
!=
CDM_BIND
::
eSwitch
::
NullSwitch
)
...
...
@@ -492,6 +494,7 @@ void PBPulseConfiguration::Serialize(const PulseConfiguration& src, PULSE_BIND::
// Nervous
PULSE_BIND
::
ConfigurationData_NervousConfigurationData
*
n
=
dst
.
mutable_nervousconfiguration
();
n
->
set_enablecerebrospinalfluid
((
CDM_BIND
::
eSwitch
)
src
.
m_CerebrospinalFluidEnabled
);
n
->
set_baroreceptorfeedback
((
CDM_BIND
::
eSwitch
)
src
.
m_BaroreceptorFeedback
);
n
->
set_chemoreceptorfeedback
((
CDM_BIND
::
eSwitch
)
src
.
m_ChemoreceptorFeedback
);
if
(
src
.
HasHeartElastanceDistributedTimeDelay
())
...
...
src/cpp/cpm/physiology/Nervous.cpp
View file @
975ec87f
...
...
@@ -49,6 +49,7 @@ Nervous::~Nervous()
void
Nervous
::
Clear
()
{
SENervousSystem
::
Clear
();
m_CSFProductAbsorptionPath
=
nullptr
;
}
//--------------------------------------------------------------------------------------------------
...
...
@@ -114,8 +115,8 @@ void Nervous::SetUp()
m_NormalizedAlphaResistance
=
m_data
.
GetConfiguration
().
GetNormalizedResistanceSympatheticSlope
();
m_NormalizedBetaHeartRate
=
m_data
.
GetConfiguration
().
GetNormalizedHeartRateParasympatheticSlope
();
m_CSFProductAbsorptionPath
=
m_data
.
GetCircuits
().
GetActiveCardiovascularCircuit
().
GetPath
(
pulse
::
CerebrospinalFluidPath
::
GroundToIntracranialSpace1
);
if
(
m_data
.
GetConfiguration
().
IsCerebrospinalFluidEnabled
())
m_CSFProductAbsorptionPath
=
m_data
.
GetCircuits
().
GetActiveCardiovascularCircuit
().
GetPath
(
pulse
::
CerebrospinalFluidPath
::
GroundToIntracranialSpace1
);
}
void
Nervous
::
AtSteadyState
()
...
...
@@ -223,6 +224,8 @@ void Nervous::PostProcess(bool solve_and_transport)
//--------------------------------------------------------------------------------------------------
void
Nervous
::
CerebralSpinalFluidUpdates
()
{
if
(
!
m_data
.
GetConfiguration
().
IsCerebrospinalFluidEnabled
())
return
;
//Update CSF Production and Absorption Rates
m_CSFProductAbsorptionPath
->
GetNextFlowSource
().
SetValue
(
m_CSFProductionRate_mlPermin
-
m_CSFAbsorptionRate_mLPermin
,
VolumePerTimeUnit
::
mL_Per_min
);
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment