# Parameters file for the S1-S2 Actors Study (S1)
# Mesh Needs to be generated first by Carputils


meshname = /code/openCARP-Actors/simulations/Joyce_Sep26_4x4x025mm-input/meshes/4x4x025_mesh/block


############### physical regions ##############
num_phys_regions     = 2
phys_region[0].name  = "Intracellular domain"
phys_region[0].ptype = 0 
phys_region[0].num_IDs = 1
phys_region[0].ID[0] = 1
phys_region[1].name  = "Extracellular domain"
phys_region[1].ptype = 1
phys_region[1].num_IDs = 1
phys_region[1].ID[0] = 1

############### ionic setup ###################
num_imp_regions      = 1
imp_region[0].im     = Shannon


############## stimulus setup #################
num_stim             =      2
stimulus[0].name     = "S1"
stimulus[0].stimtype =      1 
stimulus[0].duration =      2.
stimulus[0].start    =      0.
stimulus[0].npls     =      1
stimulus[0].x0       = -12.5 #in um
stimulus[0].xd       = 248.6 #thickness in um
stimulus[0].y0       = -12.5
stimulus[0].yd       = 248.6
stimulus[0].z0       = 12.5
stimulus[0].zd       = 25.0

stimulus[1].name     = "Ground"
stimulus[1].stimtype =      3
stimulus[1].x0       = -12.5
stimulus[1].xd       = 4025.0
stimulus[1].y0       = -12.5
stimulus[1].yd       = 4025.0
stimulus[1].z0       = -12.5
stimulus[1].zd       = 25.0


################# Simulation parameters #################
bidomain = 1 
tend    =  70. 
spacedt = 1.0 
timedt = 1.0
parab_solve = 1


############# Notes #############
# S1-S2 script params to start with:
# S1 min = 1.0e7
# S1 max = 3.0e7
# (Actual S1 threshold = 28,167,114)
# Absolute S2 max = 3.0e8 (could go higher if needed, it depends when the solution blows up.)
# S1S2_interval_min=185
# S1S2_interval_max=205 (If it is still refractory here, we can extend the range. If it is not, 
#                       we can extend it in the other direction by lowering min.)
# S1S2_interval_increment=1
# This interval range is subject to change...I have it so that we find 20 data points, 
# but I don't know what the proper min and max is for this setup yet. 
# tol = 1 
# So far I have tolerance at 1, but because we are working on a much larger scale, we could probably
# increase this number quite a bit if needed.
# Sample points - 2 in bottom left, 2 in bottom right, 2 close to centre, 4 in top left, 4 in top right.
# E.g.:  Bottom Left = (2, 2, 0.5), (2, 2, 1.5)
#        Bottom Right = (8, 8, 0.5), (8, 8, 1.5)
#        Centre       = (3.5, 5, 0.5), (6.5, 5, 1.5)
#        Top Left     = (0, 10, 0.5), (0, 10, 1.5), (0.5, 9.5, 0.25), (0.5, 9.5, 1.75)
#        Top Right    = (10, 10, 0.5), (10, 10, 1.5), (9.5, 9.5, 0.25), (9.5, 9.5, 1.75)
# These are somewhat arbitrary, we will need to test these out and see how they go.
# Also, it is unlikely that these exact coordinates are vertices. This is okay, however, in the paper,
# we should put what the actual coordinates are.