ProblemBase

class ProblemBase

Subclassed by AirCavity1D, AirCavity1D_Moment, Checkerboard_Moment, Checkerboard_Moment_1D, Checkerboard_SN, Checkerboard_SN_1D, HalfLattice_Moment, HalfLattice_SN, Hohlraum, Lattice_Moment, Lattice_SN, LineSource, MeltingCube, PhantomImage, QuarterHohlraum, RadiationCTImage, StarMapValidation_SN, SymmetricHohlraum

Public Functions

virtual VectorVector GetScatteringXS(const Vector &energies) = 0

GetScatteringXS gives back vector (each energy) of vectors (each grid cell) of scattering cross sections for materials defined by density and energies in vector energy.

Parameters:

energies – is the energy the cross section is queried for

virtual VectorVector GetTotalXS(const Vector &energies) = 0

GetTotalXS gives back vector of vectors of total cross sections for materials defined by density and energies in vector energy.

Parameters:

energies – is the energy the cross section is queried for

inline virtual Vector GetTotalXSE(const Vector&)

GetTotalXSE gives back vector of total cross sections for energies in vector energy.

inline virtual std::vector<Matrix> GetScatteringXSE(const Vector &energies, const Matrix &angles)

GetScatteringXSE gives back vector (each energy) of scattering cross sections for energies in vector energy.

Parameters:
  • energies – is the energy the cross section is queried for

  • angles – are the queried angles

virtual VectorVector GetScatteringXSE(const Vector &energies, const Vector &angles)

GetScatteringXSE gives back vector (each energy) of scattering cross sections for energies in vector energy.

Parameters:
  • energies – is the energy the cross section is queried for

  • angles – are the queried angles

virtual std::vector<VectorVector> GetExternalSource(const Vector &energies) = 0

GetExternalSource gives back vector of vectors of source terms for each energy, cell and angle.

Parameters:

energies – is the energy the cross section is queried for

virtual Vector GetStoppingPower(const Vector &energies)

GetStoppingPower gives back vector of vectors of stopping powers for materials defined by density and energies in vector energy.

Parameters:

energies – is vector with energies

virtual std::vector<double> GetDensity(const VectorVector &cellMidPoints)

GetDensity gives back vector of densities for every spatial cell.

Parameters:

cellMidPoints – is vector with cell mid points

virtual VectorVector SetupIC() = 0

Setup the initial condition for the flux psi.

virtual const Vector &GetGhostCellValue(int idx_cell, const Vector &cell_sol)

Returns the Value of the ghost cell with index idx_cell.

inline std::map<int, Vector> &GetGhostCells()

Returns the pointer to ghostcell map.

inline virtual double GetAnalyticalSolution(double, double, double, double)

Exact analytical solution for the Line Source Test Case. Returns 0 for all other test cases.

Returns:

exact solution at x,y,t,scatteringXS

ProblemBase(Config *settings, Mesh *mesh, QuadratureBase *quad)

Physics constructor.

Parameters:
  • settings – stores all needed user information

  • mesh – for the test case

virtual void ComputeCurrentOutflow(const VectorVector &solution)

Computes Problemspeagnostic Scalar QOI.

virtual void ComputeMaxOrdinatewiseOutflow(const VectorVector &solution)

Computes Problemspeagnostic Scalar QOI.

void ComputeTotalOutflow(double dT)

Computes Problemspeagnostic Scalar QOI.

void ComputeMass(const Vector &scalarFlux)

Computes Problemspeagnostic Scalar QOI.

void ComputeChangeRateFlux(const Vector &scalarFlux, const Vector &scalarFluxNew)

Computes Problemspeagnostic Scalar QOI.

inline virtual void ComputeCurrentAbsorptionLattice(const Vector&)

Computes Problemspecific Scalar QOI.

inline virtual void ComputeMaxAbsorptionLattice(const Vector&)

Computes Problemspecific Scalar QOI.

inline virtual void ComputeCurrentAbsorptionHohlraum(const Vector&)

Computes Problemspecific Scalar QOI.

inline virtual void ComputeTotalAbsorptionHohlraum(double)

Computes Problemspecific Scalar QOI.

inline virtual void ComputeCurrentProbeMoment(const VectorVector&)

Computes Problemspecific Scalar QOI.

inline virtual void ComputeVarAbsorptionGreen(const Vector&)

Computes Problemspecific Scalar QOI.

inline virtual void ComputeQOIsGreenProbingLine(const Vector&)

Computes Problemspecific Scalar QOI.

Public Static Functions

static ProblemBase *Create(Config *settings, Mesh *mesh, QuadratureBase *quad)

Create constructor.

Parameters:
  • settings – stores all needed information

  • mesh – for the test case

Returns:

pointer to ProblemBase

Protected Functions

virtual void SetGhostCells()

Sets vector of ghost cells for boundary conditions.

Protected Attributes

Config *_settings

pointer to settings

Mesh *_mesh

pointer to mesh

QuadratureBase *_quad

pointer to quadrature

std::vector<double> _density

vector with patient densities

std::vector<double> _stoppingPower

vector with stopping powers

std::map<int, Vector> _ghostCells

Vector of ghost cells for boundary conditions.

double _curScalarOutflow

Outflow over whole boundary at current time step.

double _totalScalarOutflow

Outflow over whole boundary integrated until current time step.

double _curMaxOrdinateOutflow

Maximum ordinate-wise ouftlow over boundary over all time steps.

double _mass

Integrated radiation flux over the whole simulation (i.e. mass of the particles)

double _changeRateFlux

Integrated change of radiation flux over the whole simulation