Skip to content

Commit

Permalink
Merge pull request #207 from mabarnes/pre-electron-updates
Browse files Browse the repository at this point in the history
Preparation for adding electrons
  • Loading branch information
johnomotani authored Apr 29, 2024
2 parents 1800f80 + 7d3a3f7 commit c0880a5
Show file tree
Hide file tree
Showing 105 changed files with 5,642 additions and 4,178 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,4 @@ makie_postproc.so
plots_postproc.so
precompile-temp
post_processing_input.toml
.DS_Store
4 changes: 2 additions & 2 deletions docs/src/external_sources_notes.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ S_n &= A_n(r,z) \frac{1}{(\pi)^{3/2} (2 T_{\mathrm{source},n} / m_n)^{3/2}} \exp
or in 1V simulations that do not include $v_\perp$, $v_\zeta$, $v_r$ dimensions
```math
\begin{align}
S_i &= A_i(r,z) \frac{1}{sqrt{\pi} \sqrt{2 T_{\mathrm{source},i} / m_i}} \exp\left( -\frac{v_\perp^2}{T_{\mathrm{source},i}} \right) \\
S_n &= A_n(r,z) \frac{1}{sqrt{\pi} \sqrt{2 T_{\mathrm{source},n} / m_n}} \exp\left( -\frac{v_z^2}{T_{\mathrm{source},n}} \right)
S_i &= A_i(r,z) \frac{1}{\sqrt{\pi} \sqrt{2 T_{\mathrm{source},i} / m_i}} \exp\left( -\frac{v_\perp^2}{T_{\mathrm{source},i}} \right) \\
S_n &= A_n(r,z) \frac{1}{\sqrt{\pi} \sqrt{2 T_{\mathrm{source},n} / m_n}} \exp\left( -\frac{v_z^2}{T_{\mathrm{source},n}} \right)
\end{align}
```

Expand Down
2 changes: 1 addition & 1 deletion docs/src/moment_kinetic_equations.md
Original file line number Diff line number Diff line change
Expand Up @@ -1018,7 +1018,7 @@ and for neutrals where several of the ionization terms cancel
& \qquad-\frac{w_{\|,n}}{2}\frac{1}{p_{\|,n}}\left(-\frac{\partial q_{\|,n}}{\partial z}
- R_{in}\left(n_{i}p_{\|,n} - n_{n}p_{\|,i}
- n_{n}n_{i}\left(u_{n} - u_{i}\right)^{2}\right)
+ \int dv_\parallel S_{n} + u_{n}^2\int dv_\parallel v_\parallel^2 S_{n}
+ \int dv_\parallel v_\parallel^2 S_{n} + u_{n}^2\int dv_\parallel S_{n}
+ v_{\mathrm{th},n}w_{\|,n}\frac{\partial p_{\|,n}}{\partial z}\right) \\
& \qquad\left. + \frac{w_{\parallel,n}}{2}\frac{1}{n_{n}}\int dv_\parallel S_{n}
+ \frac{w_{\|,n}^{2}}{2}\frac{v_{\mathrm{th},n}}{n_{n}}\frac{\partial n_{n}}{\partial z}\right]\frac{\partial g_{n}}{\partial w_{\|,n}} \\
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ vperp_discretization = "gausslegendre_pseudospectral"
#vzeta_bc = "periodic"
#vzeta_discretization = "chebyshev_pseudospectral"

#[numerical_dissipation]
#[ion_numerical_dissipation]
#vpa_dissipation_coefficient = 0.0
#vperp_dissipation_coefficient = 0.0
#z_dissipation_coefficient = 0.1
Expand Down
2 changes: 1 addition & 1 deletion examples/geometry/1D-mirror.toml
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ vz_L = 18.0
vz_bc = "both_zero"
vz_discretization = "chebyshev_pseudospectral"

[numerical_dissipation]
[ion_numerical_dissipation]
vpa_dissipation_coefficient = 1.0e-3 #1.0e-2 #1.0e-1
vperp_dissipation_coefficient = 1.0e-3 #1.0e-2 #1.0e-1
force_minimum_pdf_value = 0.0
Expand Down
16 changes: 10 additions & 6 deletions examples/gk-ions/2D-periodic-gk.toml
Original file line number Diff line number Diff line change
Expand Up @@ -73,15 +73,19 @@ vz_L = 18.0
vz_bc = "both_zero"
vz_discretization = "chebyshev_pseudospectral"

[numerical_dissipation]
vpa_dissipation_coefficient = 1.0e-3 #1.0e-2 #1.0e-1
vperp_dissipation_coefficient = 1.0e-3 #1.0e-2 #1.0e-1
#r_disspipation_coefficient = 1.0e-3
#force_minimum_pdf_value = 0.0

[geometry]
#option="1D-mirror"
DeltaB=0.0
option="constant-helical"
pitch=0.1
rhostar= 0.1

[ion_numerical_dissipation]
vpa_dissipation_coefficient = 1.0e-3 #1.0e-2 #1.0e-1
vperp_dissipation_coefficient = 1.0e-3 #1.0e-2 #1.0e-1
#r_disspipation_coefficient = 1.0e-3
#force_minimum_pdf_value = 0.0

[neutral_numerical_dissipation]
moment_dissipation_coefficient = 0.0001
vz_dissipation_coefficient = 0.01
2 changes: 1 addition & 1 deletion examples/numerical-dissipation/num-diss-relaxation.toml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ nwrite = 2000
nwrite_dfns = 2000
split_operators = false

[numerical_dissipation]
[ion_numerical_dissipation]
vpa_dissipation_coefficient = 0.1
vperp_dissipation_coefficient = 0.1
z_dissipation_coefficient = -1.0
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,14 @@ z_width = 0.125
source_strength = 2.0
source_T = 2.0

[numerical_dissipation]
[ion_numerical_dissipation]
vpa_dissipation_coefficient = 1.0e-1
#vpa_dissipation_coefficient = 1.0e-2
#vpa_dissipation_coefficient = 1.0e-3
force_minimum_pdf_value = 0.0

[neutral_numerical_dissipation]
vz_dissipation_coefficient = 1.0e-1
#vz_dissipation_coefficient = 1.0e-2
#vz_dissipation_coefficient = 1.0e-3
force_minimum_pdf_value = 0.0
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,14 @@ z_width = 0.125
source_strength = 2.0
source_T = 2.0

[numerical_dissipation]
[ion_numerical_dissipation]
#vpa_dissipation_coefficient = 1.0e-1
#vpa_dissipation_coefficient = 1.0e-2
#vpa_dissipation_coefficient = 1.0e-3
force_minimum_pdf_value = 0.0

[neutral_numerical_dissipation]
#vz_dissipation_coefficient = 1.0e-1
#vz_dissipation_coefficient = 1.0e-2
#vz_dissipation_coefficient = 1.0e-3
force_minimum_pdf_value = 0.0
Original file line number Diff line number Diff line change
Expand Up @@ -87,8 +87,14 @@ z_width = 0.125
source_strength = 2.0
source_T = 2.0

[numerical_dissipation]
[ion_numerical_dissipation]
#vpa_dissipation_coefficient = 1.0e-1
#vpa_dissipation_coefficient = 1.0e-2
#vpa_dissipation_coefficient = 1.0e-3
force_minimum_pdf_value = 0.0

[neutral_numerical_dissipation]
#vz_dissipation_coefficient = 1.0e-1
#vz_dissipation_coefficient = 1.0e-2
#vz_dissipation_coefficient = 1.0e-3
force_minimum_pdf_value = 0.0
Original file line number Diff line number Diff line change
Expand Up @@ -87,8 +87,14 @@ z_width = 0.125
source_strength = 2.0
source_T = 2.0

[numerical_dissipation]
[ion_numerical_dissipation]
#vpa_dissipation_coefficient = 1.0e-1
#vpa_dissipation_coefficient = 1.0e-2
#vpa_dissipation_coefficient = 1.0e-3
force_minimum_pdf_value = 0.0

[neutral_numerical_dissipation]
#vz_dissipation_coefficient = 1.0e-1
#vz_dissipation_coefficient = 1.0e-2
#vz_dissipation_coefficient = 1.0e-3
force_minimum_pdf_value = 0.0
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ source_strength = 2.0
source_T = 2.0

[numerical_dissipation]
#vpa_dissipation_coefficient = 1.0e-1
#vpa_dissipation_coefficient = 1.0e-2
#vpa_dissipation_coefficient = 1.0e-3
#vz_dissipation_coefficient = 1.0e-1
#vz_dissipation_coefficient = 1.0e-2
#vz_dissipation_coefficient = 1.0e-3
force_minimum_pdf_value = 0.0
6 changes: 5 additions & 1 deletion examples/wall-bc/wall-bc_cheb.toml
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,10 @@ dt = 1.0e-5
nwrite = 1000
split_operators = false

[numerical_dissipation]
[ion_numerical_dissipation]
#vpa_dissipation_coefficient = 1.0e-3 #1.0e-2 #1.0e-1
force_minimum_pdf_value = 0.0

[neutral_numerical_dissipation]
#vz_dissipation_coefficient = 1.0e-3 #1.0e-2 #1.0e-1
force_minimum_pdf_value = 0.0
6 changes: 5 additions & 1 deletion examples/wall-bc/wall-bc_cheb_split1.toml
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,10 @@ dt = 1.0e-5
nwrite = 1000
split_operators = false

[numerical_dissipation]
[ion_numerical_dissipation]
#vpa_dissipation_coefficient = 1.0e-3 #1.0e-2 #1.0e-1
force_minimum_pdf_value = 0.0

[neutral_numerical_dissipation]
#vz_dissipation_coefficient = 1.0e-3 #1.0e-2 #1.0e-1
force_minimum_pdf_value = 0.0
6 changes: 5 additions & 1 deletion examples/wall-bc/wall-bc_cheb_split2.toml
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,10 @@ dt = 1.0e-5
nwrite = 1000
split_operators = false

[numerical_dissipation]
[ion_numerical_dissipation]
#vpa_dissipation_coefficient = 1.0e-3 #1.0e-2 #1.0e-1
force_minimum_pdf_value = 0.0

[neutral_numerical_dissipation]
#vz_dissipation_coefficient = 1.0e-3 #1.0e-2 #1.0e-1
force_minimum_pdf_value = 0.0
6 changes: 5 additions & 1 deletion examples/wall-bc/wall-bc_cheb_split3.toml
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,10 @@ dt = 1.0e-5
nwrite = 1000
split_operators = false

[numerical_dissipation]
[ion_numerical_dissipation]
#vpa_dissipation_coefficient = 1.0e-3 #1.0e-2 #1.0e-1
force_minimum_pdf_value = 0.0

[neutral_numerical_dissipation]
#vz_dissipation_coefficient = 1.0e-3 #1.0e-2 #1.0e-1
force_minimum_pdf_value = 0.0
2 changes: 1 addition & 1 deletion examples/wall-bc/wall-bc_no-neutrals.toml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ z_width = 0.125
source_strength = 8.0
source_T = 1.0

[numerical_dissipation]
[ion_numerical_dissipation]
#vpa_dissipation_coefficient = 1.0e-1
#vpa_dissipation_coefficient = 1.0e-2
#vpa_dissipation_coefficient = 1.0e-3
Expand Down
2 changes: 1 addition & 1 deletion examples/wall-bc/wall-bc_no-neutrals_split1.toml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ z_width = 0.125
source_strength = 8.0
source_T = 1.0

[numerical_dissipation]
[ion_numerical_dissipation]
#vpa_dissipation_coefficient = 1.0e-1
#vpa_dissipation_coefficient = 1.0e-2
#vpa_dissipation_coefficient = 1.0e-3
Expand Down
2 changes: 1 addition & 1 deletion examples/wall-bc/wall-bc_no-neutrals_split2.toml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ z_width = 0.125
source_strength = 8.0
source_T = 1.0

[numerical_dissipation]
[ion_numerical_dissipation]
#vpa_dissipation_coefficient = 1.0e-1
#vpa_dissipation_coefficient = 1.0e-2
#vpa_dissipation_coefficient = 1.0e-3
Expand Down
2 changes: 1 addition & 1 deletion examples/wall-bc/wall-bc_no-neutrals_split3.toml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ z_width = 0.125
source_strength = 8.0
source_T = 1.0

[numerical_dissipation]
[ion_numerical_dissipation]
#vpa_dissipation_coefficient = 1.0e-1
#vpa_dissipation_coefficient = 1.0e-2
#vpa_dissipation_coefficient = 1.0e-3
Expand Down
8 changes: 7 additions & 1 deletion examples/wall-bc/wall-bc_volumerecycle.toml
Original file line number Diff line number Diff line change
Expand Up @@ -84,12 +84,18 @@ active = true
source_type = "recycling"
recycling_controller_fraction = 0.25

[numerical_dissipation]
[ion_numerical_dissipation]
#vpa_dissipation_coefficient = 1.0e-1
#vpa_dissipation_coefficient = 1.0e-2
#vpa_dissipation_coefficient = 1.0e-3
#force_minimum_pdf_value = 0.0

[neutral_numerical_dissipation]
#vz_dissipation_coefficient = 1.0e-1
#vz_dissipation_coefficient = 1.0e-2
#vz_dissipation_coefficient = 1.0e-3
force_minimum_pdf_value = 0.0

[krook_collisions]
use_krook = true
frequency_option = "reference_parameters"
8 changes: 7 additions & 1 deletion examples/wall-bc/wall-bc_volumerecycle_split1.toml
Original file line number Diff line number Diff line change
Expand Up @@ -84,12 +84,18 @@ active = true
source_type = "recycling"
recycling_controller_fraction = 0.25

[numerical_dissipation]
[ion_numerical_dissipation]
#vpa_dissipation_coefficient = 1.0e-1
#vpa_dissipation_coefficient = 1.0e-2
#vpa_dissipation_coefficient = 1.0e-3
#force_minimum_pdf_value = 0.0

[neutral_numerical_dissipation]
#vz_dissipation_coefficient = 1.0e-1
#vz_dissipation_coefficient = 1.0e-2
#vz_dissipation_coefficient = 1.0e-3
#force_minimum_pdf_value = 0.0

[krook_collisions]
use_krook = true
frequency_option = "reference_parameters"
8 changes: 7 additions & 1 deletion examples/wall-bc/wall-bc_volumerecycle_split2.toml
Original file line number Diff line number Diff line change
Expand Up @@ -84,12 +84,18 @@ active = true
source_type = "recycling"
recycling_controller_fraction = 0.25

[numerical_dissipation]
[ion_numerical_dissipation]
#vpa_dissipation_coefficient = 1.0e-1
#vpa_dissipation_coefficient = 1.0e-2
#vpa_dissipation_coefficient = 1.0e-3
#force_minimum_pdf_value = 0.0

[neutral_numerical_dissipation]
#vz_dissipation_coefficient = 1.0e-1
#vz_dissipation_coefficient = 1.0e-2
#vz_dissipation_coefficient = 1.0e-3
#force_minimum_pdf_value = 0.0

[krook_collisions]
use_krook = true
frequency_option = "reference_parameters"
8 changes: 7 additions & 1 deletion examples/wall-bc/wall-bc_volumerecycle_split3.toml
Original file line number Diff line number Diff line change
Expand Up @@ -84,12 +84,18 @@ active = true
source_type = "recycling"
recycling_controller_fraction = 0.25

[numerical_dissipation]
[ion_numerical_dissipation]
#vpa_dissipation_coefficient = 1.0e-1
#vpa_dissipation_coefficient = 1.0e-2
#vpa_dissipation_coefficient = 1.0e-3
force_minimum_pdf_value = 0.0

[neutral_numerical_dissipation]
#vz_dissipation_coefficient = 1.0e-1
#vz_dissipation_coefficient = 1.0e-2
#vz_dissipation_coefficient = 1.0e-3
force_minimum_pdf_value = 0.0

[krook_collisions]
use_krook = true
frequency_option = "reference_parameters"
2 changes: 1 addition & 1 deletion machines/marconi/julia.env
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

module purge
module load env-skl profile/base profile/advanced
module load gnu/7.3.0 openmpi/3.1.4--gnu--7.3.0 intel/pe-xe-2018--binary python/3.9.4
module load gnu/7.3.0 openmpi/3.1.4--gnu--7.3.0 intel/pe-xe-2018--binary python/3.9.4 git/2.17
# Needed because Julia's Cairo library complains about libz<1.2.9
module load zlib/1.2.11--intel--pe-xe-2018--binary

Expand Down
Loading

0 comments on commit c0880a5

Please sign in to comment.