Skip to content

Commit 709cdb0

Browse files
KZhu-MEax3l
authored andcommitted
Add 2D circle EB test (BLAST-WarpX#2538)
* Added embedded_circle test * Add embedded_circle test files * Removed diag files * removed PICMI input file * Update to use default regression analysis * Added line breaks for spacing * Added description * Fixed benchmark file * Added load balancing to test * Commented out load_balancing portion of test. This will be added back in once load balancing is fixed. Co-authored-by: Axel Huebl <[email protected]>
1 parent afc8124 commit 709cdb0

File tree

3 files changed

+137
-0
lines changed

3 files changed

+137
-0
lines changed
Lines changed: 92 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,92 @@
1+
# This is a 2D electrostatic simulation containing a circle embedded boundary at
2+
# the center of the grid domain, pre -seeded with equal density of argon ions
3+
# and electrons.
4+
5+
max_step = 11
6+
warpx.const_dt = 3.99e-13
7+
warpx.do_electrostatic = labframe
8+
warpx.self_fields_required_precision = 1e-06
9+
warpx.eb_implicit_function = -((x-0.00005)**2+(z-0.00005)**2-1e-05**2)
10+
warpx.eb_potential(x,y,z,t) = -10
11+
warpx.self_fields_absolute_tolerance = 0.02
12+
13+
# algo.load_balance_intervals = 5
14+
# algo.load_balance_efficiency_ratio_threshold = 1.001
15+
# algo.load_balance_with_sfc = 0
16+
# algo.load_balance_knapsack_factor = 2
17+
18+
amr.n_cell = 128 128
19+
amr.max_grid_size = 16
20+
amr.max_level = 0
21+
geometry.coord_sys = 0
22+
geometry.prob_lo = 0.0 0.0
23+
geometry.prob_hi = 0.0001 0.0001
24+
boundary.field_lo = pec periodic
25+
boundary.field_hi = pec periodic
26+
boundary.particle_lo = absorbing periodic
27+
boundary.particle_hi = absorbing periodic
28+
algo.particle_shape = 1
29+
30+
particles.species_names = electrons ar_ions
31+
electrons.mass = m_e
32+
electrons.charge = -q_e
33+
electrons.injection_style = nuniformpercell
34+
electrons.initialize_self_fields = 1
35+
electrons.num_particles_per_cell_each_dim = 2 2
36+
electrons.density = 10.2e16
37+
electrons.momentum_distribution_type = gaussian
38+
electrons.profile = constant
39+
electrons.ux_m = 0.0
40+
electrons.uy_m = 0.0
41+
electrons.uz_m = 0.0
42+
electrons.ux_th = 0.0022492462021094224
43+
electrons.uy_th = 0.0022492462021094224
44+
electrons.uz_th = 0.0022492462021094224
45+
electrons.save_particles_at_zlo = 1
46+
electrons.save_particles_at_zhi = 1
47+
electrons.save_particles_at_eb = 1
48+
ar_ions.mass = 6.633520326333601e-26
49+
ar_ions.charge = q_e
50+
ar_ions.injection_style = nuniformpercell
51+
ar_ions.initialize_self_fields = 1
52+
ar_ions.num_particles_per_cell_each_dim = 2 2
53+
ar_ions.profile = constant
54+
ar_ions.density = 10.2e16
55+
ar_ions.momentum_distribution_type = gaussian
56+
ar_ions.ux_m = 0.0
57+
ar_ions.uy_m = 0.0
58+
ar_ions.uz_m = 0.0
59+
ar_ions.ux_th = 2.6285641070031447e-06
60+
ar_ions.uy_th = 2.6285641070031447e-06
61+
ar_ions.uz_th = 2.6285641070031447e-06
62+
ar_ions.save_particles_at_zlo = 1
63+
ar_ions.save_particles_at_zhi = 1
64+
ar_ions.save_particles_at_eb = 1
65+
66+
collisions.collision_names = coll_electrons coll_ar_ions
67+
coll_electrons.type = background_mcc
68+
coll_electrons.species = electrons
69+
coll_electrons.background_density = 2.1458888524486985e+23
70+
coll_electrons.background_temperature = 450.00000000000006
71+
coll_electrons.background_mass = 6.633520326333601e-26
72+
coll_electrons.scattering_processes = excitation1 elastic ionization
73+
coll_electrons.excitation1_cross_section = ../../../../warpx-data/MCC_cross_sections/Ar/excitation_1.dat
74+
coll_electrons.excitation1_energy = 11.5
75+
coll_electrons.elastic_cross_section = ../../../../warpx-data/MCC_cross_sections/Ar/electron_scattering.dat
76+
coll_electrons.ionization_cross_section = ../../../../warpx-data/MCC_cross_sections/Ar/ionization.dat
77+
coll_electrons.ionization_energy = 15.7596112
78+
coll_electrons.ionization_species = ar_ions
79+
coll_ar_ions.type = background_mcc
80+
coll_ar_ions.species = ar_ions
81+
coll_ar_ions.background_density = 2.1458888524486985e+23
82+
coll_ar_ions.background_temperature = 450.00000000000006
83+
coll_ar_ions.scattering_processes = back elastic charge_exchange
84+
coll_ar_ions.back_cross_section = ../../../../warpx-data/MCC_cross_sections/Ar/ion_back_scatter.dat
85+
coll_ar_ions.elastic_cross_section = ../../../../warpx-data/MCC_cross_sections/Ar/ion_scattering.dat
86+
coll_ar_ions.charge_exchange_cross_section = ../../../../warpx-data/MCC_cross_sections/Ar/charge_exchange.dat
87+
88+
diagnostics.diags_names = diag1
89+
diag1.diag_type = Full
90+
diag1.format = plotfile
91+
diag1.intervals = 1
92+
diag1.fields_to_plot = phi rho_electrons rho_ar_ions
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
{
2+
"ar_ions": {
3+
"particle_cpu": 31740.0,
4+
"particle_id": 3219770578.0,
5+
"particle_momentum_x": 2.661332598290843e-18,
6+
"particle_momentum_y": 2.6484537197836753e-18,
7+
"particle_momentum_z": 2.6446763485694346e-18,
8+
"particle_position_x": 3.174118714858889,
9+
"particle_position_y": 3.174074331596828,
10+
"particle_weight": 988031616.2109375
11+
},
12+
"electrons": {
13+
"particle_cpu": 30737.0,
14+
"particle_id": 1041042475.0,
15+
"particle_momentum_x": 3.014851468379113e-20,
16+
"particle_momentum_y": 3.016132024233842e-20,
17+
"particle_momentum_z": 3.0169481587733156e-20,
18+
"particle_position_x": 3.0760407489559514,
19+
"particle_position_y": 3.072305059445631,
20+
"particle_weight": 956794738.7695312
21+
},
22+
"lev=0": {
23+
"phi": 56888.72655917703,
24+
"rho_ar_ions": 257.78992245244984,
25+
"rho_electrons": 250.2854445348176
26+
}
27+
}

Regression/WarpX-tests.ini

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2245,6 +2245,24 @@ compareParticles = 0
22452245
analysisRoutine = Examples/Tests/ElectrostaticSphere/analysis_electrostatic_sphere.py
22462246
tolerance = 1.e-12
22472247

2248+
[embedded_circle]
2249+
buildDir = .
2250+
inputFile = Examples/Tests/embedded_circle/inputs_2d
2251+
runtime_params =
2252+
dim = 2
2253+
addToCompileString = USE_EB=TRUE
2254+
restartTest = 0
2255+
useMPI = 1
2256+
numprocs = 2
2257+
useOMP = 1
2258+
numthreads = 1
2259+
compileTest = 0
2260+
doVis = 0
2261+
compareParticles = 1
2262+
particleTypes = electrons ar_ions
2263+
analysisRoutine = Examples/analysis_default_regression.py
2264+
tolerance = 1.e-12
2265+
22482266
[initial_distribution]
22492267
buildDir = .
22502268
inputFile = Examples/Tests/initial_distribution/inputs

0 commit comments

Comments
 (0)