Skip to content

Commit 151b5a3

Browse files
authored
Merge pull request #146 from ajnonaka/two_layers
Two layers
2 parents b6fb83a + 87d9719 commit 151b5a3

File tree

1 file changed

+32
-22
lines changed

1 file changed

+32
-22
lines changed

Examples/Tests/circuits/Candice/inputs_candice20

Lines changed: 32 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,14 @@
1-
# See parameters in https://github.com/ECP-WarpX/artemis/pull/43
2-
31
################################
42
####### GENERAL PARAMETERS ######
53
#################################
6-
max_step = 1
4+
max_step = 5000000
75

86
amr.n_cell = n_cellx n_celly n_cellz
97
amr.max_grid_size_x = max_grid_sizex
108
amr.max_grid_size_y = max_grid_sizey
119
amr.max_grid_size_z = max_grid_sizez
1210
amr.blocking_factor = blocking_factor
13-
amr.refine_grid_layout = 1 # if n_MPI > n_grids, the grids will be successively divided in half until n_MPI <= n_grids
11+
amr.refine_grid_layout = 0 # if n_MPI > n_grids, the grids will be successively divided in half until n_MPI <= n_grids
1412

1513
geometry.dims = 3
1614
geometry.prob_lo = prob_lox prob_loy prob_loz
@@ -22,27 +20,25 @@ amr.max_level = 0
2220
boundary.field_lo = pml pml pml
2321
boundary.field_hi = pml pml pml
2422

25-
my_constants.offset_y = -1100.e-6
26-
2723
#################################
2824
############ NUMERICS ###########
2925
#################################
3026
warpx.verbose = 1
3127

32-
warpx.cfl = 0.8
28+
warpx.cfl = 0.6
3329

3430
# vacuum or macroscopic
3531
algo.em_solver_medium = macroscopic
3632

3733
# laxwendroff or backwardeuler
3834
algo.macroscopic_sigma_method = laxwendroff
3935

40-
macroscopic.sigma_function(x,y,z) = "sigma_0 + (sigma_si - sigma_0) * (z <= h_si)"
41-
macroscopic.epsilon_function(x,y,z) = "eps_0 + eps_0 * (eps_r_si - 1.) * (z <= h_si)"
42-
macroscopic.mu_function(x,y,z) = "mu_0 + mu_0 * (mu_r_si - 1.) * (z <= h_si)"
36+
macroscopic.sigma_function(x,y,z) = "sigma_0"
37+
macroscopic.epsilon_function(x,y,z) = "eps_0 + eps_0 * (eps_r_si - 1.) * (z <= h_bot) + eps_0 * (eps_r_si - 1.) * (z >= h_top)"
38+
macroscopic.mu_function(x,y,z) = "mu_0"
4339

44-
macroscopic.npy_k_index = 0
45-
macroscopic.npy_k_index2 = 3
40+
macroscopic.npy_k_index = 98 # should be n_cellz/2-"3um"
41+
macroscopic.npy_k_index2 = 100 # should be n_cellz/2
4642

4743
# comment for PEC, uncomment these for GDS-PEC
4844
macroscopic.sigma_npy_file = "voyageurs_layer1.npy"
@@ -52,7 +48,7 @@ algo.use_PEC_mask = 1
5248

5349
macroscopic.mu_npy_file = "voyageurs_layer1.npy"
5450
macroscopic.mu_npy_file2 = "voyageurs_layer2.npy"
55-
macroscopic.mu_npy_value = 1.25663706e-06
51+
macroscopic.mu_npy_value = 1.25663707e-06
5652

5753
#################################
5854
############ FIELDS #############
@@ -64,11 +60,11 @@ macroscopic.mu_npy_value = 1.25663706e-06
6460
###############
6561
my_constants.n_cellx = 7544
6662
my_constants.n_celly = 7544
67-
my_constants.n_cellz = 4
63+
my_constants.n_cellz = 200
6864

6965
my_constants.max_grid_sizex = 92
7066
my_constants.max_grid_sizey = 92
71-
my_constants.max_grid_sizez = 4
67+
my_constants.max_grid_sizez = 200
7268
my_constants.blocking_factor = 2
7369

7470
my_constants.prob_lox = 0.
@@ -96,17 +92,18 @@ my_constants.mu_0 = 1.25663706212e-06
9692
my_constants.mu_r_si = 1.0
9793

9894
###############
99-
# silicon and palladium cross section
95+
# layer heights
10096
###############
101-
my_constants.h_si = 150.e-6
97+
my_constants.h_top = 150.e-6
98+
my_constants.h_bot = 147.e-6
10299

103100
###############
104101
# derived quantities and fundamental constants - don't touch these
105102
###############
106103

107104
my_constants.pi = 3.14159265358979
108105

109-
my_constants.freq = 8.6e9
106+
my_constants.freq = 7.5e9
110107
my_constants.TP = 1./freq
111108

112109
# grid spacing
@@ -129,13 +126,16 @@ my_constants.flag_ss = 2
129126
warpx.E_excitation_on_grid_style = parse_E_excitation_grid_function
130127

131128
warpx.Ex_excitation_flag_function(x,y,z) = "flag_none"
132-
warpx.Ey_excitation_flag_function(x,y,z) = "flag_ss * 0"
129+
# thin excitation
130+
warpx.Ey_excitation_flag_function(x,y,z) = "flag_ss * ( (y >= 702.5e-6 + ddy) * (y <= 712.5e-6 - ddy) + (y >= 717.5e-6 + ddy) * (y <= 727.5e-6 - ddy)) * (z > h_top - ddz) * (z < h_top + ddz) * (x > 162.5e-6 - ddx) * (x < 162.5e-6 + ddx)"
133131
warpx.Ez_excitation_flag_function(x,y,z) = "flag_none"
134132

135133

136134
# This is a source on a qubit control line
137135
warpx.Ex_excitation_grid_function(x,y,z,t) = "0."
138-
warpx.Ey_excitation_grid_function(x,y,z,t) = "0."
136+
# thin excitation
137+
warpx.Ey_excitation_grid_function(x,y,z,t) = "exp(-(t-3*TP)**2/(2*TP**2))*sin(2*pi*freq*t) *
138+
( (y >= 702.5e-6 + ddy) * (y <= 712.5e-6 - ddy) - (y >= 717.5e-6 + ddy) * (y <= 727.5e-6 - ddy)) * (z > h_top - ddz) * (z < h_top + ddz) * (x > 162.5e-6 - ddx) * (x < 162.5e-6 + ddx)"
139139
warpx.Ez_excitation_grid_function(x,y,z,t) = "0."
140140

141141
###############
@@ -145,10 +145,20 @@ warpx.Ez_excitation_grid_function(x,y,z,t) = "0."
145145
warpx.field_io_nfiles=64
146146
warpx.particle_io_nfiles=64
147147

148-
diagnostics.diags_names = plt
148+
diagnostics.diags_names = plt chk
149149
###############
150150
# full plotfiles
151-
plt.intervals = 1
151+
plt.intervals = 1000
152152
plt.fields_to_plot = Ex Ey Ez Bx By Bz mu
153153
plt.diag_type = Full
154154
plt.file_min_digits = 7
155+
plt.diag_lo = 0. 0. 145.51e-6
156+
plt.diag_hi = 9430.e-6 9430.e-6 151.49e-6
157+
158+
chk.intervals = 100000
159+
chk.diag_type = Full
160+
chk.format = checkpoint
161+
chk.file_min_digits = 7
162+
163+
# if you restart, remove mu, sigma, and epsilon from plotfile
164+
#amr.restart = diags/chk0100000

0 commit comments

Comments
 (0)