chombo-discharge
|
Base class for Ito diffusion particle models. More...
#include <CD_ItoSolver.H>
Public Types | |
enum class | WhichContainer { Bulk , EB , Domain , Source , Covered , Scratch } |
Enum class for distinguishing various types of particle containers. More... | |
Public Member Functions | |
ItoSolver () | |
Constructor – user must subsequently set the realm and, parse class options, set the species etc. | |
virtual | ~ItoSolver () |
Destructor (does nothing). | |
virtual void | setParticleMerger (const ParticleManagement::ParticleMerger< ItoParticle > &a_particleMerger) noexcept |
Set the particle merger. This will get called when merging particles using makeSuperparticles. More... | |
virtual std::string | getName () const |
Get this solver's name. More... | |
virtual const std::string | getRealm () const |
Get the realm where this solver is registered. More... | |
virtual void | setRealm (const std::string a_realm) |
Set the realm where this solver will live. More... | |
virtual void | parseOptions () |
Parse class options. | |
virtual void | parseRuntimeOptions () |
Parse class runtime configurable options. | |
virtual EBIntersection | getIntersectionAlgorithm () const noexcept |
Get the EB-particle intersection algorithm. | |
virtual void | initialData () |
Set the initial data. More... | |
virtual void | regrid (const int a_lmin, const int a_oldFinestLevel, const int a_newFinestLevel) |
Regrid this solver. More... | |
virtual void | allocate () |
Allocate internal storage. More... | |
virtual void | clear (const WhichContainer a_container) |
Clear a particle container – this will delete all the particles in the input container. More... | |
virtual void | clear (ParticleContainer< ItoParticle > &a_particles) const |
Clear a particle container – this will delete all the particles in the input container. More... | |
virtual void | clear (AMRParticles< ItoParticle > &a_particles) const |
Clear particles – this will deleted all the particles in the input container. More... | |
virtual void | depositConductivity (EBAMRCellData &a_phi, ParticleContainer< ItoParticle > &a_particles) const |
Deposit conductivities (i.e. mass*mobility / volume) More... | |
virtual void | depositConductivity (EBAMRCellData &a_phi, ParticleContainer< ItoParticle > &a_particles, const DepositionType a_deposition, const CoarseFineDeposition a_coarseFineDeposition) const |
Deposit conductivities (i.e. mass*mobility / volume) More... | |
virtual void | depositDiffusivity (EBAMRCellData &a_phi, ParticleContainer< ItoParticle > &a_particles) const |
Deposit diffusivity (i.e. mass*D/volume) More... | |
virtual void | depositDiffusivity (EBAMRCellData &a_phi, ParticleContainer< ItoParticle > &a_particles, const DepositionType a_deposition, const CoarseFineDeposition a_coarseFineDeposition) const |
Deposit diffusivity (i.e. mass*D/volume) More... | |
virtual void | depositEnergyDensity (EBAMRCellData &a_phi, ParticleContainer< ItoParticle > &a_particles) const |
Deposit energy densities (i.e. mass*energy/volume => total energy per unit volume) More... | |
virtual void | depositEnergyDensity (EBAMRCellData &a_phi, ParticleContainer< ItoParticle > &a_particles, const DepositionType a_deposition, const CoarseFineDeposition a_coarseFineDeposition) const |
Deposit energy densities (i.e. mass*energy/volume => total energy per unit volume) More... | |
virtual void | computeAverageMobility (EBAMRCellData &a_phi, ParticleContainer< ItoParticle > &a_particles) const |
Compute average mobility. More... | |
virtual void | computeAverageDiffusion (EBAMRCellData &a_phi, ParticleContainer< ItoParticle > &a_particles) const |
Compute average diffusion coefficient. More... | |
virtual void | computeAverageEnergy (EBAMRCellData &a_phi, ParticleContainer< ItoParticle > &a_particles) const |
Compute average particle energy.. More... | |
virtual void | depositParticles () |
Deposit particles onto mesh. More... | |
virtual void | depositParticles (const WhichContainer a_container) |
Deposit particles on to mesh. More... | |
template<class P , const Real &(P ::*)() const particleScalarField> | |
void | depositParticlesNGP (LevelData< EBCellFAB > &a_output, const ParticleContainer< P > &a_particles, const int a_level) const noexcept |
Do an NGP deposit on a specific grid level. Used for IO. More... | |
template<class P , Real(P ::*)() const particleScalarField> | |
void | depositParticlesNGP (LevelData< EBCellFAB > &a_output, const ParticleContainer< P > &a_particles, const int a_level) const noexcept |
Do an NGP deposit on a specific grid level. Used for IO. More... | |
template<class P , const Real &(P::*)() const particleScalarField> | |
void | depositParticles (EBAMRCellData &a_phi, ParticleContainer< P > &a_particles) const |
Generic deposition function which deposits a particle field onto the mesh using a specified deposition method. More... | |
template<class P , const Real &(P::*)() const particleScalarField> | |
void | depositParticles (EBAMRCellData &a_phi, ParticleContainer< P > &a_particles, const DepositionType a_deposition, const CoarseFineDeposition a_coarseFineDeposition) const |
Generic deposition function which deposits a particle field onto the mesh using a specified deposition method. More... | |
template<class P , Real(P::*)() const particleScalarField> | |
void | depositParticles (EBAMRCellData &a_phi, ParticleContainer< P > &a_particles, const DepositionType a_deposition, const CoarseFineDeposition a_coarseFineDeposition) const |
Generic deposition function which deposits a particle field onto the mesh using a specified deposition method. More... | |
virtual void | removeCoveredParticles (const EBRepresentation a_representation, const Real a_tol) |
Remove particles that are inside the EB. More... | |
virtual void | removeCoveredParticles (const WhichContainer a_container, const EBRepresentation a_representation, const Real a_tol) |
Remove particles that are inside the EB. More... | |
virtual void | removeCoveredParticles (ParticleContainer< ItoParticle > &a_particles, const EBRepresentation a_representation, const Real a_tol) const |
Remove particles that are inside the EB. More... | |
virtual void | transferCoveredParticles (const EBRepresentation a_representation, const Real a_tol) |
Transfer particles that are covered (within a_tol distance from EB) to another container. More... | |
virtual void | transferCoveredParticles (const WhichContainer a_containerFrom, const WhichContainer a_containerTo, const EBRepresentation a_representation, const Real a_tol) |
Transfer particles that are covered (within a_tol distance from EB) to another container. More... | |
virtual void | transferCoveredParticles (ParticleContainer< ItoParticle > &a_particlesFrom, ParticleContainer< ItoParticle > &a_particlesTo, const EBRepresentation a_representation, const Real a_tol) const |
Transfer particles that are inside the EB to another container. More... | |
virtual void | intersectParticles (const EBIntersection a_ebIntersection, const bool a_deleteParticles, const std::function< void(ItoParticle &)> a_nonDeletionModifier=[](ItoParticle &) -> void { return;}) |
Do boundary intersection tests. More... | |
virtual void | intersectParticles (const WhichContainer a_particles, const WhichContainer a_ebParticles, const WhichContainer a_domainParticles, const EBIntersection a_ebIntersection, const bool a_deleteParticles, const std::function< void(ItoParticle &)> a_nonDeletionModifier=[](ItoParticle &) -> void { return;}) |
Do boundary intersection tests. More... | |
virtual void | intersectParticles (ParticleContainer< ItoParticle > &a_particles, ParticleContainer< ItoParticle > &a_ebParticles, ParticleContainer< ItoParticle > &a_domainParticles, const EBIntersection a_ebIntersection, const bool a_deleteParticles, const std::function< void(ItoParticle &)> a_nonDeletionModifier=[](ItoParticle &) -> void { return;}) |
Do boundary intersection tests. More... | |
virtual void | computeLoads (Vector< long int > &a_loads, const DisjointBoxLayout &a_dbl, const int a_level) |
Compute particle load on a specific grid level – this will compute the number of particles in each box in the input grids. More... | |
virtual int | getNumberOfPlotVariables () const |
Get number of plot variables. More... | |
virtual Vector< std::string > | getPlotVariableNames () const |
Get output plot names. More... | |
virtual void | writePlotData (LevelData< EBCellFAB > &a_output, int &a_comp, const std::string a_outputRealm, const int a_level) const noexcept |
Write plot data. More... | |
virtual unsigned long long | getNumParticles (const WhichContainer a_container, const bool a_localOnly) const |
Get number of particles in a specified particle container. More... | |
virtual void | registerOperators () const |
Register operators. More... | |
virtual void | setComputationalGeometry (const RefCountedPtr< ComputationalGeometry > &a_computationalGeometry) |
Set computational geometry. More... | |
virtual void | setAmr (const RefCountedPtr< AmrMesh > &a_amr) |
Set the AmrMesh object. More... | |
virtual void | setPhase (const phase::which_phase a_phase) |
Set phase where the particles will live. More... | |
virtual void | setVerbosity (const int a_verbosity) |
Set verbosity level for this solver. More... | |
virtual void | setTime (const int a_step, const Real a_time, const Real a_dt) |
Set the time for this solver. More... | |
virtual void | setSpecies (const RefCountedPtr< ItoSpecies > &a_species) |
Set the species. More... | |
virtual void | preRegrid (const int a_lbase, const int a_oldFinestLevel) |
Perform pre-regrid operations. More... | |
template<ItoSolver::WhichContainer C = WhichContainer::Bulk> | |
void | addParticles (ListBox< ItoParticle > &a_inputParticles, const int a_lvl, const DataIndex a_dit, const bool a_destructive) |
Add particles to a contain. This adds into a specific grid level and patch. The user can delete the input particles. More... | |
virtual bool | isMobile () const |
Check if solver is mobile. More... | |
virtual bool | isDiffusive () const |
Check if solver is diffusive. More... | |
virtual ParticleContainer< ItoParticle > & | getParticles (const WhichContainer a_container) |
Get a general particle container. More... | |
virtual const ParticleContainer< ItoParticle > & | getParticles (const WhichContainer a_container) const |
Get a general particle container. More... | |
virtual const RefCountedPtr< ItoSpecies > & | getSpecies () const |
Get the species. More... | |
virtual EBAMRCellData & | getPhi () |
Get the mesh data. More... | |
virtual EBAMRCellData & | getVelocityFunction () |
Get cell-centered velocity mesh data. More... | |
virtual const EBAMRCellData & | getVelocityFunction () const |
Get cell-centered velocity mesh data. More... | |
virtual EBAMRCellData & | getDiffusionFunction () |
Get the diffusion function. More... | |
virtual const EBAMRCellData & | getDiffusionFunction () const |
Get the diffusion function. More... | |
virtual EBAMRCellData & | getMobilityFunction () |
Get mobility function. More... | |
virtual const EBAMRCellData & | getMobilityFunction () const |
Get mobility function. More... | |
virtual void | setDiffusionFunction (const Real a_diffusionCoefficient) |
Utility function – set a constant diffusion coefficient. More... | |
virtual void | setVelocityFunction (const RealVect a_velocity) |
Utility function – set a constant velocity. More... | |
virtual void | setParticleMobility (const Real a_mobility) |
Sets mobility coefficient for all particles. More... | |
virtual void | setParticleDiffusion (const Real a_diffusion) |
Sets diffusion coefficient for all particles. More... | |
virtual void | interpolateVelocities () |
Interpolate the particle velocities. More... | |
virtual void | interpolateVelocities (const int a_level, const DataIndex &a_dit) |
Interpolate the particle velocities. More... | |
virtual void | interpolateMobilities () |
Interpolate mobilities. More... | |
virtual void | updateMobilities () |
Update mobilities parametrically from the particle energy. More... | |
virtual void | interpolateDiffusion () |
Interpolate the diffusion field to the particle positions. More... | |
virtual void | updateDiffusion () |
Update mobilities parametrically from the particle energy. More... | |
virtual void | organizeParticlesByCell (const WhichContainer a_container) |
Sort the input particle container by cell. More... | |
virtual void | organizeParticlesByPatch (const WhichContainer a_container) |
Sort the input particle container by patch. More... | |
virtual void | makeSuperparticles (const WhichContainer a_container, const int a_particlesPerCell) |
Make superparticles for a full container – this is the AMR version that users will usually call. More... | |
virtual void | makeSuperparticles (const WhichContainer a_container, const Vector< int > a_particlesPerCell) |
Make superparticles for a full container – this is the AMR version that users will usually call. More... | |
virtual void | makeSuperparticles (const WhichContainer a_container, const int a_particlesPerCell, const int a_level) |
Make superparticles for a particle container – this is used for a specified grid level. More... | |
virtual void | makeSuperparticles (const WhichContainer a_container, const int a_particlesPerCell, const int a_level, const DataIndex a_dit) |
Make superparticles for a particle container – this is used for a specified grid level and patch. More... | |
virtual void | mergeParticles (List< ItoParticle > &a_particles, const CellInfo &a_cellInfo, const int a_particlesPerCell) const noexcept |
General superparticle merging with underlying algorithm through m_particleMerger. More... | |
virtual void | makeSuperparticlesEqualWeightKD (List< ItoParticle > &a_particles, const CellInfo &a_cellInfo, const int a_particlesPerCell) const noexcept |
Superparticle merging with KD/BVH trees. More... | |
virtual void | reinitializeParticles (List< ItoParticle > &a_particles, const CellInfo &a_cellInfo, const int a_particlesPerCell) const noexcept |
Particle re-initialization algorithm. More... | |
virtual void | remap () |
Remap the bulk particle container. | |
virtual void | remap (const WhichContainer a_container) |
Remap all particles in the input container. More... | |
virtual void | remapAll () |
Remap all particle containers. | |
RealVect | randomGaussian () const |
Draw a random N-dimensional Gaussian number from a normal distribution with zero with and unit standard deviation. More... | |
RealVect | randomDirection () const |
Draw a random direction in N-dimensional space. More... | |
virtual Real | computeDt () const |
Compute a time step for the advance – this calls the level function. More... | |
virtual Real | computeDt (const int a_lvl) const |
Compute a time step for the advance – this returns the maximum permitted time step on the input grid level. More... | |
virtual Real | computeDt (const int a_lvl, const DataIndex &a_dit) const |
Compute a time step for the advance – this returns the maximum permitted time step on the input grid patch. More... | |
virtual Real | computeHopDt (const Real a_maxCellsToMove) const |
Compute the largest possible time step such that the particles does not move more than a specified number of grid cells on any grid level. More... | |
virtual Real | computeHopDt (const Real a_maxCellsToMove, const int a_lvl) const |
Compute the largest possible time step such that the particles does not move more than a specified number of grid cells on the input grid level. More... | |
virtual Real | computeHopDt (const Real a_maxCellsToMove, const int a_lvl, const DataIndex &a_dit) const |
Compute the largest possible time step such that the particles does not move more than a specified number of grid cells on the input grid level. More... | |
virtual Real | computeAdvectiveDt () const |
Compute advection time step dt = dx/vMax where vMax is the largest velocity component of the particle. | |
virtual Real | computeAdvectiveDt (const int a_lvl) const |
Compute the drift dt. This computes the minimum dt = dx/vMax on the input level. More... | |
virtual Real | computeAdvectiveDt (const int a_lvl, const DataIndex &a_dit) const |
Compute the drift dt. This computes the minimum dt = dx/vMax on one level and one box. More... | |
virtual Real | computeDiffusiveDt () const |
Compute the diffusive dt. This computes dt = dx*dx/(2*D) for all particles. | |
virtual Real | computeDiffusiveDt (const int a_lvl) const |
Compute the diffusive dt. This computes dt = dx*dx/(2*D) for all particles on the input level. More... | |
virtual Real | computeDiffusiveDt (const int a_lvl, const DataIndex &a_dit) const |
Compute the diffusive dt. This computes dt = dx*dx/(2*D) for all particles on the input grid patch. More... | |
DepositionType | getDeposition () const |
Get deposition method. More... | |
CoarseFineDeposition | getCoarseFineDeposition () const |
Get the coarse-fine deposition strategy. | |
phase::which_phase | getPhase () const |
Return phase. More... | |
Protected Types | |
enum class | WhichCheckpoint { Particles , Numbers } |
How to checkpoint files. More... | |
enum class | WhichMobilityInterpolation { Direct , Velocity } |
Enum for deciding how to interpolate particle mobilities. More... | |
Protected Member Functions | |
void | parseRNG () |
Parse RNG options – this parses the RNG seed and instantiates the distributions. | |
void | parseTruncation () |
Parse the normal distribution truncation level. | |
void | parseDeposition () |
Parse particle deposition methods. | |
void | parseParticleMerger () |
Parse the super-particle merger. | |
void | parseIntersectionEB () |
Parse EB intersection algorithms. | |
void | parseVerbosity () |
Parse class verbosity. | |
void | parsePlotVariables () |
Parse plot variables. | |
void | parseDiffusionHop () |
Parse diffusion hop. | |
void | parseRedistribution () |
Parse whether or not to use redistribution. | |
void | parseDivergenceComputation () |
Parse whether or not to compute a "non-conservative" divergence when redistributing mass. | |
void | parseCheckpointing () |
Parse checkpointing method. | |
void | drawNewParticles (const LevelData< EBCellFAB > &a_particlesPerCell, const int a_level, const int a_newPPC) |
Restart particles from a specified number of particles in the grid cell. More... | |
template<class P , const Real &(P::*)() const particleScalarField> | |
void | depositKappaConservative (EBAMRCellData &a_phi, ParticleContainer< P > &a_particles, const DepositionType a_deposition, const CoarseFineDeposition a_coarseFineDeposition) const |
Compute the cell-centered deposition – this is the main deposition function. More... | |
template<class P , Real(P::*)() const particleScalarField> | |
void | depositKappaConservative (EBAMRCellData &a_phi, ParticleContainer< P > &a_particles, const DepositionType a_deposition, const CoarseFineDeposition a_coarseFineDeposition) const |
Compute the cell-centered deposition – this is the main deposition function. More... | |
virtual void | redistributeAMR (EBAMRCellData &a_phi) const |
Redistribute mass in an AMR context. More... | |
virtual void | depositNonConservative (EBAMRIVData &a_depositionNC, const EBAMRCellData &a_depositionKappaC) const |
Make the "non-conservative" kappa deposition – computing depositionNC = sum(kappa*depositionC)/sum(kappa) in a neighborhood around each vof. More... | |
virtual void | depositHybrid (EBAMRCellData &a_depositionH, EBAMRIVData &a_massDifference, const EBAMRIVData &a_depositionNC) const |
Make the "hybrid" deposition phiH = kappa*phiC + (1-kappa)*phiNC. On input, a_depositionH should contain phiC. More... | |
virtual void | interpolateMobilities (const int a_level, const DataIndex &a_dit, const EBCellFAB &a_velocityMagnitude) noexcept |
Interpolate mobilities – this will switch between the two ways of computing the particle mobility. More... | |
virtual void | interpolateMobilitiesDirect (const int a_level, const DataIndex &a_dit) noexcept |
Directly interpolate mobilities. Interpolates for all particles in the specified grid patch. More... | |
virtual void | interpolateMobilitiesVelocity (const int a_level, const DataIndex &a_dit, const EBCellFAB &a_velocityMagnitude) noexcept |
Interpolate mobilities through the velocity. Interpolates for all particles in the specified grid patch. More... | |
virtual void | updateMobilities (const int a_level, const DataIndex a_dit) |
Update mobilities parametrically from the particle energy. More... | |
virtual void | interpolateDiffusion (const int a_level, const DataIndex &a_dit) |
Interpolate the diffusion field to the particle positions. More... | |
virtual void | updateDiffusion (const int a_level, const DataIndex a_dit) |
Update mobilities parametrically from the particle energy. More... | |
virtual void | writeData (LevelData< EBCellFAB > &a_output, int &a_comp, const EBAMRCellData &a_data, const std::string a_outputRealm, const int a_level, const bool a_interpToCentroids, const bool a_interpGhost) const noexcept |
Write data to output. Convenience function. More... | |
Protected Attributes | |
WhichCheckpoint | m_checkpointing |
How to checkpoint files. particles => write particles to HDF5. numbers => write numbers to HDF5. | |
WhichMobilityInterpolation | m_mobilityInterp |
Switch for deciding how to interpolate mobilities, i.e. interpolating either mu*E or just mu (to the particle position) | |
ParticleManagement::ParticleMerger< ItoParticle > | m_particleMerger |
Particle merger. | |
int | m_restartPPC |
Number of particles used when restarting a simulation – this is relevant only when restarting from a "fluid" checkpoint file. | |
std::string | m_realm |
Realm where this solve lives. | |
RefCountedPtr< ComputationalGeometry > | m_computationalGeometry |
Computational geometry. | |
RefCountedPtr< AmrMesh > | m_amr |
AMR; needed for grid stuff. | |
RefCountedPtr< ItoSpecies > | m_species |
Species that this solver solves for. | |
phase::which_phase | m_phase |
Phase where this solver lives. | |
std::string | m_name |
Solver name. | |
std::string | m_className |
Class name. More... | |
Real | m_normalDistributionTruncation |
Truncation value for normal distribution. More... | |
Real | m_bisectionStep |
Bisection step size to use for particle intersection tests with EBs. | |
int | m_verbosity |
Verbosity level for this solver. | |
int | m_timeStep |
Time step. | |
int | m_haloBuffer |
Size of refinement boundary halo. | |
Real | m_time |
Current time. | |
Real | m_dt |
Time step. | |
bool | m_forceIrregDepositionNGP |
NGP deposition in cut cells or not. | |
bool | m_forceIrregInterpolationNGP |
NGP interpolation in cut cells or not. | |
bool | m_forceHaloNGP |
Force usage of NGP when depositing "halo" particles. | |
bool | m_useRedistribution |
Use mass redistribution or not. | |
bool | m_blendConservation |
Flag for blending the deposition clouds with the "non-conservative" divergence. | |
bool | m_isDiffusive |
If true, solver is diffusive. | |
bool | m_isMobile |
If true, solver is mobile, i.e. advection is turned on. | |
bool | m_plotPhi |
Flag for outputting m_phi to plot files. | |
bool | m_plotVelocity |
Flag for outputting m_velocityFunction to plot files. | |
bool | m_plotDiffCo |
Flag for outputting m_diffusionFunction to plot files. | |
bool | m_plotParticles |
Flag for depositing and plotting the bulk particles on the mesh. | |
bool | m_plotParticlesEB |
Flag for depositing and plotting the EB particles on the mesh. | |
bool | m_plotParticlesDomain |
Flag for depositing and plotting the domain particles on the mesh. | |
bool | m_plotParticlesSource |
Flag for depositing and plotting the source particles on the mesh. | |
bool | m_plotParticlesCovered |
Flag for depositing and plotting the covered particles on the mesh. | |
bool | m_plotEnergyDensity |
Flag for plotting the energy density on the mesh. | |
bool | m_plotAverageEnergy |
Flag for plotting the average particle energy on the mesh. | |
DepositionType | m_deposition |
Deposition method when depositing particles to the mesh. | |
CoarseFineDeposition | m_coarseFineDeposition |
Coarse-fine deposition strategy. | |
DepositionType | m_plotDeposition |
Deposition method when depositing particles to mesh during plotting. | |
EBAMRCellData | m_phi |
Storage for particle mesh data. | |
EBAMRCellData | m_mobilityFunction |
Mobility function – used when interpolating particle mobilities. | |
EBAMRCellData | m_velocityFunction |
Cell-centered field used for interpolating velocities. | |
EBAMRCellData | m_diffusionFunction |
Diffusion-centerer field used for interpolating diffusion coefficients. | |
EBAMRIVData | m_depositionNC |
Scratch storage for holding the non-conservative deposition. | |
EBAMRIVData | m_massDiff |
Scratch storage for holding the mass difference when using hybrid deposition. | |
std::map< WhichContainer, ParticleContainer< ItoParticle > > | m_particleContainers |
Various particle containers with identifiers. | |
EBIntersection | m_intersectionAlg |
Algorithm for EB intersection. | |
Static Protected Attributes | |
static constexpr int | m_comp = 0 |
Default component in data holders (do not touch). | |
static constexpr int | m_nComp = 1 |
Default number of component in data holders (do not touch). | |
Base class for Ito diffusion particle models.
This is a particle class for solving Ito diffusion problems dX = v*dt + sqrt(2*D)*dW_t (dW_t is a Wiener process over dt) over an AMR hierarchy. The diffusion coefficient is related to the hydrodynamic diffusion coefficient by D(fluid) = sqrt(2*D(Ito)).
|
strongprotected |
How to checkpoint files.
Particles => Write particles to HDF5. Numbers => Write particle numbers to HDF5 (and lose information)
|
strong |
Enum class for distinguishing various types of particle containers.
This exists because the ItoSolver can partition particles into various containers, which is very useful when one wants to add particles from a source term, remove particles that fall inside the EB, or parse boundary conditions on the EB and domain faces. Here, Bulk = "Active" particles, EB = Particles on the EBs , Domain = Particles on the domain sides, Source = Source particles – used to e.g. add new particles to the bulk particles, Covered = Particles inside the EB, Scratch = Scratch particles
|
strongprotected |
Enum for deciding how to interpolate particle mobilities.
Direct => Interpolate particle mobilities from the mesh. Velocity => Set particle mobilitys by computing mu = |v|/|V| where v is the particle velocity and V is the "velocity field".
void ItoSolver::addParticles | ( | ListBox< ItoParticle > & | a_inputParticles, |
const int | a_lvl, | ||
const DataIndex | a_dit, | ||
const bool | a_destructive | ||
) |
Add particles to a contain. This adds into a specific grid level and patch. The user can delete the input particles.
[in,out] | a_inputParticles | Input particles – can be destroyed if a_destructive=true |
[in] | a_lvl | Grid level |
[in] | a_dit | Grid index |
[in] | a_destructive | If true, delete the input particles. |
|
virtual |
Allocate internal storage.
This will allocate the required mesh data as well as all the particle data holders.
|
virtual |
Clear particles – this will deleted all the particles in the input container.
[in] | a_particles | Particle container to be emptied. |
|
virtual |
Clear a particle container – this will delete all the particles in the input container.
[in] | a_whichContainer | Particle container to be cleared. |
|
virtual |
Clear a particle container – this will delete all the particles in the input container.
[in] | a_particles | Particle container to be emptied. |
|
virtual |
Compute the drift dt. This computes the minimum dt = dx/vMax on the input level.
[in] | a_lvl | Grid level |
|
virtual |
Compute the drift dt. This computes the minimum dt = dx/vMax on one level and one box.
[in] | a_lvl | Grid level |
[in] | a_dit | Grid index |
|
virtual |
Compute average diffusion coefficient.
This computes the average diffusion coefficient as D_avg = sum(mass*D)/sum(mass) by depositing on the mesh.
[out] | a_phi | Mesh data |
[in] | a_particles | Particle data |
|
virtual |
Compute average particle energy..
This computes the average energy as E_avg = sum(mass*energy)/sum(mass) by depositing on the mesh.
[out] | a_phi | Mesh data |
[in] | a_particles | Particle data |
|
virtual |
Compute average mobility.
This computes the average mobility as mu_avg = sum(mass*mu)/sum(mass) by depositing on the mesh.
[out] | a_phi | Mesh data |
[in] | a_particles | Particle data |
|
virtual |
Compute the diffusive dt. This computes dt = dx*dx/(2*D) for all particles on the input level.
[in] | a_lvl | Grid level |
|
virtual |
Compute the diffusive dt. This computes dt = dx*dx/(2*D) for all particles on the input grid patch.
[in] | a_lvl | Grid level |
[in] | a_dit | Grid index |
|
virtual |
Compute a time step for the advance – this calls the level function.
This computes the time step differently whether or not diffusion and advection are active. The Ito particle model does not have a fundamental time step limitation, so these limits "replicate" the time step selections in a 1D fluid model. If we only use advection advection the time step is computed as dt = dx/Vmax = dtA, where Vmax is the largest velocity component along any of the directions. If only diffusion is active the time step is computed as dt = (dx*dx)/(2*D) = dtD. If both advection and diffusion are active the time step is computed as dt = 1/(1/dtA + 1/dtD).
|
virtual |
Compute a time step for the advance – this returns the maximum permitted time step on the input grid level.
This computes the time step differently whether or not diffusion and advection are active. The Ito particle model does not have a fundamental time step limitation, so these limits "replicate" the time step selections in a 1D fluid model. If we only use advection advection the time step is computed as dt = dx/Vmax = dtA, where Vmax is the largest velocity component along any of the directions. If only diffusion is active the time step is computed as dt = (dx*dx)/(2*D) = dtD. If both advection and diffusion are active the time step is computed as dt = 1/(1/dtA + 1/dtD).
[in] | a_lvl | Grid level |
|
virtual |
Compute a time step for the advance – this returns the maximum permitted time step on the input grid patch.
This computes the time step differently whether or not diffusion and advection are active. The Ito particle model does not have a fundamental time step limitation, so these limits "replicate" the time step selections in a 1D fluid model. If we only use advection advection the time step is computed as dt = dx/Vmax = dtA, where Vmax is the largest velocity component along any of the directions. If only diffusion is active the time step is computed as dt = (dx*dx)/(2*D) = dtD. If both advection and diffusion are active the time step is computed as dt = 1/(1/dtA + 1/dtD).
[in] | a_lvl | Grid level |
[in] | a_dit | Grid index |
|
virtual |
Compute the largest possible time step such that the particles does not move more than a specified number of grid cells on any grid level.
This computes the time step differently whether or not diffusion and advection are active. The Ito particle model does not a fundamental time step limitation, so this function does its best at computing a time step such that the particles do not move more than the specified amount of grid cells. If only advection is active the time step is computed as dt = a_maxCellsToMove * dx/vMax where vMax is the largest velocity component. If only diffusion is active the usual kernel is dX = dWt which yields a "hop" of length L_d = sqrt(2*D*dt)*N0 where N0 is the diffusion hop in one of the coordinates. We do not need to worry about SpaceDim-related corrections because the hops in each direction are independent, so solving for dt we find dtD = L_d^2/(2*D*N0^2). If both advectino and diffusion are active then we can move up to L_d = v_d*dt + sqrt(2*D*dt)*N0 in any one coordinate direction (this is the usual Ito kernel). This requires a solution to a quadratic equation. Fortunately, this is easy to solve for.
[in] | a_maxCellsToMove |
|
virtual |
Compute the largest possible time step such that the particles does not move more than a specified number of grid cells on the input grid level.
This computes the time step differently whether or not diffusion and advection are active. The Ito particle model does not a fundamental time step limitation, so this function does its best at computing a time step such that the particles do not move more than the specified amount of grid cells. If only advection is active the time step is computed as dt = a_maxCellsToMove * dx/vMax where vMax is the largest velocity component. If only diffusion is active the usual kernel is dX = dWt which yields a "hop" of length L_d = sqrt(2*D*dt)*N0 where N0 is the diffusion hop in one of the coordinates. We do not need to worry about SpaceDim-related corrections because the hops in each direction are independent, so solving for dt we find dtD = L_d^2/(2*D*N0^2). If both advectino and diffusion are active then we can move up to L_d = v_d*dt + sqrt(2*D*dt)*N0 in any one coordinate direction (this is the usual Ito kernel). This requires a solution to a quadratic equation. Fortunately, this is easy to solve for.
[in] | a_maxCellsToMove | Maximum number of cells to move with a standard Ito kernel dX = v*dt + sqrt(2*D*dt)*N |
[in] | a_lvl | Grid level |
|
virtual |
Compute the largest possible time step such that the particles does not move more than a specified number of grid cells on the input grid level.
This computes the time step differently whether or not diffusion and advection are active. The Ito particle model does not a fundamental time step limitation, so this function does its best at computing a time step such that the particles do not move more than the specified amount of grid cells. If only advection is active the time step is computed as dt = a_maxCellsToMove * dx/vMax where vMax is the largest velocity component. If only diffusion is active the usual kernel is dX = dWt which yields a "hop" of length L_d = sqrt(2*D*dt)*N0 where N0 is the diffusion hop in one of the coordinates. We do not need to worry about SpaceDim-related corrections because the hops in each direction are independent, so solving for dt we find dtD = L_d^2/(2*D*N0^2). If both advectino and diffusion are active then we can move up to L_d = v_d*dt + sqrt(2*D*dt)*N0 in any one coordinate direction (this is the usual Ito kernel). This requires a solution to a quadratic equation. Fortunately, this is easy to solve for.
[in] | a_maxCellsToMove | Maximum number of cells to move with a standard Ito kernel dX = v*dt + sqrt(2*D*dt)*N |
[in] | a_lvl | Grid level |
[in] | a_dit | Grid index |
|
virtual |
Compute particle load on a specific grid level – this will compute the number of particles in each box in the input grids.
[out] | a_loads | Loads on each grid patch. This follows the order from a_dbl.boxArray() |
[in] | a_dbl | Grids |
[in] | a_level | Grid level |
|
virtual |
Deposit conductivities (i.e. mass*mobility / volume)
This deposits mass*mobility (not multiplied by charge)
[out] | a_phi | Mesh data |
[in] | a_particles | Particle data |
|
virtual |
Deposit conductivities (i.e. mass*mobility / volume)
This deposits mass*mobility (not multiplied by charge)
[out] | a_phi | Mesh data |
[in] | a_particles | Particle data |
[in] | a_deposition | Deposition method |
[in] | a_coarseFineDeposition | Coarse-fine deposition method. |
|
virtual |
Deposit diffusivity (i.e. mass*D/volume)
This deposits mass*diffusion (not multiplied by charge)
[out] | a_phi | Mesh data |
[in] | a_particles | Particle data |
|
virtual |
Deposit diffusivity (i.e. mass*D/volume)
This deposits mass*mobility (not multiplied by charge)
[out] | a_phi | Mesh data |
[in] | a_particles | Particle data |
[in] | a_deposition | Deposition method |
[in] | a_coarseFineDeposition | Coarse-fine deposition method. |
|
virtual |
Deposit energy densities (i.e. mass*energy/volume => total energy per unit volume)
This deposits mass*energy
[out] | a_phi | Mesh data |
[in] | a_particles | Particle data |
|
virtual |
Deposit energy densities (i.e. mass*energy/volume => total energy per unit volume)
This deposits mass*energy
[out] | a_phi | Mesh data |
[in] | a_particles | Particle data |
[in] | a_deposition | Deposition method |
[in] | a_coarseFineDeposition | Coarse-fine deposition method. |
|
protectedvirtual |
Make the "hybrid" deposition phiH = kappa*phiC + (1-kappa)*phiNC. On input, a_depositionH should contain phiC.
[in,out] | a_depositionH | On input, contains phiC. On output, contain phiH |
[out] | a_massDifference | On output, contains mass loss in each cut-cell. |
[in] | a_depositionNC | The "non-conservative" deposited variable. |
|
protected |
Compute the cell-centered deposition – this is the main deposition function.
The template parameters indicate the particle type and quantity to be deposited. The second template parameter must be a pointer to a member function in the particle class with signature 'const Real& P::function() const'. E.g. 'const Real& P::mass() const' which is the default quantity to be deposited.
[out] | a_phi | Cell-centered mesh data. Must have exactly one component. |
[in] | a_particles | Particles to be deposited. |
[in] | a_deposition | Deposition type |
[in] | a_coarseFineDeposition | Coarse-fine deposition strategy |
|
protected |
Compute the cell-centered deposition – this is the main deposition function.
Just like the version above except that the function signature is Real P::particleScalarField() const.
[out] | a_phi | Cell-centered mesh data. Must have exactly one component. |
[in] | a_particles | Particles to be deposited. |
[in] | a_deposition | Deposition type |
[in] | a_coarseFineDeposition | Coarse-fine deposition strategy |
|
protectedvirtual |
Make the "non-conservative" kappa deposition – computing depositionNC = sum(kappa*depositionC)/sum(kappa) in a neighborhood around each vof.
[out] | a_depositionNC | Non-conservative deposition |
[in] | a_depositionKappaC | Conserved deposition |
|
virtual |
Deposit particles onto mesh.
This will deposit the mass (i.e., computational weight) "bulk" particles into m_phi.
|
virtual |
Deposit particles on to mesh.
[in] | a_container | Which container to deposit. |
This will deposit mass (i.e., computational weight) of the the input particle container particles onto the classes member 'm_phi'.
void ItoSolver::depositParticles | ( | EBAMRCellData & | a_phi, |
ParticleContainer< P > & | a_particles | ||
) | const |
Generic deposition function which deposits a particle field onto the mesh using a specified deposition method.
The template parameters indicate the particle type and quantity to be deposited. The second template parameter must be a pointer to a member function in the particle class with signature 'const Real& P::function() const'. E.g. 'const Real& P::mass() const' which is the default quantity to be deposited.
[out] | a_phi | Mesh data – must have exactly one component. |
[in] | a_particles | Particles to be deposited |
void ItoSolver::depositParticles | ( | EBAMRCellData & | a_phi, |
ParticleContainer< P > & | a_particles, | ||
const DepositionType | a_deposition, | ||
const CoarseFineDeposition | a_coarseFineDeposition | ||
) | const |
Generic deposition function which deposits a particle field onto the mesh using a specified deposition method.
The template parameters indicate the particle type and quantity to be deposited. The second template parameter must be a pointer to a member function in the particle class with signature 'const Real& P::function() const'. E.g. 'const Real& P::mass() const' which is the default quantity to be deposited.
[out] | a_phi | Mesh data – must have exactly one component. |
[in] | a_particles | Particles to be deposited |
[in] | a_deposition | Deposition method |
[in] | a_coarseFineDeposition | Coarse-fine deposition strategy |
void ItoSolver::depositParticles | ( | EBAMRCellData & | a_phi, |
ParticleContainer< P > & | a_particles, | ||
const DepositionType | a_deposition, | ||
const CoarseFineDeposition | a_coarseFineDeposition | ||
) | const |
Generic deposition function which deposits a particle field onto the mesh using a specified deposition method.
Just like the version above, but with a different function signature.
[out] | a_phi | Mesh data – must have exactly one component. |
[in] | a_particles | Particles to be deposited |
[in] | a_deposition | Deposition method |
[in] | a_coarseFineDeposition | Coarse-fine deposition strategy |
|
noexcept |
Do an NGP deposit on a specific grid level. Used for IO.
[out] | a_output | Contains NGP deposition of particles. Ignores cut-cells. |
[in] | a_particles | Particles |
[in] | a_level | Grid level |
|
noexcept |
Do an NGP deposit on a specific grid level. Used for IO.
[out] | a_output | Contains NGP deposition of particles. Ignores cut-cells. |
[in] | a_particles | Particles |
[in] | a_level | Grid level |
|
protected |
Restart particles from a specified number of particles in the grid cell.
This will instantiate the bulk particles by randomly drawing new particles in each grid cell.
[in] | a_particlesPerCell | Mesh data showing how many particles are in each cell. |
[in] | a_level | Grid level. |
[in] | a_newPPC | Desired number of computational particles per cell |
DepositionType ItoSolver::getDeposition | ( | ) | const |
Get deposition method.
|
virtual |
Get the diffusion function.
|
virtual |
Get the diffusion function.
|
virtual |
Get mobility function.
|
virtual |
Get mobility function.
|
virtual |
Get this solver's name.
|
virtual |
Get number of plot variables.
|
virtual |
Get number of particles in a specified particle container.
[in] | a_whichContainer | Which container to count particles in. |
[in] | a_localOnly | Only report local particles (i.e. not reduced over MPI ranks) |
|
virtual |
Get a general particle container.
[in] | a_container | Which container to fetch. |
|
virtual |
Get a general particle container.
[in] | a_container | Which container to fetch. |
phase::which_phase ItoSolver::getPhase | ( | ) | const |
Return phase.
|
virtual |
Get the mesh data.
|
virtual |
Get output plot names.
|
virtual |
Get the realm where this solver is registered.
|
virtual |
Get the species.
|
virtual |
Get cell-centered velocity mesh data.
|
virtual |
Get cell-centered velocity mesh data.
|
virtual |
Set the initial data.
This will add the initial particles and deposit them.
|
virtual |
Interpolate the diffusion field to the particle positions.
This computes D_p = Df(X_p) where Df is the diffusion field on the mesh.
|
protectedvirtual |
Interpolate the diffusion field to the particle positions.
This computes D_p = Df(X_p) where Df is the diffusion field on the mesh.
[in] | a_level | Grid level |
[in] | a_dit | Grid index |
|
virtual |
Interpolate mobilities.
This will switch between the two ways of computing the particle mobility.
|
protectedvirtualnoexcept |
Interpolate mobilities – this will switch between the two ways of computing the particle mobility.
[in] | a_level | Grid level. |
[in] | a_dit | Grid index. |
[in] | a_velocityMagnitude | Velocity magnitude. |
|
protectedvirtualnoexcept |
Directly interpolate mobilities. Interpolates for all particles in the specified grid patch.
[in] | a_level | Grid level. |
[in] | a_dit | Grid index. |
|
protectedvirtualnoexcept |
Interpolate mobilities through the velocity. Interpolates for all particles in the specified grid patch.
[in] | a_level | Grid level. |
[in] | a_dit | Grid index. |
[in] | a_velocityMagnitude | Velocity magnitude. |
|
virtual |
Interpolate the particle velocities.
This will compute the particle velocities as v = mu * V(Xp) where mu is the particle mobility and V(Xp) is the interpolation of m_velocityFunction to the particle position.
|
virtual |
Interpolate the particle velocities.
This will compute the particle velocities as v = mu * V(Xp) where mu is the particle mobility and V(Xp) is the interpolation of m_velocityFunction to the particle position.
[in] | a_level | Grid level |
[in] | a_dit | Grid index |
|
virtual |
Do boundary intersection tests.
This will intersect the particles in the "bulk" particles data holder with the domain faces and EBs. If a particle crossed the EB it will be put into the "EB" particle data holder and likewise for the particles that crossed the domain side.
[in] | a_ebIntersection | Enum for switching between various types of intersection tests. |
[in] | a_deleteParticles | If true, the origin particle will also be removed from the bulk particle data holder. |
[in] | a_nonDeletionModifier | Optional input argument for letting the user manipulate particles that were intersected but not deleted |
|
virtual |
Do boundary intersection tests.
This will intersect the particles in the a_particles data holder with the domain faces and EBs. If a particle crossed the EB it will be put into the a_eb_particles particle data holder and likewise for the particles that crossed the domain side.
[in] | a_particles | Which particle container to use for the "active" particles |
[in] | a_ebParticles | Which particle container to put the EB particles |
[in] | a_domainParticles | Which particle container to put the domain particles |
[in] | a_ebIntersection | Enum for switching between various types of intersection tests. |
[in] | a_deleteParticles | If true, the origin particle will also be removed from the bulk particle data holder. |
[in] | a_nonDeletionModifier | Optional input argument for letting the user manipulate particles that were intersected but not deleted |
|
virtual |
Do boundary intersection tests.
This will intersect the particles in the a_particles data holder with the domain faces and EBs. If a particle crossed the EB it will be put into the a_eb_particles particle data holder and likewise for the particles that crossed the domain side.
[in] | a_particles | Which particle container to use for the "active" particles |
[in] | a_ebParticles | Which particle container to put the EB particles |
[in] | a_domainParticles | Which particle container to put the domain particles |
[in] | a_ebIntersection | Enum for switching between various types of intersection tests. |
[in] | a_deleteParticles | If true, the origin particle will also be removed from the bulk particle data holder. |
[in] | a_nonDeletionModifier | Optional input argument for letting the user manipulate particles that were intersected but not deleted |
|
virtual |
Check if solver is diffusive.
|
virtual |
Check if solver is mobile.
|
virtual |
Make superparticles for a full container – this is the AMR version that users will usually call.
[in] | a_container | Which container to repartition into new superparticles |
[in] | a_particlesPerCell | Target number of particles per cell |
|
virtual |
Make superparticles for a particle container – this is used for a specified grid level.
[in] | a_container | Which container to repartition into new superparticles |
[in] | a_particlesPerCell | Target number of particles per cell |
[in] | a_level | Grid level |
|
virtual |
Make superparticles for a particle container – this is used for a specified grid level and patch.
[in] | a_container | Which container to repartition into new superparticles |
[in] | a_particlesPerCell | Target number of particles per cell |
[in] | a_level | Grid level |
[in] | a_dit | Grid index |
|
virtual |
Make superparticles for a full container – this is the AMR version that users will usually call.
[in] | a_container | Which container to repartition into new superparticles |
[in] | a_particlesPerCell | Target number of particles per cell. Vector indicates grid levels. |
|
virtualnoexcept |
Superparticle merging with KD/BVH trees.
[in,out] | a_particles | Particles to be merged/split |
[in] | a_cellInfo | Arithmetic information about the current grid cell. |
[in] | a_particlesPerCell | Target number of particles per cell |
|
virtualnoexcept |
General superparticle merging with underlying algorithm through m_particleMerger.
[in,out] | a_particles | Particles to be merged/split |
[in] | a_cellInfo | Arithmetic information about the current grid cell. |
[in] | a_particlesPerCell | Target number of particles per cell |
|
virtual |
Sort the input particle container by cell.
[in] | a_container | Container to be sorted. |
|
virtual |
Sort the input particle container by patch.
[in] | a_container | Container to be sorted. |
|
virtual |
Perform pre-regrid operations.
[in] | a_lbase | Coarsest level that changed during regrid. |
[in] | a_oldFinestLevel | Finest grid level before the regrid operation. |
|
inline |
Draw a random direction in N-dimensional space.
We use the algorithm by Marsaglia (1972).
|
inline |
Draw a random N-dimensional Gaussian number from a normal distribution with zero with and unit standard deviation.
|
protectedvirtual |
Redistribute mass in an AMR context.
We will have deposited particles into each cell, i.e. phi_i = m_i/dx^3. To obtain the true density in an EB context we need to divide by kappa such that phi_i = m_i/(kappa_i*dx^3). Unfortunately, this is numerically unstable because kappa_i can be arbitrarily small. We can set the density as phi_i = m_i/dx^3 but we will be missing a mass m_i*(1-kappa_i) from the cell. This mass can be smooshed into neighboring cells such as to make the total scheme conservative. As an option, we can also use a "non-conservative" divergence but the scheme is not guaranteed to be non-negative. All of this is just to say that we take the mass that fell inside the EB and put it back into the domain.
[in,out] | a_phi | Quantity to be redistributed. |
|
virtual |
Register operators.
This will register the required operators for running this class.
|
virtual |
Regrid this solver.
[in] | a_lmin | Coarsest level where grids did not change. |
[in] | a_oldFinestLevel | Finest AMR level before the regrid. |
[in] | a_newFinestLevel | Finest AMR level after the regrid. |
|
virtualnoexcept |
Particle re-initialization algorithm.
[in,out] | a_particles | Particles to be merged/split |
[in] | a_cellInfo | Arithmetic information about the current grid cell. |
[in] | a_particlesPerCell | Target number of particles per cell |
|
virtual |
Remap all particles in the input container.
[in] | a_container | Particle container |
|
virtual |
Remove particles that are inside the EB.
[in] | a_ebRepresentation | EB representation (e.g. implicit function, discrete, voxel) |
[in] | a_tol | Tolerance – removes particles if they are less than a_tol*dx away from the boundary. |
Calls the other version with m_particles.
|
virtual |
Remove particles that are inside the EB.
[in] | a_container | Which particle container to remove particles from |
[in] | a_ebRepresentation | EB representation (e.g. implicit function, discrete, voxel) |
[in] | a_tol | Tolerance – removes particles if they are less than a_tol*dx away from the boundary. |
|
virtual |
Remove particles that are inside the EB.
[in] | a_particles | Particles to remove. |
[in] | a_ebRepresentation | EB representation (e.g. implicit function, discrete, voxel) |
[in] | a_tol | Tolerance – removes particles if they are less than a_tol*dx away from the boundary. |
|
virtual |
|
virtual |
Set computational geometry.
[in] | a_computationalGeometry | Computational geometry. |
|
virtual |
Utility function – set a constant diffusion coefficient.
[in] | a_diffusionCoefficient | Diffusion coefficient |
|
virtual |
Sets diffusion coefficient for all particles.
[in] | a_diffusion | Particle diffusion value. |
|
virtualnoexcept |
Set the particle merger. This will get called when merging particles using makeSuperparticles.
[in] | a_particleMerger | Particle merger |
|
virtual |
Sets mobility coefficient for all particles.
[in] | a_mobility | Particle mobility. |
|
virtual |
Set phase where the particles will live.
[in] | a_phase | Phase |
|
virtual |
Set the realm where this solver will live.
[in] | a_realm | Realm name. |
|
virtual |
Set the species.
[in] | a_species | Species to be solved for. |
|
virtual |
Set the time for this solver.
[in] | a_step | Time step number |
[in] | a_time | Time (in seconds) |
[in] | a_dt | Time step increment |
|
virtual |
Utility function – set a constant velocity.
[in] | a_velocity | Velocity |
|
virtual |
Set verbosity level for this solver.
[in] | a_verbosity | Verbosity level. |
|
virtual |
Transfer particles that are covered (within a_tol distance from EB) to another container.
Calls the other version with m_particles and m_coveredParticles
[in] | a_ebRepresentation | EB representation (e.g. implicit function, discrete, voxel) |
[in] | a_tol | Tolerance – removes particles if they are less than a_tol*dx away from the boundary. |
|
virtual |
Transfer particles that are covered (within a_tol distance from EB) to another container.
[in] | a_containerFrom | Which particle container to transfer particles from |
[in] | a_containerFrom | Which particle container to move particles into |
[in] | a_ebRepresentation | EB representation (e.g. implicit function, discrete, voxel) |
[in] | a_tol | Tolerance – removes particles if they are less than a_tol*dx away from the boundary. |
|
virtual |
Transfer particles that are inside the EB to another container.
[in] | a_particlesFrom | Which particle container to transfer particles from |
[in] | a_particlesTo | Which particle container to move particles into |
[in] | a_ebRepresentation | EB representation (e.g. implicit function, discrete, voxel) |
[in] | a_tol | Tolerance – removes particles if they are less than a_tol*dx away from the boundary. |
|
virtual |
Update mobilities parametrically from the particle energy.
This calls the diffusion function implemented by ItoSpecies. The particle diffusion is set D = f(p.energy()) where f is the diffusion function in ItoSpecies
|
protectedvirtual |
Update mobilities parametrically from the particle energy.
This calls the diffusion function implemented by ItoSpecies. The particle diffusion is set D = f(p.energy()) where f is the diffusion function in ItoSpecies
[in] | a_level | Grid level |
[in] | a_dit | Grid index |
|
virtual |
Update mobilities parametrically from the particle energy.
This calls the mobility function implemented by ItoSpecies. The particle mobility is set mu = f(p.energy()) where f is the mobility function in ItoSpecies
|
protectedvirtual |
Update mobilities parametrically from the particle energy.
This calls the mobility function implemented by ItoSpecies. The particle mobility is set mu = f(p.energy()) where f is the mobility function in ItoSpecies
[in] | a_level | Grid level |
[in] | a_dit | Grid index |
|
protectedvirtualnoexcept |
Write data to output. Convenience function.
[in,out] | a_output | Output data holder. |
[in,out] | a_icomp | Starting component where this solver begins writing the output. |
[in] | a_data | Data to write. |
[in] | a_outputRealm | Realm where a_output belongs |
[in] | a_level | Grid level |
[in] | a_interpToCentroids | If true, a_data will be interpolated to cell centroids before writing to a_output. |
[in] | a_interpGhost | If true, interpolate ghost cells |
|
virtualnoexcept |
Write plot data.
[in,out] | a_output | Output data holder. |
[in,out] | a_icomp | Starting component where this solver begins writing the output. |
[in] | a_outputRealm | Realm where a_output belongs |
[in] | a_level | Grid level |
|
protected |
Class name.
ItoSolver for parent class – derived classes might be named something else.
|
protected |
Truncation value for normal distribution.
This is used when drawing numbers from the Gaussian distribution, replacing all values above m_normalDistributionTruncation by m_normalDistributionTruncation.