PRISMS-PF Manual
Loading...
Searching...
No Matches
MiscellaneousParameters Struct Reference

Struct that holds miscellaneous parameters. More...

#include <miscellaneous_parameters.h>

Inheritance diagram for MiscellaneousParameters:
[legend]
Collaboration diagram for MiscellaneousParameters:
[legend]

Public Member Functions

void assign (dealii::ParameterHandler &parameter_handler, unsigned int n_subsections=Numbers::default_subsections) override
 Assign the parameters from file.
 
void validate (const std::vector< FieldAttributes > &field_attributes, const std::vector< SolveBlock > &solve_blocks) const override
 Validate.
 
void set_random_seed (const unsigned int &_random_seed)
 Set the random seed and initialize the RNG.
 
- Public Member Functions inherited from ParameterBase
 ParameterBase ()=default
 
virtual ~ParameterBase ()=default
 
 ParameterBase (const ParameterBase &)=default
 
 ParameterBase (ParameterBase &&)=default
 
ParameterBaseoperator= (const ParameterBase &)=default
 
ParameterBaseoperator= (ParameterBase &&)=default
 

Static Public Member Functions

static void declare (dealii::ParameterHandler &parameter_handler, unsigned int n_subsections=Numbers::default_subsections)
 Declare the parameters to be read from file.
 

Public Attributes

unsigned int random_seed = 2025
 
RNGEngine rng {random_seed}
 

Detailed Description

Struct that holds miscellaneous parameters.

Member Function Documentation

◆ assign()

void MiscellaneousParameters::assign ( dealii::ParameterHandler & parameter_handler,
unsigned int n_subsections = Numbers::default_subsections )
overridevirtual

Assign the parameters from file.

Implements ParameterBase.

◆ declare()

PRISMS_PF_BEGIN_NAMESPACE void MiscellaneousParameters::declare ( dealii::ParameterHandler & parameter_handler,
unsigned int n_subsections = Numbers::default_subsections )
static

Declare the parameters to be read from file.

◆ set_random_seed()

void MiscellaneousParameters::set_random_seed ( const unsigned int & _random_seed)

Set the random seed and initialize the RNG.

NOTE: When using this method to set the RNG, the MPI process number is added to the random seed to avoid correlated events between processors. This means that to reproduce the same results as someone else you need both the number of MPI processes and the random seed.

If you would like to change the default behavior you can override the rng manually.

◆ validate()

void MiscellaneousParameters::validate ( const std::vector< FieldAttributes > & field_attributes,
const std::vector< SolveBlock > & solve_blocks ) const
overridevirtual

Validate.

Implements ParameterBase.

Member Data Documentation

◆ random_seed

unsigned int MiscellaneousParameters::random_seed = 2025

◆ rng

RNGEngine MiscellaneousParameters::rng {random_seed}
mutable

The documentation for this struct was generated from the following files: