Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/development' into add_thread_s…
Browse files Browse the repository at this point in the history
…anitizer
  • Loading branch information
lucafedeli88 committed Jul 4, 2024
2 parents 1a2563a + a1980cf commit 84f881d
Show file tree
Hide file tree
Showing 55 changed files with 422 additions and 408 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/cuda.yml
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ jobs:
which nvcc || echo "nvcc not in PATH!"
git clone https://github.com/AMReX-Codes/amrex.git ../amrex
cd ../amrex && git checkout --detach 1f038e767011e20100af6ab0db02c69cf7ebe55c && cd -
cd ../amrex && git checkout --detach 259db7cfb99e7d1d2ab4bec9b1587fdf624a138a && cd -
make COMP=gcc QED=FALSE USE_MPI=TRUE USE_GPU=TRUE USE_OMP=FALSE USE_FFT=TRUE USE_CCACHE=TRUE -j 4
ccache -s
Expand Down
27 changes: 21 additions & 6 deletions Docs/source/usage/parameters.rst
Original file line number Diff line number Diff line change
Expand Up @@ -581,11 +581,26 @@ Additional PML parameters
Embedded Boundary Conditions
----------------------------

* ``warpx.eb_implicit_function`` (`string`)
A function of `x`, `y`, `z` that defines the surface of the embedded
boundary. That surface lies where the function value is 0 ;
the physics simulation area is where the function value is negative ;
the interior of the embeddded boundary is where the function value is positive.
In WarpX, the embedded boundary can be defined in either of two ways:

- **From an analytical function:**
In that case, you will need to set the following parameter in the input file.

* ``warpx.eb_implicit_function`` (`string`)
A function of `x`, `y`, `z` that defines the surface of the embedded
boundary. That surface lies where the function value is 0 ;
the physics simulation area is where the function value is negative ;
the interior of the embeddded boundary is where the function value is positive.

- **From an STL file:**
In that case, you will need to set the following parameters in the input file.

* ``eb2.stl_file`` (`string`)
The path to an STL file. In addition, you also need to set ``eb2.geom_type = stl``,
in order for the file to be read by WarpX.

Whether the embedded boundary is defined with an analytical function or an STL file, you can
additionally define the electric potential at the embedded boundary with an analytical function:

* ``warpx.eb_potential(x,y,z,t)`` (`string`)
Gives the value of the electric potential at the surface of the embedded boundary,
Expand Down Expand Up @@ -2431,7 +2446,7 @@ Grid types (collocated, staggered, hybrid)
For example, :math:`E_z` is gathered using ``algo.particle_shape`` along :math:`(x,y)` and ``algo.particle_shape - 1`` along :math:`z`.
See equations (21)-(23) of :cite:t:`param-Godfrey2013` and associated references for details.

Default: ``interpolation.galerkin_scheme = 0`` with collocated grids and/or momentum-conserving field gathering, ``interpolation.galerkin_scheme = 1`` otherwise.
Default: ``interpolation.galerkin_scheme = 0`` with collocated grids, or momentum-conserving field gathering, or when ``algo.current_deposition = direct`` ; ``interpolation.galerkin_scheme = 1`` otherwise.

.. warning::

Expand Down
1 change: 1 addition & 0 deletions Examples/Tests/collision/inputs_3d
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ boundary.field_hi = periodic periodic periodic
warpx.serialize_initial_conditions = 1
warpx.verbose = 1
warpx.const_dt = 1.224744871e-07
warpx.random_seed = 2034958209

# Do not evolve the E and B fields
algo.maxwell_solver = none
Expand Down
44 changes: 22 additions & 22 deletions Regression/Checksum/benchmarks_json/Langmuir_multi_2d_MR_psatd.json
Original file line number Diff line number Diff line change
@@ -1,40 +1,40 @@
{
"electrons": {
"particle_momentum_x": 4.2387000553111037e-20,
"particle_momentum_y": 0.0,
"particle_momentum_z": 4.238700039223283e-20,
"particle_position_x": 0.6553599659707846,
"particle_position_y": 0.6553599659699976,
"particle_weight": 3200000000000000.5
},
"lev=0": {
"Bx": 0.0,
"By": 46.86760020196344,
"By": 46.65494014556924,
"Bz": 0.0,
"Ex": 7589330186947.288,
"Ex": 7596470155558.35,
"Ey": 0.0,
"Ez": 7589330198843.742,
"jx": 7283102663077210.0,
"Ez": 7596470167219.471,
"jx": 7277974695617658.0,
"jy": 0.0,
"jz": 7283102630279985.0
"jz": 7277974664068728.0
},
"lev=1": {
"Bx": 0.0,
"By": 369.2209081024592,
"By": 371.2497742366917,
"Bz": 0.0,
"Ex": 7593801203430.788,
"Ex": 7596619292118.433,
"Ey": 0.0,
"Ez": 7593800988021.711,
"jx": 6597471633118175.0,
"Ez": 7596619076137.7295,
"jx": 6592788899529852.0,
"jy": 0.0,
"jz": 6597471447306984.0
"jz": 6592788734672843.0
},
"electrons": {
"particle_momentum_x": 4.2314133085678375e-20,
"particle_momentum_y": 0.0,
"particle_momentum_z": 4.2314132920088513e-20,
"particle_position_x": 0.6553599899254421,
"particle_position_y": 0.6553599899246253,
"particle_weight": 3200000000000000.5
},
"positrons": {
"particle_momentum_x": 4.238670783273887e-20,
"particle_momentum_x": 4.2314444192249906e-20,
"particle_momentum_y": 0.0,
"particle_momentum_z": 4.238670762294589e-20,
"particle_position_x": 0.6553596917214832,
"particle_position_y": 0.6553596917221793,
"particle_momentum_z": 4.231444401040395e-20,
"particle_position_x": 0.655359770013864,
"particle_position_y": 0.6553597700144888,
"particle_weight": 3200000000000000.5
}
}
28 changes: 14 additions & 14 deletions Regression/Checksum/benchmarks_json/Langmuir_multi_2d_psatd.json
Original file line number Diff line number Diff line change
@@ -1,27 +1,27 @@
{
"electrons": {
"particle_momentum_x": 5.663705661977914e-20,
"particle_momentum_y": 0.0,
"particle_momentum_z": 5.663705661977915e-20,
"particle_position_x": 0.65536,
"particle_position_y": 0.6553599999999999,
"particle_weight": 3200000000000000.5
},
"lev=0": {
"Ex": 3771082811318.298,
"Ex": 3751590727260.198,
"Ey": 0.0,
"Ez": 3771082811318.301,
"jx": 1.009365330460902e+16,
"Ez": 3751590727260.1885,
"jx": 1.0100623838390416e+16,
"jy": 0.0,
"jz": 1.009365330460902e+16,
"jz": 1.0100623838390416e+16,
"part_per_cell": 131072.0
},
"positrons": {
"particle_momentum_x": 5.663705661977916e-20,
"particle_momentum_x": 5.668407775012392e-20,
"particle_momentum_y": 0.0,
"particle_momentum_z": 5.663705661977916e-20,
"particle_momentum_z": 5.668407775012392e-20,
"particle_position_x": 0.65536,
"particle_position_y": 0.65536,
"particle_weight": 3200000000000000.5
},
"electrons": {
"particle_momentum_x": 5.668407775012391e-20,
"particle_momentum_y": 0.0,
"particle_momentum_z": 5.668407775012391e-20,
"particle_position_x": 0.65536,
"particle_position_y": 0.6553600000000002,
"particle_weight": 3200000000000000.5
}
}
Original file line number Diff line number Diff line change
@@ -1,29 +1,29 @@
{
"electrons": {
"particle_momentum_x": 5.663705657675969e-20,
"particle_momentum_y": 0.0,
"particle_momentum_z": 5.663705657675969e-20,
"particle_position_x": 0.65536,
"particle_position_y": 0.65536,
"particle_weight": 3200000000000000.5
},
"lev=0": {
"Bx": 0.0,
"By": 3.4892704618136277,
"By": 5.710236645367475,
"Bz": 0.0,
"Ex": 3771082786646.7104,
"Ex": 3751590785149.1333,
"Ey": 0.0,
"Ez": 3771082786646.702,
"jx": 1.0093631772735916e+16,
"Ez": 3751590785149.124,
"jx": 1.0100602372860838e+16,
"jy": 0.0,
"jz": 1.0093631772735912e+16
"jz": 1.0100602372860836e+16
},
"positrons": {
"particle_momentum_x": 5.663705657675971e-20,
"particle_momentum_x": 5.668407759026453e-20,
"particle_momentum_y": 0.0,
"particle_momentum_z": 5.663705657675969e-20,
"particle_position_x": 0.65536,
"particle_momentum_z": 5.668407759026454e-20,
"particle_position_x": 0.6553599999999999,
"particle_position_y": 0.65536,
"particle_weight": 3200000000000000.5
},
"electrons": {
"particle_momentum_x": 5.668407759026452e-20,
"particle_momentum_y": 0.0,
"particle_momentum_z": 5.668407759026452e-20,
"particle_position_x": 0.65536,
"particle_position_y": 0.6553600000000002,
"particle_weight": 3200000000000000.5
}
}
Original file line number Diff line number Diff line change
@@ -1,30 +1,30 @@
{
"electrons": {
"particle_momentum_x": 9.520485222844096e-20,
"particle_position_x": 2.6214400000233367,
"particle_position_y": 2.6214400000233367,
"particle_position_z": 2.6214400000000007,
"particle_weight": 128000000000.00002
},
"lev=0": {
"Bx": 78.90261993791012,
"By": 78.90261993794903,
"Bz": 78.9041393998435,
"Ex": 84580428018688.97,
"Ey": 84580428018688.73,
"Ez": 84580441923246.2,
"F": 685.6927382678912,
"divE": 7.94184911020468e+19,
"jx": 6.007457695701311e+16,
"jy": 6.007457695701312e+16,
"jz": 6.007453636158103e+16,
"Bx": 86.03228226677659,
"By": 86.03228226679013,
"Bz": 86.033798606458,
"Ex": 84659309211473.42,
"Ey": 84659309211473.42,
"Ez": 84659323064827.52,
"F": 700.2020613746595,
"divE": 7.94984970149747e+19,
"jx": 5.999100369888243e+16,
"jy": 5.999100369888247e+16,
"jz": 5.999096310379822e+16,
"part_per_cell": 524288.0,
"rho": 705198439.2596256
"rho": 705877712.4251474
},
"positrons": {
"particle_momentum_z": 9.520479438980041e-20,
"particle_position_x": 2.6214400000233367,
"particle_position_y": 2.6214400000233358,
"particle_momentum_z": 9.508931687286131e-20,
"particle_position_x": 2.621440000034161,
"particle_position_y": 2.6214400000341618,
"particle_position_z": 2.62144
},
"electrons": {
"particle_momentum_x": 9.508937471997448e-20,
"particle_position_x": 2.6214400000341604,
"particle_position_y": 2.621440000034161,
"particle_position_z": 2.6214399999999993,
"particle_weight": 128000000000.00002
}
}
}
Original file line number Diff line number Diff line change
@@ -1,28 +1,28 @@
{
"electrons": {
"particle_momentum_x": 9.633869745818886e-20,
"particle_position_x": 2.621440000001177,
"particle_position_y": 2.6214400000011784,
"particle_position_z": 2.6214400000000007,
"particle_weight": 128000000000.00002
},
"lev=0": {
"Bx": 80.96035538655111,
"By": 80.96035538657691,
"Bz": 80.96271445263956,
"Ex": 84777489275096.88,
"Ey": 84777489275096.88,
"Ez": 84777485856239.4,
"jx": 6.08447015360442e+16,
"jy": 6.084470153604425e+16,
"jz": 6.084470085554113e+16,
"Bx": 88.73949682623977,
"By": 88.73949682627456,
"Bz": 88.74185838578241,
"Ex": 84851140116479.64,
"Ey": 84851140116479.62,
"Ez": 84851136696893.72,
"jx": 6.075773528102969e+16,
"jy": 6.0757735281029736e+16,
"jz": 6.075773460167053e+16,
"part_per_cell": 524288.0,
"rho": 703546536.8089281
"rho": 704298346.5173542
},
"positrons": {
"particle_momentum_z": 9.63386961193585e-20,
"particle_position_x": 2.621440000001177,
"particle_position_y": 2.621440000001179,
"particle_position_z": 2.6214400000000007
"particle_momentum_z": 9.621748455552108e-20,
"particle_position_x": 2.621440000001309,
"particle_position_y": 2.6214400000013076,
"particle_position_z": 2.6214399999999998
},
"electrons": {
"particle_momentum_x": 9.621748589257923e-20,
"particle_position_x": 2.621440000001309,
"particle_position_y": 2.6214400000013076,
"particle_position_z": 2.6214399999999998,
"particle_weight": 128000000000.00002
}
}
16 changes: 8 additions & 8 deletions Regression/Checksum/benchmarks_json/Python_Langmuir.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
{
"lev=0": {
"Ex": 3047094224871324.5,
"jx": 3.294250379355652e+18
},
"electrons": {
"particle_momentum_x": 1.7507165884671642e-17,
"particle_position_x": 10.350911572498216,
"particle_position_y": 10.485760000000003,
"particle_position_z": 10.485760000000003,
"particle_momentum_x": 1.740964347107983e-17,
"particle_position_x": 10.351045542291539,
"particle_position_y": 10.485759999999997,
"particle_position_z": 10.48576,
"particle_weight": 320000000000.00006
},
"lev=0": {
"Ex": 3091324128949712.5,
"jx": 3.3015975627803766e+18
}
}
14 changes: 7 additions & 7 deletions Regression/Checksum/benchmarks_json/Python_Langmuir_2d.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"lev=0": {
"Ex": 53556162492188.62,
"jx": 5.722548841990386e+16
},
"electrons": {
"particle_momentum_x": 1.0449418710231497e-19,
"particle_position_x": 0.0831205701527011,
"particle_position_y": 0.08192,
"particle_momentum_x": 1.0581442023547547e-19,
"particle_position_x": 0.0831038802568349,
"particle_position_y": 0.08191999999999999,
"particle_weight": 8000000000000001.0
},
"lev=0": {
"Ex": 54311177004701.516,
"jx": 5.639670983525456e+16
}
}
Loading

0 comments on commit 84f881d

Please sign in to comment.