|
|
| ItoKMCJSON () |
| | Default constructor.
|
| |
|
virtual | ~ItoKMCJSON () noexcept |
| | Destructor.
|
| |
| virtual void | parseRuntimeOptions () noexcept override |
| | Parse run-time options.
|
| |
| virtual Real | getNeutralDensity (const RealVect a_pos) const noexcept override |
| | Get the neutral density at a position in space.
|
| |
| virtual Real | computeAlpha (const Real a_E, const RealVect a_pos) const noexcept override |
| | Compute Townsend ionization coefficient.
|
| |
| virtual Real | computeEta (const Real a_E, const RealVect a_pos) const noexcept override |
| | Compute Townsend attachment coefficient.
|
| |
| virtual Vector< std::string > | getPlotVariableNames () const noexcept override |
| | Get number of plot variables.
|
| |
| virtual Vector< Real > | getPlotVariables (const RealVect a_E, const RealVect a_pos, const Vector< Real > &a_phi, const Vector< RealVect > &a_gradPhi, const Real a_dx, const Real a_kappa) const noexcept override |
| | Get plot variables.
|
| |
| virtual int | getNumberOfPlotVariables () const noexcept override |
| | Get number of plot variables.
|
| |
| virtual bool | needGradients () const noexcept override |
| | Return true/false if physics model needs species gradients.
|
| |
| virtual Vector< Real > | computeMobilities (const Real a_time, const RealVect a_pos, const RealVect a_E) const noexcept override |
| | Compute the Ito solver mobilities.
|
| |
| virtual Vector< Real > | computeDiffusionCoefficients (const Real a_time, const RealVect a_pos, const RealVect a_E) const noexcept override |
| | Compute the Ito solver diffusion coefficients.
|
| |
| virtual void | secondaryEmissionEB (Vector< List< ItoParticle > > &a_secondaryParticles, Vector< Real > &a_secondaryCDRFluxes, Vector< List< Photon > > &a_secondaryPhotons, const Vector< List< ItoParticle > > &a_primaryParticles, const Vector< Real > &a_primaryCDRFluxes, const Vector< List< Photon > > &a_primaryPhotons, const RealVect &a_E, const RealVect &a_cellCenter, const RealVect &a_cellCentroid, const RealVect &a_bndryCentroid, const RealVect &a_bndryNormal, const Real a_bndryArea, const Real a_dx, const Real a_dt, const bool a_isDielectric, const int a_matIndex) const noexcept override |
| | Resolve secondary emission at the EB.
|
| |
|
| ItoKMCPhysics () noexcept |
| | Constructor. Does nothing.
|
| |
|
virtual | ~ItoKMCPhysics () noexcept |
| | Destructor. Does nothing.
|
| |
|
void | defineKMC () const noexcept |
| | Define the KMC solver and state.
|
| |
|
void | killKMC () const noexcept |
| | Kill the KMC solver.
|
| |
| const Vector< RefCountedPtr< ItoSpecies > > & | getItoSpecies () const |
| | Get all particle drift-diffusion species.
|
| |
| const Vector< RefCountedPtr< CdrSpecies > > & | getCdrSpecies () const |
| | Get all fluid drift-diffusion species.
|
| |
| const Vector< RefCountedPtr< RtSpecies > > & | getRtSpecies () const |
| | Get all photon species.
|
| |
|
const Vector< DiffusionFunction > & | getItoDiffusionFunctions () const noexcept |
| | Get diffusion functions.
|
| |
|
int | getNumItoSpecies () const |
| | Return number of Ito solvers.
|
| |
|
int | getNumCdrSpecies () const |
| | Return number of CDR solvers.
|
| |
|
int | getNumPlasmaSpecies () const |
| | Return total number of plasma species.
|
| |
|
int | getNumPhotonSpecies () const |
| | Return number of RTE solvers.
|
| |
|
const std::map< int, std::pair< SpeciesType, int > > & | getSpeciesMap () const noexcept |
| | Get the internal mapping between plasma species and Ito solvers.
|
| |
| virtual Real | initialSigma (const Real a_time, const RealVect a_pos) const |
| | Set initial surface charge. Default is 0, override if you want.
|
| |
| void | advanceKMC (Vector< FPR > &a_numParticles, Vector< FPR > &a_numNewPhotons, Real &a_physicsDt, const Vector< Real > &a_phi, const Vector< RealVect > &a_gradPhi, const Real a_dt, const RealVect a_E, const RealVect a_pos, const Real a_dx, const Real a_kappa) const |
| | Advance the reaction network using the KMC algorithm.
|
| |
| void | reconcileParticles (Vector< List< ItoParticle > * > &a_particles, const Vector< FPR > &a_newNumParticles, const Vector< FPR > &a_oldNumParticles, const RealVect a_electricField, const RealVect a_cellPos, const RealVect a_centroidPos, const RealVect a_lo, const RealVect a_hi, const RealVect a_bndryCentroid, const RealVect a_bndryNormal, const Real a_dx, const Real a_kappa) const noexcept |
| | Reconcile the number of particles.
|
| |
| void | reconcilePhotons (Vector< List< Photon > * > &a_newPhotons, const Vector< FPR > &a_numNewPhotons, const RealVect a_cellPos, const RealVect a_centroidPos, const RealVect a_lo, const RealVect a_hi, const RealVect a_bndryCentroid, const RealVect a_bndryNormal, const Real a_dx, const Real a_kappa) const noexcept |
| | Generate new photons.
|
| |
| void | reconcilePhotoionization (Vector< List< ItoParticle > * > &a_itoParticles, Vector< List< PointParticle > * > &a_cdrParticles, const Vector< List< Photon > * > &a_absorbedPhotons) const noexcept |
| | Reconcile photoionization reactions.
|
| |
|
| virtual std::string | trim (const std::string &a_string) const noexcept |
| | Trim a string. This removes whitespace before/after.
|
| |
|
virtual void | parseJSON () |
| | Parse the JSON file.
|
| |
|
virtual void | parseVerbose () noexcept |
| | Parse chattiness.
|
| |
| virtual void | throwParserError (const std::string a_error) const noexcept |
| | Throw a parser error.
|
| |
| virtual void | throwParserWarning (const std::string a_warning) const noexcept |
| | Throw a parser wearning.
|
| |
| virtual bool | doesFileExist (const std::string a_filename) const noexcept |
| | Check if a file exists.
|
| |
| virtual bool | isBackgroundSpecies (const std::string &a_name) const noexcept |
| | Return true if species is a background species.
|
| |
| virtual bool | isPlasmaSpecies (const std::string &a_name) const noexcept |
| | Return true if species is a plasma species.
|
| |
| virtual bool | isPhotonSpecies (const std::string &a_name) const noexcept |
| | Return true if species is a photon species.
|
| |
| virtual bool | containsWildcard (const std::string a_str) const noexcept |
| | Check if a string contains the wildcard @ and return true if it does.
|
| |
| virtual bool | containsBracket (const std::string a_str) const noexcept |
| | Check if a string contains standard brackets.
|
| |
| virtual bool | isBracketed (const std::string a_str) const noexcept |
| | Check if a string contains starts with '(' and ends with ')'.
|
| |
| virtual void | checkMolarFraction (const RealVect a_position) const noexcept |
| | Check that molar fraction is one. Throws a warning if it isn't.
|
| |
| virtual void | sanctifyPlasmaReaction (const std::vector< std::string > &a_reactants, const std::vector< std::string > &a_products, const std::string &a_reaction) const noexcept |
| | Check that a plasma reaction makes sense. I.e. that all species are properly defined and that it conserves charge.
|
| |
| virtual void | sanctifyPhotoReaction (const std::vector< std::string > &a_reactants, const std::vector< std::string > &a_products, const std::string &a_reaction) const noexcept |
| | Check that a photo-reaction makes sense. I.e. that all species are properly defined and that it conserves charge.
|
| |
|
virtual void | initializeGasLaw () |
| | Initialize gas law.
|
| |
|
virtual void | initializeBackgroundSpecies () |
| | Initialize the background species.
|
| |
| virtual void | initializeTownsendCoefficient (const std::string a_coeff) |
| | Parse one of the Townsend coefficients.
|
| |
| virtual void | initializeAutomaticTownsend (const std::string a_coeff) |
| | Initialize automatic Townsend coefficient (ionizatino or attachment) from the reaction rates.
|
| |
| virtual void | previewFunctionEX (const nlohmann::json &a_json, const FunctionEX &a_function) const |
| | Simple function for previewing a rate/coefficient defined as a function f = f(E,x)
|
| |
|
virtual void | printFluidRates () const noexcept |
| | Print the fluid-representation of the reaction rates.
|
| |
|
virtual void | initializePlasmaSpecies () |
| | Initialize the plasma species.
|
| |
|
virtual void | initializeParticles () |
| | Parse initial particles.
|
| |
|
virtual void | initializeDensities () |
| | Parse initial densities for CDR and Ito species.
|
| |
|
virtual void | initializeMobilities () |
| | Initialize mobility functions.
|
| |
|
virtual void | initializeDiffusionCoefficients () |
| | Initialize diffusion coefficients.
|
| |
|
virtual void | initializeTemperatures () |
| | Initialize the plasma species temperatures.
|
| |
|
virtual void | initializePhotonSpecies () |
| | Initialize the photon species.
|
| |
|
virtual void | initializePlasmaReactions () |
| | Initialize plasma reactions.
|
| |
|
virtual void | initializePhotoReactions () |
| | Initialize photo-reactions.
|
| |
| virtual void | initializeSurfaceEmission (const std::string a_surface) |
| | Initialize surface reactions.
|
| |
|
virtual void | initializeFieldEmission () |
| | Initialize field emission reactions.
|
| |
|
virtual void | initializeParticlePlacement () |
| | Initialize the particle placement algorithm.
|
| |
| virtual void | parseReactionString (std::vector< std::string > &a_reactants, std::vector< std::string > &a_products, const std::string &a_reaction) const noexcept |
| | Parses a reaction string into reactangs and products.
|
| |
| virtual void | getReactionSpecies (std::list< size_t > &a_backgroundReactants, std::list< size_t > &a_plasmaReactants, std::list< size_t > &a_photonReactants, std::list< size_t > &a_backgroundProducts, std::list< size_t > &a_plasmaProducts, std::list< size_t > &a_photonProducts, const std::vector< std::string > &a_reactants, const std::vector< std::string > &a_products) const noexcept |
| | Turn reactants and products strings into indices.
|
| |
| virtual std::pair< FunctionEVXTP, FunctionEX > | parsePlasmaReactionRate (const nlohmann::json &a_reactionJSON, const std::list< size_t > &a_backgroundReactants, const std::list< size_t > &a_plasmaReactants) const |
| | Parse a plasma reaction rate and turn it into a function.
|
| |
| virtual std::pair< bool, std::string > | parsePlasmaReactionPlot (const nlohmann::json &a_reactionJSON) const |
| | Parse whether or not a reaction rate should be plotted.
|
| |
| virtual std::pair< bool, std::string > | parsePlasmaReactionGradientCorrection (const nlohmann::json &a_reactionJSON) const |
| | Parse whether or not a reaction uses a gradient correction for the rate.
|
| |
|
virtual Real | parsePlasmaReactionDt (const nlohmann::json &a_reactionJSON) const |
| | Parse whether or not a reaction should be a part of the time step calculation. Returns 1 if the reaction is a part of it.
|
| |
| virtual LookupTable1D< Real, 1 > | parseTableEByN (const nlohmann::json &a_tableEntry, const std::string &a_dataID) const |
| | Parse a table which is stored in E/N format.
|
| |
| virtual std::vector< std::tuple< std::string, std::vector< std::string >, std::vector< std::string > > > | parseReactionWildcards (const std::vector< std::string > &a_reactants, const std::vector< std::string > &a_products, const nlohmann::json &a_reactionJSON) const noexcept |
| | Make a reaction set into a superset. This parses wildcards '@' in reaction string.
|
| |
| virtual void | updateReactionRates (std::vector< std::shared_ptr< const KMCReaction > > &a_kmcReactions, const RealVect a_E, const RealVect a_pos, const Vector< Real > &a_phi, const Vector< RealVect > &a_gradPhi, const Real a_dt, const Real a_dx, const Real a_kappa) const noexcept override |
| | Update reaction rates.
|
| |
| std::vector< size_t > | multinomial (const size_t N, const std::discrete_distribution< size_t > &a_distribution) const noexcept |
| | Sample a multinomial distribution with N samples.
|
| |
|
void | define () noexcept |
| | Define method – defines all the internal machinery.
|
| |
| void | defineSpeciesMap () noexcept |
| | Build internal representation of how we distinguish the Ito and CDR solvers.
|
| |
|
void | definePhotoPathways () noexcept |
| | Define pathways for photo-reactions.
|
| |
|
void | parsePPC () noexcept |
| | Parse the maximum number of particles generated per cell.
|
| |
|
void | parseDebug () noexcept |
| | Parse the maximum number of particles generated per cell.
|
| |
|
void | parseAlgorithm () noexcept |
| | Parse reaction algorithm.
|
| |
| void | removeParticles (List< ItoParticle > &a_particles, const long long a_numToRemove) const |
| | Remove particles from the input list.
|
| |
| bool | computeUpstreamPosition (RealVect &a_pos, RealVect &a_lo, RealVect &a_hi, const int &a_Z, const List< ItoParticle > &a_particles, const RealVect &a_electricField, const RealVect &a_cellPos, const Real &a_dx) const noexcept |
| | Compute the upstream position in a grid cell. Returns false if an upstream position was undefinable.
|
| |
| RealVect | noDiffusion (const ItoParticle &a_particle, const Real a_dt) const noexcept |
| | No diffusion function for a particle.
|
| |
| RealVect | isotropicDiffusion (const ItoParticle &a_particle, const Real a_dt) const noexcept |
| | Isotropic diffusion function for a particle.
|
| |
| RealVect | forwardIsotropicDiffusion (const ItoParticle &a_particle, const Real a_dt) const noexcept |
| | Quasi-isotropic diffusion function for a particle which does not permit backward diffusion.
|
| |
|
|
bool | m_verbose |
| | Verbose or not.
|
| |
|
bool | m_plotGas |
| | Plot gas pressure, density, and temperature.
|
| |
|
bool | m_plotAlpha |
| | Plot Townsend ionization coefficient.
|
| |
|
bool | m_plotEta |
| | Plot Townsend attachment coefficient.
|
| |
|
bool | m_skipReactions |
| | A flag for skipping reactions completely.
|
| |
|
bool | m_previewRates |
| | Preview rates or not.
|
| |
|
int | m_numPlasmaSpecies |
| | Total number of plasma species.
|
| |
|
int | m_numPhotonSpecies |
| | Total number of photon species.
|
| |
|
nlohmann::json | m_json |
| | Nohmanns implementation of JSON files.
|
| |
|
std::string | m_jsonFile |
| | Input JSON file name.
|
| |
| std::set< std::string > | m_allSpecies |
| | All species that have been defined.
|
| |
|
std::map< std::string, int > | m_backgroundSpeciesMap |
| | Map of string-int identifiers for background species.
|
| |
|
std::map< int, std::string > | m_backgroundSpeciesMapInverse |
| | Map of int-string identifiers for background species.
|
| |
| std::vector< ItoKMCBackgroundSpecies > | m_backgroundSpecies |
| | Map of background species.
|
| |
| std::vector< bool > | m_backgroundSpeciesPlot |
| | Plot background species or not.
|
| |
|
std::map< std::string, SpeciesType > | m_plasmaSpeciesTypes |
| | Map for identifying a species name with a solver type.
|
| |
|
std::map< std::string, int > | m_itoSpeciesMap |
| | Map for indexing from an ID to an Ito solver index.
|
| |
|
std::map< std::string, int > | m_cdrSpeciesMap |
| | Map for indexing from an ID to an Ito solver index.
|
| |
|
std::map< std::string, int > | m_plasmaIndexMap |
| | Map for indexing a plasma species name to a global index in the solver vectors.
|
| |
|
std::map< std::string, int > | m_photonIndexMap |
| | Map for indexing a photon species name to a global index in the solver vectors.
|
| |
|
std::vector< FunctionEX > | m_mobilityFunctions |
| | Mobilities for the various species.
|
| |
|
std::vector< FunctionEX > | m_diffusionCoefficients |
| | Diffusion coefficients for the various species.
|
| |
|
std::vector< FunctionEX > | m_plasmaTemperatures |
| | Plasma species temperatures.
|
| |
|
std::vector< FunctionEVXTP > | m_kmcReactionRates |
| | Function-based plasma reaction rates. Same index as the actual reactions.
|
| |
| std::vector< FunctionEX > | m_fluidRates |
| | Function-based plasma reaction rates as if they appeared in the reaction rate equation. Same index as actual reactions.
|
| |
|
std::vector< std::list< size_t > > | m_plasmaReactionBackgroundReactants |
| | List of background species involved in a reaction.
|
| |
|
std::vector< std::list< size_t > > | m_plasmaReactionPlasmaReactants |
| | List of plasma species on the left-hand side of a reaction.
|
| |
|
std::vector< std::list< size_t > > | m_plasmaReactionPlasmaProducts |
| | List of plasma species on the right-hand side of a reaction.
|
| |
|
std::vector< std::list< size_t > > | m_plasmaReactionPhotonProducts |
| | List of photon species on the right-hand side of a reaction.
|
| |
|
std::vector< std::pair< bool, std::string > > | m_kmcReactionGradientCorrections |
| | Whether or not a reaction uses a gradient correction for the rate (Soloviev et. al. paper)
|
| |
|
std::vector< std::pair< bool, std::string > > | m_kmcReactionRatePlots |
| | Map of reactions that will be plotted.
|
| |
|
std::map< int, std::pair< bool, int > > | m_plasmaReactionSolovievCorrection |
| | Map of reactions that will be plotted.
|
| |
|
std::pair< bool, std::string > | m_autoAlpha |
| | Flag if the user wants to compute the alpha coefficient from the reactions.
|
| |
|
std::pair< bool, std::string > | m_autoEta |
| | Flag if the user wants to compute the alpha coefficient from the reactions.
|
| |
|
std::vector< std::pair< int, FunctionEN > > | m_dielectricFieldEmission |
| | List of dielectric field emission reactions.
|
| |
|
std::vector< std::pair< int, FunctionEN > > | m_electrodeFieldEmission |
| | List of electrode field emission reactions.
|
| |
|
FunctionEX | m_alpha |
| | Townsend ionization coefficient. Defined during parseAlpha.
|
| |
|
FunctionEX | m_eta |
| | Townsend attachment coefficient. Defined during parseEta.
|
| |
|
FunctionX | m_gasPressure |
| | Background gas pressure.
|
| |
|
FunctionX | m_gasTemperature |
| | Background gas temperature.
|
| |
|
FunctionX | m_gasNumberDensity |
| | Background gas number density.
|
| |
|
Algorithm | m_algorithm |
| | Algorithm to use for KMC advance.
|
| |
|
ParticlePlacement | m_particlePlacement |
| | Particle placement algorithm.
|
| |
|
std::map< int, std::pair< SpeciesType, int > > | m_speciesMap |
| | Map for associating a plasma species with an Ito solver or CDR solver.
|
| |
|
std::string | m_className |
| | Class name. Used for options parsing.
|
| |
|
bool | m_debug |
| | Turn on/off debugging.
|
| |
|
bool | m_isDefined |
| | Is defined or not.
|
| |
|
bool | m_incrementNewParticles |
| | If true, increment onto existing particles rather than creating new ones.
|
| |
|
std::vector< KMCReaction > | m_kmcReactions |
| | List of reactions for the KMC solver.
|
| |
|
std::vector< ItoKMCPhotoReaction > | m_photoReactions |
| | List of photoionization reactions.
|
| |
|
std::vector< Real > | m_reactiveDtFactors |
| | List of reactions that are a part of the time step limitation.
|
| |
| std::map< int, std::pair< std::discrete_distribution< int >, std::map< int, int > > > | m_photoPathways |
| | Random number generators for photoionization pathways.
|
| |
|
ItoKMCSurfaceReactionSet | m_surfaceReactions |
| | Surface reactions.
|
| |
|
Vector< DiffusionFunction > | m_itoDiffusionFunctions |
| | Diffusion functions for the various Ito species.
|
| |
|
Vector< RefCountedPtr< ItoSpecies > > | m_itoSpecies |
| | List of solver-tracked particle drift-diffusion species.
|
| |
|
Vector< RefCountedPtr< CdrSpecies > > | m_cdrSpecies |
| | List of solver-tracked fluid drift-diffusion species.
|
| |
|
Vector< RefCountedPtr< RtSpecies > > | m_rtSpecies |
| | List of solver-tracked photon species.
|
| |
| int | m_downstreamSpecies |
| | An internal integer describing which species is the "ionizing" species.
|
| |
|
int | m_maxNewParticles |
| | Maximum new number of particles generated by the chemistry advance.
|
| |
|
int | m_maxNewPhotons |
| | Maximum new number of photons generated by the chemistry advance.
|
| |
| int | m_Ncrit |
| | Solver setting for the Cao et. al algorithm.
|
| |
| int | m_NSSA |
| | Solver setting for the Cao et. al algorithm.
|
| |
|
int | m_maxIter |
| | Maximum number of iterations for implicit KMC-leaping algorithms.
|
| |
| Real | m_SSAlim |
| | Solver setting for the Cao et. al. algorithm.
|
| |
| Real | m_eps |
| | Solver setting for the Cao et. al. algorithm.
|
| |
|
Real | m_exitTol |
| | Exit tolerance for implicit KMC-leaping algorithms.
|
| |
Implementation of ItoKMCPhysics which parses input data from a JSON file.