|
WarpX
|
This class contains the parameters needed to evaluate hybrid field solutions (kinetic ions with fluid electrons). More...
#include <HybridPICModel.H>
Public Member Functions | |
| HybridPICModel (int nlevs_max) | |
| void | ReadParameters () |
| void | AllocateMFs (int nlevs_max) |
| void | AllocateLevelMFs (int lev, const amrex::BoxArray &ba, const amrex::DistributionMapping &dm, int ncomps, const amrex::IntVect &ngJ, const amrex::IntVect &ngRho, const amrex::IntVect &jx_nodal_flag, const amrex::IntVect &jy_nodal_flag, const amrex::IntVect &jz_nodal_flag, const amrex::IntVect &rho_nodal_flag) |
| void | ClearLevel (int lev) |
| void | InitData () |
| void | CalculateCurrentAmpere (amrex::Vector< std::array< std::unique_ptr< amrex::MultiFab >, 3 >> const &Bfield, amrex::Vector< std::array< std::unique_ptr< amrex::MultiFab >, 3 >> const &edge_lengths) |
| Function to calculate the total current based on Ampere's law while neglecting displacement current (J = curl x B). Used in the Ohm's law solver (kinetic-fluid hybrid model). More... | |
| void | CalculateCurrentAmpere (std::array< std::unique_ptr< amrex::MultiFab >, 3 > const &Bfield, std::array< std::unique_ptr< amrex::MultiFab >, 3 > const &edge_lengths, int lev) |
| void | HybridPICSolveE (amrex::Vector< std::array< std::unique_ptr< amrex::MultiFab >, 3 >> &Efield, amrex::Vector< std::array< std::unique_ptr< amrex::MultiFab >, 3 >> const &Jfield, amrex::Vector< std::array< std::unique_ptr< amrex::MultiFab >, 3 >> const &Bfield, amrex::Vector< std::unique_ptr< amrex::MultiFab >> const &rhofield, amrex::Vector< std::array< std::unique_ptr< amrex::MultiFab >, 3 >> const &edge_lengths, bool include_resistivity_term) |
| Function to update the E-field using Ohm's law (hybrid-PIC model). More... | |
| void | HybridPICSolveE (std::array< std::unique_ptr< amrex::MultiFab >, 3 > &Efield, std::array< std::unique_ptr< amrex::MultiFab >, 3 > const &Jfield, std::array< std::unique_ptr< amrex::MultiFab >, 3 > const &Bfield, std::unique_ptr< amrex::MultiFab > const &rhofield, std::array< std::unique_ptr< amrex::MultiFab >, 3 > const &edge_lengths, int lev, bool include_resistivity_term) |
| void | HybridPICSolveE (std::array< std::unique_ptr< amrex::MultiFab >, 3 > &Efield, std::array< std::unique_ptr< amrex::MultiFab >, 3 > const &Jfield, std::array< std::unique_ptr< amrex::MultiFab >, 3 > const &Bfield, std::unique_ptr< amrex::MultiFab > const &rhofield, std::array< std::unique_ptr< amrex::MultiFab >, 3 > const &edge_lengths, int lev, PatchType patch_type, bool include_resistivity_term) |
| void | CalculateElectronPressure (DtType a_dt_type) |
| Function to calculate the electron pressure at a given timestep type using the simulation charge density. Used in the Ohm's law solver (kinetic-fluid hybrid model). More... | |
| void | CalculateElectronPressure (int lev, DtType a_dt_type) |
| void | FillElectronPressureMF (std::unique_ptr< amrex::MultiFab > const &Pe, amrex::MultiFab *const &rhofield) |
| Fill the electron pressure multifab given the kinetic particle charge density (and assumption of quasi-neutrality) using the user specified electron equation of state. More... | |
| amrex::MultiFab * | get_pointer_current_fp_ampere (int lev, int direction) const |
| amrex::MultiFab * | get_pointer_electron_pressure_fp (int lev) const |
Public Attributes | |
| int | m_substeps = 100 |
| amrex::Real | m_elec_temp |
| amrex::Real | m_n0_ref = 1.0 |
| amrex::Real | m_gamma = 5.0/3.0 |
| amrex::Real | m_n_floor = 1.0 |
| std::string | m_eta_expression = "0.0" |
| std::unique_ptr< amrex::Parser > | m_resistivity_parser |
| amrex::ParserExecutor< 1 > | m_eta |
| amrex::Vector< std::unique_ptr< amrex::MultiFab > > | rho_fp_temp |
| amrex::Vector< std::array< std::unique_ptr< amrex::MultiFab >, 3 > > | current_fp_temp |
| amrex::Vector< std::array< std::unique_ptr< amrex::MultiFab >, 3 > > | current_fp_ampere |
| amrex::Vector< std::unique_ptr< amrex::MultiFab > > | electron_pressure_fp |
| amrex::GpuArray< int, 3 > | Jx_IndexType |
| amrex::GpuArray< int, 3 > | Jy_IndexType |
| amrex::GpuArray< int, 3 > | Jz_IndexType |
| amrex::GpuArray< int, 3 > | Bx_IndexType |
| amrex::GpuArray< int, 3 > | By_IndexType |
| amrex::GpuArray< int, 3 > | Bz_IndexType |
| amrex::GpuArray< int, 3 > | Ex_IndexType |
| amrex::GpuArray< int, 3 > | Ey_IndexType |
| amrex::GpuArray< int, 3 > | Ez_IndexType |
This class contains the parameters needed to evaluate hybrid field solutions (kinetic ions with fluid electrons).
| HybridPICModel::HybridPICModel | ( | int | nlevs_max | ) |
| void HybridPICModel::AllocateLevelMFs | ( | int | lev, |
| const amrex::BoxArray & | ba, | ||
| const amrex::DistributionMapping & | dm, | ||
| int | ncomps, | ||
| const amrex::IntVect & | ngJ, | ||
| const amrex::IntVect & | ngRho, | ||
| const amrex::IntVect & | jx_nodal_flag, | ||
| const amrex::IntVect & | jy_nodal_flag, | ||
| const amrex::IntVect & | jz_nodal_flag, | ||
| const amrex::IntVect & | rho_nodal_flag | ||
| ) |
| void HybridPICModel::AllocateMFs | ( | int | nlevs_max | ) |
Allocate hybrid-PIC specific multifabs. Called in constructor.
| void HybridPICModel::CalculateCurrentAmpere | ( | amrex::Vector< std::array< std::unique_ptr< amrex::MultiFab >, 3 >> const & | Bfield, |
| amrex::Vector< std::array< std::unique_ptr< amrex::MultiFab >, 3 >> const & | edge_lengths | ||
| ) |
Function to calculate the total current based on Ampere's law while neglecting displacement current (J = curl x B). Used in the Ohm's law solver (kinetic-fluid hybrid model).
| [in] | Bfield | Magnetic field from which the current is calculated. |
| [in] | edge_lengths | Length of cell edges taking embedded boundaries into account |
| void HybridPICModel::CalculateCurrentAmpere | ( | std::array< std::unique_ptr< amrex::MultiFab >, 3 > const & | Bfield, |
| std::array< std::unique_ptr< amrex::MultiFab >, 3 > const & | edge_lengths, | ||
| int | lev | ||
| ) |
| void HybridPICModel::CalculateElectronPressure | ( | DtType | a_dt_type | ) |
Function to calculate the electron pressure at a given timestep type using the simulation charge density. Used in the Ohm's law solver (kinetic-fluid hybrid model).
| void HybridPICModel::ClearLevel | ( | int | lev | ) |
Helper function to clear values from hybrid-PIC specific multifabs.
| void HybridPICModel::FillElectronPressureMF | ( | std::unique_ptr< amrex::MultiFab > const & | Pe, |
| amrex::MultiFab *const & | rhofield | ||
| ) |
Fill the electron pressure multifab given the kinetic particle charge density (and assumption of quasi-neutrality) using the user specified electron equation of state.
| [out] | Pe | scalar electron pressure MultiFab at a given level |
| [in] | rhofield | scalar ion chrge density Multifab at a given level |
|
inline |
|
inline |
| void HybridPICModel::HybridPICSolveE | ( | amrex::Vector< std::array< std::unique_ptr< amrex::MultiFab >, 3 >> & | Efield, |
| amrex::Vector< std::array< std::unique_ptr< amrex::MultiFab >, 3 >> const & | Jfield, | ||
| amrex::Vector< std::array< std::unique_ptr< amrex::MultiFab >, 3 >> const & | Bfield, | ||
| amrex::Vector< std::unique_ptr< amrex::MultiFab >> const & | rhofield, | ||
| amrex::Vector< std::array< std::unique_ptr< amrex::MultiFab >, 3 >> const & | edge_lengths, | ||
| bool | include_resistivity_term | ||
| ) |
Function to update the E-field using Ohm's law (hybrid-PIC model).
| void HybridPICModel::HybridPICSolveE | ( | std::array< std::unique_ptr< amrex::MultiFab >, 3 > & | Efield, |
| std::array< std::unique_ptr< amrex::MultiFab >, 3 > const & | Jfield, | ||
| std::array< std::unique_ptr< amrex::MultiFab >, 3 > const & | Bfield, | ||
| std::unique_ptr< amrex::MultiFab > const & | rhofield, | ||
| std::array< std::unique_ptr< amrex::MultiFab >, 3 > const & | edge_lengths, | ||
| int | lev, | ||
| bool | include_resistivity_term | ||
| ) |
| void HybridPICModel::HybridPICSolveE | ( | std::array< std::unique_ptr< amrex::MultiFab >, 3 > & | Efield, |
| std::array< std::unique_ptr< amrex::MultiFab >, 3 > const & | Jfield, | ||
| std::array< std::unique_ptr< amrex::MultiFab >, 3 > const & | Bfield, | ||
| std::unique_ptr< amrex::MultiFab > const & | rhofield, | ||
| std::array< std::unique_ptr< amrex::MultiFab >, 3 > const & | edge_lengths, | ||
| int | lev, | ||
| PatchType | patch_type, | ||
| bool | include_resistivity_term | ||
| ) |
| void HybridPICModel::InitData | ( | ) |
| void HybridPICModel::ReadParameters | ( | ) |
Read user-defined model parameters. Called in constructor.
| amrex::GpuArray<int, 3> HybridPICModel::Bx_IndexType |
Gpu Vector with index type of the Bx multifab
| amrex::GpuArray<int, 3> HybridPICModel::By_IndexType |
Gpu Vector with index type of the By multifab
| amrex::GpuArray<int, 3> HybridPICModel::Bz_IndexType |
Gpu Vector with index type of the Bz multifab
| amrex::Vector<std::array< std::unique_ptr<amrex::MultiFab>, 3 > > HybridPICModel::current_fp_ampere |
| amrex::Vector<std::array< std::unique_ptr<amrex::MultiFab>, 3 > > HybridPICModel::current_fp_temp |
| amrex::Vector< std::unique_ptr<amrex::MultiFab> > HybridPICModel::electron_pressure_fp |
| amrex::GpuArray<int, 3> HybridPICModel::Ex_IndexType |
Gpu Vector with index type of the Ex multifab
| amrex::GpuArray<int, 3> HybridPICModel::Ey_IndexType |
Gpu Vector with index type of the Ey multifab
| amrex::GpuArray<int, 3> HybridPICModel::Ez_IndexType |
Gpu Vector with index type of the Ez multifab
| amrex::GpuArray<int, 3> HybridPICModel::Jx_IndexType |
Gpu Vector with index type of the Jx multifab
| amrex::GpuArray<int, 3> HybridPICModel::Jy_IndexType |
Gpu Vector with index type of the Jy multifab
| amrex::GpuArray<int, 3> HybridPICModel::Jz_IndexType |
Gpu Vector with index type of the Jz multifab
| amrex::Real HybridPICModel::m_elec_temp |
Electron temperature in eV
| amrex::ParserExecutor<1> HybridPICModel::m_eta |
| std::string HybridPICModel::m_eta_expression = "0.0" |
Plasma resistivity
| amrex::Real HybridPICModel::m_gamma = 5.0/3.0 |
Electron pressure scaling exponent
| amrex::Real HybridPICModel::m_n0_ref = 1.0 |
Reference electron density
| amrex::Real HybridPICModel::m_n_floor = 1.0 |
Plasma density floor - if n < n_floor it will be set to n_floor
| std::unique_ptr<amrex::Parser> HybridPICModel::m_resistivity_parser |
| int HybridPICModel::m_substeps = 100 |
Number of substeps to take when evolving B
| amrex::Vector< std::unique_ptr<amrex::MultiFab> > HybridPICModel::rho_fp_temp |