Location: ECC_MSK (Rios et al. 1993) @ 0215191a1690 / Simulation / src / simFig13.py

Author:
WeiweiAi <wai484@aucklanduni.ac.nz>
Date:
2022-07-28 09:41:09+12:00
Desc:
fixed the legend in Fig6
Permanent Source URI:
https://models.cellml.org/workspace/8af/rawfile/0215191a1690e71b260b53fcb0cefb005d681e24/Simulation/src/simFig13.py

# importing modules
import sys as sys
import os 
import numpy

# Getting the name of the directory where this file is present.
current = os.path.dirname(os.path.realpath(__file__))  # src
# Getting the parent directory name where the current directory is present.
parent = os.path.dirname(current) # Simulation
# Getting the grandparent directory name
gparent = os.path.dirname(parent) # RecruitmentSynchronization_SMCs
# The path where the simExp.py is saved
mpath = gparent + '\\cellLib\\Scripts'
# appending a path
sys.path.append(mpath)
import simExp
# The simulation .sedml file
simfile = gparent+'\\Experiments\\MWC_18_test.sedml'
# Set the parameters for simulation
start, ending, pointInterval = 0, 420, 0.01

savefiles=[parent+'\\simulatedData\\simFig13_r']
indexStart = int(200/pointInterval)
indexEnd = int(ending/pointInterval) + 1
varSet = {'clamp_para/t_act':{'constants':200},'free_para_18/K':{'constants':7},'free_para_18/k_L':{'constants':0.001}
,'free_para_18/k_Lminus':{'constants':1500},'free_para_18/f':{'constants':0.3},'free_para_18/V0':{'constants':-10}}
varLoop = {'clamp_para/V_actTest':{'constants':numpy.array(range(-100, 52, 2))}}
varSave = {'clamp_para/V_actTest':{'constants':True},'output_18/P_o':{'algebraic':True},'output_18/Q':{'algebraic':True}}
simExp.simExp(simfile, savefiles,start, ending, pointInterval,indexStart,indexEnd,varSet,varLoop,varSave)

savefiles=[parent+'\\simulatedData\\simFig13_p']
indexStart = int(200/pointInterval)
indexEnd = int(ending/pointInterval) + 1
varSet = {'clamp_para/t_act':{'constants':200},'free_para_18/K':{'constants':7},'free_para_18/k_L':{'constants':0.003}
,'free_para_18/k_Lminus':{'constants':500},'free_para_18/f':{'constants':0.3},'free_para_18/V0':{'constants':-10}}
varLoop = {'clamp_para/V_actTest':{'constants':numpy.array(range(-100, 52, 2))}}
varSave = {'clamp_para/V_actTest':{'constants':True},'output_18/P_o':{'algebraic':True},'output_18/Q':{'algebraic':True}}
simExp.simExp(simfile, savefiles,start, ending, pointInterval,indexStart,indexEnd,varSet,varLoop,varSave)