- Author:
- WeiweiAi <wai484@aucklanduni.ac.nz>
- Date:
- 2022-07-28 12:05:55+12:00
- Desc:
- Fixed the link
- Permanent Source URI:
- https://models.physiomeproject.org/workspace/8af/rawfile/1b1a07491a4d102536a3f7e25957ca2810d6ed76/Simulation/src/simFig14.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, 400, 0.01
savefiles=[None]*len([-40,-20])
for i in range(len([-40,-20])):
savefiles[i]=parent+'\\simulatedData\\simFig14_r_'+'%d' %i
indexStart = int(200/pointInterval)
indexEnd = int(ending/pointInterval) + 1
varSet = {'clamp_para/t_act':{'constants':80},'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([-40,-20])}}
varSave = {'t':{'voi':False},'output_18/dQ':{'algebraic':False},'output_18/P_o':{'algebraic':False},'output_18/Q':{'algebraic':False}}
simExp.simExp(simfile, savefiles,start, ending, pointInterval,indexStart,indexEnd,varSet,varLoop,varSave)
savefiles=[None]*len([-40,-20])
for i in range(len([-40,-20])):
savefiles[i]=parent+'\\simulatedData\\simFig14_p_'+'%d' %i
indexStart = int(200/pointInterval)
indexEnd = int(ending/pointInterval) + 1
varSet = {'clamp_para/t_act':{'constants':80},'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([-40,-20])}}
varSave = {'t':{'voi':False},'output_18/dQ':{'algebraic':False},'output_18/P_o':{'algebraic':False},'output_18/Q':{'algebraic':False}}
simExp.simExp(simfile, savefiles,start, ending, pointInterval,indexStart,indexEnd,varSet,varLoop,varSave)