Hi,
I am trying to add electrodes to start stimulation on a 2D mesh. The main code I am using is from the reentry induction example. It was successful in some areas of the mesh, but in some other area of the mesh, when I tried to add electrodes, I got this error message:
L3 : Warning: openCARP requires input vtx indices to be of from the input mesh, i.e. of type "extra".
L5 : Stimulus 0: Specified vertices are not in stimulus domain! Aborting!
Could you help me understand why this error occurred? Also, I wonder what the stimulus domain means, was it defined somewhere?
Here are some parameters I used:
cmd = tools.carp_cmd(os.path.join(EXAMPLE_DIR, 'parameters.par'))
cmd += ['-num_gregions', 2,
'-gregion[0].num_IDs ', 2,
'-gregion[0].ID[0]', 1,
'-gregion[0].ID[1]', 2,
'-gregion[0].g_il ', args.giL,
'-gregion[0].g_it ', args.giL,
'-gregion[0].g_in ', args.giL,
'-gregion[0].g_el ', args.geL,
'-gregion[0].g_et ', args.geL,
'-gregion[0].g_en ', args.geL,
'-gregion[1].num_IDs ', 1,
'-gregion[1].ID[0]', 3,
'-gregion[1].g_il ', 0.0001,
'-gregion[1].g_it ', 0.0001,
'-gregion[1].g_in ', 0.0001,
'-gregion[1].g_el ', 0.0001,
'-gregion[1].g_et ', 0.0001,
'-gregion[1].g_en ', 0.0001]
stimNum = ['-num_stim',1]
stim_test = ['-stimulus[0].stimtype', 0,
'-stimulus[0].strength', 2500.0,
'-stimulus[0].duration', 5.0,
'-stimulus[0].start', 0,
'-stimulus[0].npls', 1,
'-stimulus[0].vtx_file', 'stim_test']
In parameters.par:
dt = 20 # in microseconds
timedt = 50 # console dt
spacedt = 1 # output dt
tend = 10000.1
experiment = 0
parab_solve = 1
mass_lumping = 0
bidomain = 0
num_imp_regions = 2
imp_region[0].name = "LA"
imp_region[0].im = Courtemanche
imp_region[0].im_param = "GCaL*75%,GK1+100%,factorGKur-50%,Gto*75%,GKs*67%,maxIpCa+50%,maxINaCa+60%,GKr*2.4"
imp_region[0].num_IDs = 1
imp_region[0].ID = 1
imp_region[1].name = "Fibrotic tissue with ionic changes"
imp_region[1].im = Courtemanche
imp_region[1].im_param = "GCaL*0.225,GNa*0.6,factorGKur-50%,Gto-65%,GKs+100%,maxIpCa+50%,maxINaCa+60%,GKr*1.6"
imp_region[1].num_IDs = 2
imp_region[1].ID = 2 3
In stim_test.vtx:
1
intra
26000 13600 0
Additionally, is there a function where I could get the coordinates of certain points on the mesh? How are the coordinates defined in a mesh?