Skip to content

Commit

Permalink
Removed multiple declarations of Sisat from PinskyRinzel
Browse files Browse the repository at this point in the history
Addresses this issue: OpenSourceBrain/PinskyRinzelModel#7 by implementing the solution suggested here: LEMS/jLEMS#88 (comment)
  • Loading branch information
JustasB committed Mar 26, 2018
1 parent ace214c commit bbd3191
Showing 1 changed file with 27 additions and 25 deletions.
52 changes: 27 additions & 25 deletions NeuroML2CoreTypes/Cells.xml
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -1583,7 +1583,7 @@

<Parameter name="iSoma" dimension="currentDensity"/>
<Parameter name="iDend" dimension="currentDensity"/>

<Parameter name="gLs" dimension="conductanceDensity"/>
<Parameter name="gLd" dimension="conductanceDensity"/>
<Parameter name="gNa" dimension="conductanceDensity"/>
Expand All @@ -1592,12 +1592,12 @@
<Parameter name="gKahp" dimension="conductanceDensity"/>
<Parameter name="gKC" dimension="conductanceDensity"/>
<Parameter name="gc" dimension="conductanceDensity"/>

<Parameter name="eNa" dimension="voltage"/>
<Parameter name="eCa" dimension="voltage"/>
<Parameter name="eK" dimension="voltage"/>
<Parameter name="eL" dimension="voltage"/>

<Parameter name="pp" dimension="none"/>
<Parameter name="cm" dimension="specificCapacitance"/>
<Parameter name="alphac" dimension="none"/>
Expand All @@ -1606,17 +1606,17 @@
<Parameter name="gNmda" dimension="conductanceDensity"/>
<Parameter name="gAmpa" dimension="conductanceDensity"/>
<Parameter name="qd0" dimension="none"/>

<!-- Normalizing Constants -->
<Constant name="MSEC" dimension="time" value="1 ms"/>
<Constant name="MVOLT" dimension="voltage" value="1 mV"/>
<Constant name="UAMP_PER_CM2" dimension="currentDensity" value="1 uA_per_cm2"/>

<!-- Model Constants -->
<Constant name="Smax" dimension="none" value="125.0"/>
<Constant name="Vsyn" dimension="voltage" value="60.0 mV"/>
<Constant name="betaqd" dimension="none" value="0.001"/>

<Exposure name="Vs" dimension="voltage"/>
<Exposure name="Vd" dimension="voltage"/>
<Exposure name="ICad" dimension="currentDensity"/>
Expand All @@ -1628,10 +1628,10 @@
<Exposure name="qd" dimension="none"/>
<Exposure name="Si" dimension="none"/>
<Exposure name="Wi" dimension="none"/>


<Dynamics>

<StateVariable name="Vs" dimension="voltage" exposure="Vs"/>
<StateVariable name="Vd" dimension="voltage" exposure="Vd"/>
<StateVariable name="Cad" dimension="none" exposure="Cad"/>
Expand All @@ -1645,15 +1645,12 @@
<!-- Synaptic Dynamics -->
<StateVariable name="Si" dimension="none" exposure="Si"/>
<StateVariable name="Wi" dimension="none" exposure="Wi"/>

<!-- Note Sisat is StateVariable & ConditionalDerivedVariable, see https://github.com/OpenSourceBrain/PinskyRinzelModel/issues/7 -->
<StateVariable name="Sisat" dimension="none"/>


<!-- baseCellMembPot compatibility -->
<DerivedVariable name="v" dimension="voltage" value="Vs" exposure="v"/>
<DerivedVariable name="ICad" dimension="currentDensity" exposure="ICad" value="gCa*sd*sd*(Vd-eCa)"/>



<DerivedVariable name="alphams_Vs" dimension="none" value="0.32*(-46.9-Vs/MVOLT)/(exp((-46.9-Vs/MVOLT)/4.0)-1.0)"/>
<DerivedVariable name="betams_Vs" dimension="none" value="0.28*(Vs/MVOLT+19.9)/(exp((Vs/MVOLT+19.9)/5.0)-1.0)"/>
Expand All @@ -1668,17 +1665,15 @@
<DerivedVariable name="alphasd_Vd" dimension="none" value="1.6/(1.0+exp(-0.072*(Vd/MVOLT-5.0)))"/>
<DerivedVariable name="betasd_Vd" dimension="none" value="0.02*(Vd/MVOLT+8.9)/(exp((Vd/MVOLT+8.9)/5.0)-1.0)"/>


<DerivedVariable name="Iampa" dimension="currentDensity" value="gAmpa*Wi*(Vd-Vsyn)"/>
<DerivedVariable name="Inmda" dimension="currentDensity" value="gNmda*Sisat*(Vd-Vsyn)/(1.0+0.28*exp(-0.062*(Vd/MVOLT-60.0)))"/>
<DerivedVariable name="Isyn" dimension="currentDensity" value="Iampa+Inmda"/>




<ConditionalDerivedVariable name="alphaqd" dimension="none">
<Case condition="0.00002*Cad .gt. 0.01" value="0.01"/>
<Case value="0.00002*Cad"/>
</ConditionalDerivedVariable>

<ConditionalDerivedVariable name="chid" dimension="none">
<Case condition="Cad/250 .gt. 1" value="1"/>
<Case value="Cad/250"/>
Expand All @@ -1688,18 +1683,25 @@
<Case condition="Vd .lt. -10*MVOLT" value="exp((Vd/MVOLT+50.0)/11-(Vd/MVOLT+53.5)/27)/18.975"/>
<Case value="2.0*exp((-53.5-Vd/MVOLT)/27.0)"/>
</ConditionalDerivedVariable>

<ConditionalDerivedVariable name="betacd_Vd" dimension="none">
<Case condition="Vd .lt. -10*MVOLT" value="(2.0*exp((-53.5-Vd/MVOLT)/27.0)-alphacd_Vd)"/>
<Case value="0"/>
</ConditionalDerivedVariable>

<!-- Note Sisat is StateVariable & ConditionalDerivedVariable, see https://github.com/OpenSourceBrain/PinskyRinzelModel/issues/7 -->
<ConditionalDerivedVariable name="Sisat" dimension="none">
<Case condition="Si .gt. Smax" value="Smax"/>
<Case value="Si"/>
</ConditionalDerivedVariable>

<ConditionalDerivedVariable name="Inmda" dimension="currentDensity">
<Case condition="1 .eq. 1" value="gNmda*Sisat*(Vd-Vsyn)/(1.0+0.28*exp(-0.062*(Vd/MVOLT-60.0)))"/>
</ConditionalDerivedVariable>

<ConditionalDerivedVariable name="Isyn" dimension="currentDensity">
<Case condition="1 .eq. 1" value="Iampa+Inmda"/>
</ConditionalDerivedVariable>


<TimeDerivative variable="Vs" value="(-gLs*(Vs-eL)-gNa*(Minfs_Vs^2)*hs*(Vs-eNa)-gKdr*ns*(Vs-eK)+(gc/pp)*(Vd-Vs)+iSoma/pp) / cm"/>
<TimeDerivative variable="Vd" value="(iDend/(1.0-pp)-Isyn/(1.0-pp)-gLd*(Vd-eL)-ICad-gKahp*qd*(Vd-eK)-gKC*cd*chid*(Vd-eK)+(gc*(Vs-Vd))/(1.0-pp)) / cm"/>
Expand All @@ -1713,7 +1715,7 @@
<!-- Synaptic Dynamics -->
<TimeDerivative variable="Si" value="-Si/150.0" />
<TimeDerivative variable="Wi" value="-Wi/2.0" />


<OnStart>
<StateAssignment variable="Vs" value="eL"/>
Expand All @@ -1722,7 +1724,7 @@
</OnStart>

</Dynamics>

</ComponentType>


Expand Down

0 comments on commit bbd3191

Please sign in to comment.