Skip to content

Commit

Permalink
started hohlraum probing qoi
Browse files Browse the repository at this point in the history
  • Loading branch information
ScSteffen committed Dec 21, 2023
1 parent 3b60ec2 commit 0ef1627
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 5 deletions.
8 changes: 6 additions & 2 deletions include/common/config.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -94,10 +94,12 @@ class Config
double _dsgnAbsBlue; /*!< @brief Absorption in all blue blocks */
double _dsgnScatterWhite; /*!< @brief Scattering in all white blocks */
std::vector<double> _dsgnAbsIndividual; /*!< @brief Absorption in all 7x7 blocks of the Lattice test case (up left to low right) */
unsigned short _nDsgnAbsIndividual; /*!< @brief Number of individual blocks. Needs to be 47*/
unsigned short _nDsgnAbsIndividual; /*!< @brief Number of individual blocks. Needs to be 49*/
std::vector<double> _dsgnScatterIndividual; /*!< @brief Scatter in all 7x7 blocks of the Lattice test case (up left to low right) */
unsigned short _nDsgnScatterIndividual; /*!< @brief Number of individual blocks. Needs to be 47*/
unsigned short _nDsgnScatterIndividual; /*!< @brief Number of individual blocks. Needs to be 49*/

// Hohlraum
unsigned _nProbingCellsLineGreenHohlraum; /*!< @brief Number SamplingPoints for Hohlraum Green region sampling.*/
// CSD
double _maxEnergyCSD; /*!< @brief Maximum energy for CSD simulation */

Expand Down Expand Up @@ -325,6 +327,8 @@ class Config
unsigned short inline GetNLatticeAbsIndividual() { return _nDsgnAbsIndividual; }
std::vector<double> inline GetLatticeScatterIndividual() const { return _dsgnScatterIndividual; }
unsigned short inline GetNLatticeScatterIndividual() { return _nDsgnScatterIndividual; }
// Hohlraum
unsigned inline GetNumProbingCellsLineHohlraum() { return _nProbingCellsLineGreenHohlraum; }

// Optimizer
double inline GetNewtonOptimizerEpsilon() const { return _optimizerEpsilon; }
Expand Down
3 changes: 2 additions & 1 deletion include/problems/symmetrichohlraum.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ class SymmetricHohlraum : public ProblemBase
double _varAbsorptionHohlraumGreen; /*!< @brief Absorption of particles at Hohlraum green center cells integrated at current time step */
std::vector<unsigned> _probingCells; /*!< @brief Indices of cells that contain a probing sensor */
VectorVector _probingMoments; /*!< @brief Solution Momnets at the probing cells that contain a probing sensor */
VectorVector _probingCellsLineGreen; /*!< @brief Indices of cells that contain a probing sensor for the sliding window */
unsigned _nProbingCellsLineGreen; /*!< @brief Number of sampling cells that contain a probing sensor for the sliding window */
std::vector<unsigned> _probingCellsLineGreen; /*!< @brief Indices of cells that contain a probing sensor for the sliding window */

public:
SymmetricHohlraum( Config* settings, Mesh* mesh, QuadratureBase* quad );
Expand Down
3 changes: 3 additions & 0 deletions src/common/config.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -291,6 +291,9 @@ void Config::SetConfigOptions() {
* lower right (row major). \n DEFAULT \ingroup Config */
AddDoubleListOption( "LATTICE_DSGN_SCATTER_INDIVIDUAL", _nDsgnScatterIndividual, _dsgnScatterIndividual );

// Hohlraum related options
AddUnsignedShortOption( "N_SAMPLING_PTS_LINE_GREEN", _nProbingCellsLineGreenHohlraum, 20 );

// Entropy related options
/*! @brief Entropy Functional \n DESCRIPTION: Entropy functional used for the MN_Solver \n DEFAULT QUADRTATIC @ingroup Config. */
AddEnumOption( "ENTROPY_FUNCTIONAL", _entropyName, Entropy_Map, QUADRATIC );
Expand Down
6 changes: 4 additions & 2 deletions src/problems/symmetrichohlraum.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,11 @@ SymmetricHohlraum::SymmetricHohlraum( Config* settings, Mesh* mesh, QuadratureBa
_mesh->GetCellOfKoordinate( 0., -0.6 ),
_mesh->GetCellOfKoordinate( 0., 0.6 ),
};
_probingMoments = VectorVector( 4, Vector( 3, 0.0 ) );
_probingMoments = VectorVector( 4, Vector( 3, 0.0 ) );
_nProbingCellsLineGreen = _settings->GetNumProbingCellsLineHohlraum();
_probingCellsLineGreen = VectorVector( 4, Vector( 3, 0.0 ) );
#pragma omp parallel for
for( unsigned idx_cell = 0; idx_cell < _mesh->GetNumCells(); idx_cell++ ) {
for( unsigned idx_cell = 0; idx_cell < _mesh->GetNumCells(); idx_cell++ ) {
// Assumption: Domain size is 1.3x1.3
double x = _mesh->GetCellMidPoints()[idx_cell][0];
double y = _mesh->GetCellMidPoints()[idx_cell][1];
Expand Down

0 comments on commit 0ef1627

Please sign in to comment.