chombo-discharge
Loading...
Searching...
No Matches
CD_ItoKMCBackgroundEvaluator.H
Go to the documentation of this file.
1/* chombo-discharge
2 * Copyright © 2025 SINTEF Energy Research.
3 * Please refer to Copyright.txt and LICENSE in the chombo-discharge root directory.
4 */
5
12#ifndef CD_ItoKMCBackgroundEvaluator_H
13#define CD_ItoKMCBackgroundEvaluator_H
14
15// Our includes
17#include <CD_NamespaceHeader.H>
18
19namespace Physics {
20 namespace ItoKMC {
21
25 template <typename I = ItoSolver, typename C = CdrCTU, typename R = McPhoto, typename F = FieldSolverGMG>
27 {
28 public:
34
38 virtual void
39 postInitialize() noexcept override final;
40
44 virtual void
45 postRegrid() noexcept override final;
46
50 virtual void
51 postCheckpointSetup() noexcept override final;
52
56 virtual void
57 printStepReport() noexcept override final;
58
63 virtual Real
64 advance(const Real a_dt) override;
65
70 virtual Real
71 computeDt() override;
72
73 protected:
78
83
91
96
101
106
111
116
121
126
132
136 virtual void
138
143 [[nodiscard]]
146
151 [[nodiscard]]
154
159 [[nodiscard]]
162
167 [[nodiscard]]
170 };
171 } // namespace ItoKMC
172} // namespace Physics
173
174#include <CD_NamespaceFooter.H>
175
177
178#endif
Implementation of CD_ItoKMCBackgroundEvaluator.H.
Declaration of a class which uses a semi-implicit Godunov method for Ito plasma equations.
Implementation of ItoKMCGodunovStepper that also evaluates the background field at every regrid/time ...
Definition CD_ItoKMCBackgroundEvaluator.H:27
virtual void postRegrid() noexcept override final
Post-regrid operations. Computes the background field.
Definition CD_ItoKMCBackgroundEvaluatorImplem.H:65
Real m_maxInitialTimeStep
Initial time step size. Introduced to limit the initial particles from moving to far in the initial t...
Definition CD_ItoKMCBackgroundEvaluator.H:90
virtual Real integrateElectrodeSurfaceCharge() const noexcept
Compute total charge on electrode.
Definition CD_ItoKMCBackgroundEvaluatorImplem.H:317
std::string m_opticalSolver
Name of the optical solver.
Definition CD_ItoKMCBackgroundEvaluator.H:125
virtual void computeBackgroundField() noexcept
Computes the background field. I.e., it allocates and fills m_backgroundField.
Definition CD_ItoKMCBackgroundEvaluatorImplem.H:177
virtual std::pair< Real, Real > evaluateSpaceChargeEffects() noexcept
Evaluate the maximum change in the background field.
Definition CD_ItoKMCBackgroundEvaluatorImplem.H:219
virtual void printStepReport() noexcept override final
Print a new step report. This is the old one plus the maximum field change.
Definition CD_ItoKMCBackgroundEvaluatorImplem.H:151
Real m_maxFieldChange
Change in max field.
Definition CD_ItoKMCBackgroundEvaluator.H:95
MFAMRCellData m_backgroundField
For storing the background field.
Definition CD_ItoKMCBackgroundEvaluator.H:131
Real m_relFieldExitCrit
Exit criterion for relative field – if the relative change in the background field in any cell change...
Definition CD_ItoKMCBackgroundEvaluator.H:82
virtual Real integrateOhmicCharge() const noexcept
Compute the total ohmic current through the electrode.
Definition CD_ItoKMCBackgroundEvaluatorImplem.H:376
Real m_relFieldChange
Change in relative field.
Definition CD_ItoKMCBackgroundEvaluator.H:100
virtual Real advance(const Real a_dt) override
Overriden advance method.
Definition CD_ItoKMCBackgroundEvaluatorImplem.H:93
Real m_sumOpticalPhi
Integrated optical emissions (phi)
Definition CD_ItoKMCBackgroundEvaluator.H:115
Real m_sumOpticalSrc
Integrated optical emissions (source term)
Definition CD_ItoKMCBackgroundEvaluator.H:120
virtual void postInitialize() noexcept override final
Post-initialization operations. Computes the background field.
Definition CD_ItoKMCBackgroundEvaluatorImplem.H:51
Real m_electrodeCharge
Total charge on the electrode, given by \int(eps*E dA)
Definition CD_ItoKMCBackgroundEvaluator.H:105
virtual void postCheckpointSetup() noexcept override final
Post-checkpoint operations. Computes the background field.
Definition CD_ItoKMCBackgroundEvaluatorImplem.H:79
virtual Real computeDt() override
Compute a time step used for the advance method.
Definition CD_ItoKMCBackgroundEvaluatorImplem.H:134
Real m_maxFieldExitCrit
Exit criterion for maximum field – if the background field changes by this much the simulation is ter...
Definition CD_ItoKMCBackgroundEvaluator.H:77
Real m_ohmicCharge
Total charge that left through the electrode in the last time step.
Definition CD_ItoKMCBackgroundEvaluator.H:110
virtual std::pair< Real, Real > integrateOpticalExcitations() const noexcept
Integrate the sum of the optical excitations.
Definition CD_ItoKMCBackgroundEvaluatorImplem.H:388
Implementation of ItoKMCStepper that uses a semi-implicit split-step formalism for advancing the Ito-...
Definition CD_ItoKMCGodunovStepper.H:29
Base class for a tracer particle solver. This solver can advance particles in a pre-defined velocity ...
Definition CD_TracerParticleSolver.H:37
TracerParticleSolver()
Default constructor.
Definition CD_TracerParticleSolverImplem.H:25
Name containing various physics models for running chombo-discharge code.
Definition CD_AdvectionDiffusion.H:15