MURE
Loading...
Searching...
No Matches
Public Member Functions | List of all members
EvolutionControl Class Reference

EvolutionControl allows interactions with the evolution. More...

#include <EvolutionControl.hxx>

Inheritance diagram for EvolutionControl:
EvolutionWrapper FissileEvolutionControl HNEvolutionControl InLineReprocessing PoisonEvolutionControl RodEvolutionControl

Public Member Functions

 EvolutionControl ()
 Default Constructor.
 
 EvolutionControl (const EvolutionControl &ev)
 Copy constructor.
 
virtual EvolutionControlClone ()
 
virtual ~EvolutionControl ()
 destructor
 
Methods directly called by MURE to interact with evolution
virtual void ControlBeforeFirstMCRun ()
 
virtual void ControlAfterRestart (int RestartRun)
 control at the very beginning of the evolution, before any MC run
 
virtual void ControlAfterEachMCRun ()
 when restart from existing (B)DATA files, call this method just after reading files
 
virtual void ControlBeforeEachSubStep ()
 Control just before each sub-step in an Evolution Step.
 
virtual void ControlAfterEachEvolutionStep ()
 Control after the last CRAM/RK sub-step of an Evolution Step.
 
virtual void ControlAfterLastMCRun ()
 
void SetMCRunTime (vector< double > T)
 Control at the end of evolution, after the last Evolution Step (or MC run if evolution end on a MC run)
 
vector< double > & GetMCRunTimes ()
 
Evolution Condition methods
void SetWantedKeff (double keff=1.)
 
void SetWantedHNProportion (double HNproportion=0.01)
 
double GetWantedHNProportion ()
 
void SetLockToInitialKeff (bool flag=true)
 
void SetConstantPower (bool flag=true)
 
bool IsConstantPower ()
 
void SetFuelReprocessing (FuelReprocessing *processing)
 
FuelReprocessingGetFuelReprocessing ()
 
Safety related methods
virtual void CalculateCoeffsAtStep (int s)
 Abstract method ; to be overloaded.
 
virtual void SetRunFuelTemperatureCoeff (bool flag=true)
 Abstract method ; to be overloaded.
 
virtual void SetRunVoidCoeff (bool flag=true)
 Abstract method ; to be overloaded.
 
virtual void SetRunModeratorTemperatureCoeff (bool flag=true)
 Abstract method ; to be overloaded.
 
virtual void SetRunPoisonReactivityWorth (bool flag=true)
 Abstract method ; to be overloaded.
 
virtual void SetCriticalitySource (MCSource *s)
 Abstract method ; to be overloaded.
 
virtual void LaunchReactivityCoeffsCalculations ()
 Abstract method ; to be overloaded.
 
virtual void ControlKeff (double Time)
 Abstract method ; to be overloaded.
 
void RunMCCriticality (string FileName)
 Run MC only for a Kcode (no tally)
 
Reaction rates and keff estimation methods
virtual double EstimatedKeff ()
 Extrapolation of Keff on the next step from a linear fit.
 
virtual void FindKeffSlope ()
 Find the slope of Keff base on previous run (fit)
 
virtual void FindAbsorptionSlope ()
 Find the slope of Aborption base on previous run (fit)
 
virtual void FindFissionSlope ()
 Find the slope of Fission base on previous run (fit)
 
virtual void FindNuFissionSlope ()
 Find the slope of Fission*nu base on previous run (fit)
 
virtual void ExtrapolateRates ()
 Extrapolation of reaction rates on the next step from a linear fit.
 

Miscellaneous methods

vector< double > fMCRunTimes
 Time at which MC run is performed.
 
bool fConstantPower
 whether or not keep a constant power
 
double fWantedKeff
 The wanted Keff of the problem.
 
double fWantedHNProportion
 The wanted heavy nuclide proportion.
 
vector< double > fMCTime
 vector of last MC run time (for fits)
 
vector< double > fMCKeff
 vector of last MC run Keff
 
vector< double > fMCDeltaKeff
 vector of last MC run Keff error
 
double fOldKeff
 The previous MC keff result.
 
bool fLockToInitialKeff
 for keff control.
 
vector< double > fKeffWarningTime
 Times at which estimate keff differs from MC keff at 3sigma.
 
vector< double > fKeffWarningGap
 |Estimate keff - Mcnp Keff|
 
vector< double > fKeffWarning3sigma
 3sigma on MC keff
 
vector< int > fKeffWarningMCNum
 The MC run number of the warning.
 
double fFitKeffSlope
 slope to find the Keff extrapolation
 
double fFitKeffIntersept
 intersept to find the Keff extrapolation
 
vector< double > fMCAbs
 vector of last MC run's global total absorption rate.
 
vector< double > fMCDeltaAbs
 vector of last MC run global Absorption rate (-2) error
 
double fFitAbsSlope
 slope to find extrapolated Absorption value.
 
double fFitAbsIntercept
 Absorption intercept for the extrapolation.
 
vector< double > fMCFiss
 vector of last MC run's global fission rate.
 
vector< double > fMCDeltaFiss
 vector of last MC run's global fission rate error.
 
double fFitFissSlope
 slope of linear fit of the fission rate.
 
double fFitFissIntercept
 intersept of linear fit of the fission rate.
 
vector< double > fMCNuFiss
 vector of last MC run's global nu*fission rate.
 
vector< double > fMCDeltaNuFiss
 vector of last MC run's global nu*fission rate error
 
double fFitNuFissSlope
 slope of linear fit of the nu*fission rate.
 
double fFitNuFissIntercept
 intersept of linear fit of the nu*fission rate.
 
double fSumOfFission
 sum of all (n, fission) reaction in a cell
 
double fSumOfCapture
 sum of all (n, gamma) reaction in a cell
 
double fSumOfN2N
 sum of all (n, 2n) reaction in a cell
 
double fTNF
 the Tally normalization Factor
 
FuelReprocessingfFuelReprocessing
 the FuelReprocessing
 
virtual void WriteControlParameters ()
 Write poison/fissile proportions etc.
 
virtual void WriteCurrentRates ()
 Write absorpstion, fission, ... rates in ABS, FISS, ... files.
 
void PrintKeffWarning ()
 Print Keff estimation warnings.
 
void FindNextCoefs (double value, vector< double > &V, double &Slope, double &Intersept, int &LastMCRunNumber)
 Fit a vector and return the fitted parameters.
 
virtual void InitVector ()
 build vector used in fits full of 0.
 

Detailed Description

EvolutionControl allows interactions with the evolution.

A list of usefull methods are provided to control evolution. The control only acts through the 2 main methods EvolutionControl::ControlAfterEachMCRun() and EvolutionControl::ControlBeforeEachSubStep().

To implement your own evolution control, you have to make your onw class with inheritance mechanism in which YOU ABSOLUTELY NEED TO DEFINE THE EvolutionControl *Clone() method!!!

See also
User Guide
Author
PTO
Version
1.0

Constructor & Destructor Documentation

◆ EvolutionControl() [1/2]

EvolutionControl::EvolutionControl ( )

Default Constructor.

By default the tally normalization factor is <0. This mean that the power will be used to normalized tallies. The Constant power is assumed and the wanted Keff is set to 1.

◆ EvolutionControl() [2/2]

EvolutionControl::EvolutionControl ( const EvolutionControl ev)

Copy constructor.

◆ ~EvolutionControl()

EvolutionControl::~EvolutionControl ( )
virtual

destructor

Member Function Documentation

◆ CalculateCoeffsAtStep()

virtual void EvolutionControl::CalculateCoeffsAtStep ( int  s)
inlinevirtual

Abstract method ; to be overloaded.

◆ Clone()

virtual EvolutionControl * EvolutionControl::Clone ( )
inlinevirtual

◆ ControlAfterEachEvolutionStep()

void EvolutionControl::ControlAfterEachEvolutionStep ( )
virtual

Control after the last CRAM/RK sub-step of an Evolution Step.

This method is called just before the next MC run after the end of an Evolution Step. In this method, a FuelReprocessing::CoreRefuel is performed if a NOT continuous fuel reprocessing has been been set. Just before this, (B)DATA_b files are writen in order to see the impact of the core refuel.

Reimplemented in EvolutionWrapper, FissileEvolutionControl, HNEvolutionControl, InLineReprocessing, and RodEvolutionControl.

◆ ControlAfterEachMCRun()

void EvolutionControl::ControlAfterEachMCRun ( )
virtual

when restart from existing (B)DATA files, call this method just after reading files

Control just after each MC run.

In this method, the Tally Normalization Factor is upated if the power is kept constant, Keff data are writen to files (for post-treatment), current "r" file from MCNP is removed (only for MCNP run) if this has been set to the (MCNP) ConnectorPlugin.

Reimplemented in EvolutionWrapper, FissileEvolutionControl, InLineReprocessing, PoisonEvolutionControl, and RodEvolutionControl.

◆ ControlAfterLastMCRun()

virtual void EvolutionControl::ControlAfterLastMCRun ( )
inlinevirtual

◆ ControlAfterRestart()

virtual void EvolutionControl::ControlAfterRestart ( int  RestartRun)
inlinevirtual

control at the very beginning of the evolution, before any MC run

◆ ControlBeforeEachSubStep()

void EvolutionControl::ControlBeforeEachSubStep ( )
virtual

Control just before each sub-step in an Evolution Step.

In this method, the Tally Normalization Factor is upated if the power is kept constant, a Fit of TallyNormallizationFactor is done if this has been set in EvolutionSlover and a FuelReprocessing::CoreRefuel is performed if a continuous fuel reprocessing has been been set.

Reimplemented in EvolutionWrapper, InLineReprocessing, PoisonEvolutionControl, and RodEvolutionControl.

◆ ControlBeforeFirstMCRun()

virtual void EvolutionControl::ControlBeforeFirstMCRun ( )
inlinevirtual

◆ ControlKeff()

virtual void EvolutionControl::ControlKeff ( double  Time)
inlinevirtual

Abstract method ; to be overloaded.

◆ EstimatedKeff()

double EvolutionControl::EstimatedKeff ( )
virtual

Extrapolation of Keff on the next step from a linear fit.

◆ ExtrapolateRates()

void EvolutionControl::ExtrapolateRates ( )
virtual

Extrapolation of reaction rates on the next step from a linear fit.

Reimplemented in FissileEvolutionControl, and PoisonEvolutionControl.

◆ FindAbsorptionSlope()

void EvolutionControl::FindAbsorptionSlope ( )
virtual

Find the slope of Aborption base on previous run (fit)

◆ FindFissionSlope()

void EvolutionControl::FindFissionSlope ( )
virtual

Find the slope of Fission base on previous run (fit)

◆ FindKeffSlope()

void EvolutionControl::FindKeffSlope ( )
virtual

Find the slope of Keff base on previous run (fit)

◆ FindNextCoefs()

void EvolutionControl::FindNextCoefs ( double  value,
vector< double > &  V,
double &  Slope,
double &  Intersept,
int &  LastMCRunNumber 
)

Fit a vector and return the fitted parameters.

The value (at time T) is added to the vector V and a time linear fit is performed to find the slope and intersept

Parameters
value: the value added to the vector V to fit
V: the vector to fit
Slope: output only: the slope of the linear fit
Intersept: output only: the intersept of the linear fit.
LastMCRunNumber: value of the last MC number to avoid to used 2 time the same value in case of multi call

◆ FindNuFissionSlope()

void EvolutionControl::FindNuFissionSlope ( )
virtual

Find the slope of Fission*nu base on previous run (fit)

◆ GetFuelReprocessing()

FuelReprocessing * EvolutionControl::GetFuelReprocessing ( )
inline

< get the FuelReprocessing

◆ GetMCRunTimes()

vector< double > & EvolutionControl::GetMCRunTimes ( )
inline

< returns Time at which MC run is performed

◆ GetWantedHNProportion()

double EvolutionControl::GetWantedHNProportion ( )
inline

< return the wanted Heavy Nucleus proportion

◆ InitVector()

void EvolutionControl::InitVector ( )
protectedvirtual

build vector used in fits full of 0.

Reimplemented in PoisonEvolutionControl, and RodEvolutionControl.

◆ IsConstantPower()

bool EvolutionControl::IsConstantPower ( )
inline

< return whether the power is kept constant or not

◆ LaunchReactivityCoeffsCalculations()

virtual void EvolutionControl::LaunchReactivityCoeffsCalculations ( )
inlinevirtual

Abstract method ; to be overloaded.

◆ PrintKeffWarning()

void EvolutionControl::PrintKeffWarning ( )

Print Keff estimation warnings.

If abs(MC Keff - Estimated Keff)>3*MC_Keff_sigma) the time, the MC run number, the difference and the 3 sigma are printed.

◆ RunMCCriticality()

void EvolutionControl::RunMCCriticality ( string  FileName)

Run MC only for a Kcode (no tally)

◆ SetConstantPower()

void EvolutionControl::SetConstantPower ( bool  flag = true)
inline

< say whether the power is kept constant or not

◆ SetCriticalitySource()

virtual void EvolutionControl::SetCriticalitySource ( MCSource s)
inlinevirtual

Abstract method ; to be overloaded.

◆ SetFuelReprocessing()

void EvolutionControl::SetFuelReprocessing ( FuelReprocessing processing)
inline

< add the FuelReprocessing

◆ SetLockToInitialKeff()

void EvolutionControl::SetLockToInitialKeff ( bool  flag = true)
inline

< set keff control to keep keff at its initial value. (tang)

◆ SetMCRunTime()

void EvolutionControl::SetMCRunTime ( vector< double >  T)

Control at the end of evolution, after the last Evolution Step (or MC run if evolution end on a MC run)

Set Time at which MC run is performed

◆ SetRunFuelTemperatureCoeff()

virtual void EvolutionControl::SetRunFuelTemperatureCoeff ( bool  flag = true)
inlinevirtual

Abstract method ; to be overloaded.

◆ SetRunModeratorTemperatureCoeff()

virtual void EvolutionControl::SetRunModeratorTemperatureCoeff ( bool  flag = true)
inlinevirtual

Abstract method ; to be overloaded.

◆ SetRunPoisonReactivityWorth()

virtual void EvolutionControl::SetRunPoisonReactivityWorth ( bool  flag = true)
inlinevirtual

Abstract method ; to be overloaded.

◆ SetRunVoidCoeff()

virtual void EvolutionControl::SetRunVoidCoeff ( bool  flag = true)
inlinevirtual

Abstract method ; to be overloaded.

◆ SetWantedHNProportion()

void EvolutionControl::SetWantedHNProportion ( double  HNproportion = 0.01)
inline

< set the wanted Heavy Nucleus proportion

◆ SetWantedKeff()

void EvolutionControl::SetWantedKeff ( double  keff = 1.)
inline

< set the wanted keff value

◆ WriteControlParameters()

virtual void EvolutionControl::WriteControlParameters ( )
inlinevirtual

Write poison/fissile proportions etc.

Reimplemented in FissileEvolutionControl, and PoisonEvolutionControl.

◆ WriteCurrentRates()

void EvolutionControl::WriteCurrentRates ( )
virtual

Write absorpstion, fission, ... rates in ABS, FISS, ... files.

Reimplemented in PoisonEvolutionControl.

Member Data Documentation

◆ fConstantPower

bool EvolutionControl::fConstantPower
protected

whether or not keep a constant power

◆ fFitAbsIntercept

double EvolutionControl::fFitAbsIntercept
protected

Absorption intercept for the extrapolation.

◆ fFitAbsSlope

double EvolutionControl::fFitAbsSlope
protected

slope to find extrapolated Absorption value.

◆ fFitFissIntercept

double EvolutionControl::fFitFissIntercept
protected

intersept of linear fit of the fission rate.

◆ fFitFissSlope

double EvolutionControl::fFitFissSlope
protected

slope of linear fit of the fission rate.

◆ fFitKeffIntersept

double EvolutionControl::fFitKeffIntersept
protected

intersept to find the Keff extrapolation

◆ fFitKeffSlope

double EvolutionControl::fFitKeffSlope
protected

slope to find the Keff extrapolation

◆ fFitNuFissIntercept

double EvolutionControl::fFitNuFissIntercept
protected

intersept of linear fit of the nu*fission rate.

◆ fFitNuFissSlope

double EvolutionControl::fFitNuFissSlope
protected

slope of linear fit of the nu*fission rate.

◆ fFuelReprocessing

FuelReprocessing* EvolutionControl::fFuelReprocessing
protected

◆ fKeffWarning3sigma

vector< double > EvolutionControl::fKeffWarning3sigma
protected

3sigma on MC keff

◆ fKeffWarningGap

vector< double > EvolutionControl::fKeffWarningGap
protected

|Estimate keff - Mcnp Keff|

◆ fKeffWarningMCNum

vector< int > EvolutionControl::fKeffWarningMCNum
protected

The MC run number of the warning.

◆ fKeffWarningTime

vector< double > EvolutionControl::fKeffWarningTime
protected

Times at which estimate keff differs from MC keff at 3sigma.

◆ fLockToInitialKeff

bool EvolutionControl::fLockToInitialKeff
protected

for keff control.

◆ fMCAbs

vector< double > EvolutionControl::fMCAbs
protected

vector of last MC run's global total absorption rate.

◆ fMCDeltaAbs

vector< double > EvolutionControl::fMCDeltaAbs
protected

vector of last MC run global Absorption rate (-2) error

◆ fMCDeltaFiss

vector< double > EvolutionControl::fMCDeltaFiss
protected

vector of last MC run's global fission rate error.

◆ fMCDeltaKeff

vector< double > EvolutionControl::fMCDeltaKeff
protected

vector of last MC run Keff error

◆ fMCDeltaNuFiss

vector< double > EvolutionControl::fMCDeltaNuFiss
protected

vector of last MC run's global nu*fission rate error

◆ fMCFiss

vector< double > EvolutionControl::fMCFiss
protected

vector of last MC run's global fission rate.

◆ fMCKeff

vector< double > EvolutionControl::fMCKeff
protected

vector of last MC run Keff

◆ fMCNuFiss

vector< double > EvolutionControl::fMCNuFiss
protected

vector of last MC run's global nu*fission rate.

◆ fMCRunTimes

vector< double > EvolutionControl::fMCRunTimes
protected

Time at which MC run is performed.

◆ fMCTime

vector< double > EvolutionControl::fMCTime
protected

vector of last MC run time (for fits)

◆ fOldKeff

double EvolutionControl::fOldKeff
protected

The previous MC keff result.

◆ fSumOfCapture

double EvolutionControl::fSumOfCapture
protected

sum of all (n, gamma) reaction in a cell

◆ fSumOfFission

double EvolutionControl::fSumOfFission
protected

sum of all (n, fission) reaction in a cell

◆ fSumOfN2N

double EvolutionControl::fSumOfN2N
protected

sum of all (n, 2n) reaction in a cell

◆ fTNF

double EvolutionControl::fTNF
protected

the Tally normalization Factor

◆ fWantedHNProportion

double EvolutionControl::fWantedHNProportion
protected

The wanted heavy nuclide proportion.

◆ fWantedKeff

double EvolutionControl::fWantedKeff
protected

The wanted Keff of the problem.


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

MURE Project, documentation generated by Doxygen 1.9.7 - Fri Jan 19 2024