forked from dschwoerer/hermes-2
-
Notifications
You must be signed in to change notification settings - Fork 1
/
template_inputfile.inp
350 lines (242 loc) · 6.33 KB
/
template_inputfile.inp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
nout = 1000
timestep = 1e-1
grid = "cor_islanddivertor_260_4_1024_6.0_1.0_0.8_0.4_0.1_0.875_0.0_0.0_0.0.fci.grid.nc"
[mesh]
symmetricGlobalX = true
extrapolate_y = false # Extrapolate metrics into Y boundary cells?
[mesh:paralleltransform]
type = fci
[input]
error_on_unused_options=false
[restart_files]
init_missing = true # initialize missing variables on restart?
##################################################
# derivative methods
[ddx]
first = C2
second = C2
upwind = W3
[ddy]
first = C2
second = C2
upwind = W3
[ddz]
first = C2
second = C2
upwind = W3
###################################################
# Time-integration solver
[solver]
# Note: If evolving neutrals, need preconditioning
type = cvode
#use_precon = true
atol = 1.0e-12 # absolute tolerance
rtol = 1.0e-5 # relative tolerance
mxstep = 1000000 # Maximum internal steps per output
cvode_max_order = 2
cvode_stability_limit_detection = true
########################################################################################
[phiSolver]
type = petsc # Needed if Boussinesq = false
ksptype = gmres # Linear iterative method
pctype = hypre # Preconditioner. Direct "lu" or "ilu"; iterative "jacobi", "sor"
atol=1e-12
rtol = 1e-5
# Set package to perform factorisation for direct solves
# "petsc" built-in solver only serial
# "superlu", "superlu_dist", "mumps", "cusparse"
factor_package = superlu_dist
inner_boundary_flags = 2
outer_boundary_flags = 16
all_terms = false
nonuniform = true # NOTE: Necessary to avoid numerical instability
#########################################################################################
[aparSolver]
type = petsc
rtol=1e-5
atol=1e-12
# ksptype = gmres # Linear iterative method
# pctype = hypre # Preconditioner. Direct "lu" or "ilu"; iterative "jacobi", "sor"
# # Set package to perform factorisation for direct solves
# # "petsc" built-in solver only serial
# # "superlu", "superlu_dist", "mumps", "cusparse"
# factor_package = superlu_dist
inner_boundary_flags = 2
outer_boundary_flags = 2
# all_terms = true
# nonuniform = true
# general settings for the model
[input]
transform_from_field_aligned=False
[Hermes]
electromagnetic = true
j_pol_pi = false
j_pol_simplified = true
boussinesq = true
FiniteElMass = true
evolve_ne = true
evolve_nvi = true
evolve_te = true
evolve_ti = true
evolve_vort = true
evolve_vepsi = true
TE_Ne = true
TE_NVi = true
TE_Pe = true
TE_Pi = true
TE_Vort = true
TE_VePsi = true
verbose = true
output_ddt = false
Tnorm = 20
Nnorm = 1e19
Bnorm = 1.0
AA = 2.0
[Transportcoefficients]
anomalous_D = 0.1
anomalous_nu = 0.1
anomalous_chi = 0.1
hyper_D = 1e-4
hyper_nu = 1e-4
hyper_chi = 1e-4
num_D = 1e-2
num_nu = 1e-2
num_chi = 1e-10
[Numerics]
use_Div_n_bxGrad_f_B_XPPM = true
use_bracket = true
ne_bndry_flux = false
pe_bndry_flux = false
vort_bndry_flux = false
flux_limit_alpha = -1
kappa_limit_alpha = -1
eta_limit_alpha = -1
resistivity_multiply = 1.0
electron_weight = 1.0
scale_ExB = 1.0
[Sheath]
sheath_model = 0
sheath_gamma_e = 6.0
sheath_gamma_i = 3.5
parallel_sheaths = true
sheath_allow_supersonic = true
########################################################################################
########################################################################################
########################################################################################
########################################################################################
########################################################################################
[all]
bndry_all = neumann_o2
bndry_xin = neumann_o2
bndry_xout =neumann_o2
bndry_par_all = parallel_neumann_o2
########################################################################################
[Ne] # Electron density
bndry_xin = neumann
bndry_xout =neumann
bndry_par = parallel_neumann_o1
scale = 1
function = 2.0 - x
source = 3e2*gauss(x, 0.24)
#Switches for terms
Ne_ExB = true
Ne_mag = true
Ne_parflow = true
Ne_collision = false
Ne_anomalous = true
Ne_sources = true
Ne_hyper = false
Ne_numdiff = true
########################################################################################
[NVi]
bndry_xin = neumann
bndry_xout =neumann
bndry_par = parallel_neumann_o1
scale = 1
function = 1e-2*sin(6*pi*x)*sin(12*z)*gauss(x,0.4)
#Switches for terms
NVi_ExB = true
NVi_mag = true
NVi_parflow = true
NVi_parpressure = true
NVi_parviscos = false
NVi_collision = false
NVi_anomalous = true
NVi_hyper = false
NVi_numdiff = true
########################################################################################
[Pe] # Electron pressure
bndry_xin = neumann
bndry_xout =neumann
bndry_par_xin = parallel_neumann_o1
scale = 1
function = Ne:function + (2.0-x)*Ne:function
source = 5.0*Ne:source
#Switches for terms
Pe_ExB = true
Pe_mag = true
Pe_parflow = true
Pe_conduction = true
Pe_ohmic = true
Pe_thermalforce = true
Pe_thermalcurrent = true
Pe_collision = false
Pe_anomalous = true
Pe_sources = true
Pe_energyexchange = true
Pe_hyper = false
Pe_numdiff = false
####################################################################################
[Pi]
bndry_xin = neumann
bndry_xout =neumann
bndry_par = parallel_neumann_o1
scale = 1
function = Pe:function
source = Pe:source
#Switches for terms
Pi_ExB = true
Pi_mag = true
Pi_parflow = true
Pi_conduction = true
Pi_diamagenergyexchange = true
Pi_parviscousheat = true
Pi_resistivedrift = false
Pi_perpviscous = false
Pi_sources = true
Pi_hyper =false
Pi_numdiff = false
Pi_anomalous = true
Pi_energyexchange = true
####################################################################################
[Vort]
bndry_xin = neumann
bndry_xout =neumann
bndry_par = parallel_neumann_o1
scale=1.0
function=1e-3*sin(14*pi*x)*sin(8*z)*gauss(x,0.4)
#Switches for terms
Vort_mag = true
Vort_parcurrent = true
Vort_polarcurrent = true
Vort_collision = false
Vort_parviscous = false
Vort_anomalous = true
Vort_hyper = false
Vort_numdiff = true
########################################################################################
[VePsi] # Ve + 0.5*beta_e*mi_me*psi
bndry_xin = neumann
bndry_xout =neumann
bndry_par = parallel_neumann_o1
scale = 1
function = 1e-1*sin(14*pi*x)*sin(8*z)*gauss(x,0.4)
#Switches for terms
VePsi_parefield = true
VePsi_parpressure = true
VePsi_partemp = true
VePsi_parcurrent = true
VePsi_ExB = true
VePsi_parflow = true
VePsi_hyper = true
VePsi_numdiff = true