Line data Source code
1 : /********************************************************************/ 2 : /* SOFTWARE COPYRIGHT NOTIFICATION */ 3 : /* Cardinal */ 4 : /* */ 5 : /* (c) 2021 UChicago Argonne, LLC */ 6 : /* ALL RIGHTS RESERVED */ 7 : /* */ 8 : /* Prepared by UChicago Argonne, LLC */ 9 : /* Under Contract No. DE-AC02-06CH11357 */ 10 : /* With the U. S. Department of Energy */ 11 : /* */ 12 : /* Prepared by Battelle Energy Alliance, LLC */ 13 : /* Under Contract No. DE-AC07-05ID14517 */ 14 : /* With the U. S. Department of Energy */ 15 : /* */ 16 : /* See LICENSE for full restrictions */ 17 : /********************************************************************/ 18 : 19 : #pragma once 20 : 21 : #include "GeneralPostprocessor.h" 22 : 23 : #include "OpenMCBase.h" 24 : #include "CardinalEnums.h" 25 : 26 : /** 27 : * Get the k-effective eigenvalue computed by OpenMC. 28 : */ 29 : class KEigenvalue : public GeneralPostprocessor, public OpenMCBase 30 : { 31 : public: 32 : static InputParameters validParams(); 33 : 34 : KEigenvalue(const InputParameters & parameters); 35 : 36 562 : virtual void initialize() override {} 37 562 : virtual void execute() override {} 38 : 39 : virtual Real getValue() const override; 40 : 41 : protected: 42 : /** 43 : * A function which computes the mean value of k_{eff}. 44 : * @return the mean value of the k-eigenvalue 45 : */ 46 : Real kMean() const; 47 : 48 : /** 49 : * A function which computes the standard deviation of k_{eff}. 50 : * @return the standard deviation of the k-eigenvalue 51 : */ 52 : Real KStandardDeviation() const; 53 : 54 : /** 55 : * A function which computes the relative error of k_{eff}. 56 : * @return the relative error of the k-eigenvalue 57 : */ 58 : Real kRelativeError() const; 59 : 60 : /** 61 : * Type of k-effective value to report. Options: 62 : * collision, absorption, tracklength, and combined (default). 63 : * 64 : * The combined k-effective estimate is a minimum variance estimate 65 : * of k-effective based on a linear combination of the collision, absorption, 66 : * and tracklength estimates. 67 : */ 68 : const eigenvalue::EigenvalueEnum _type; 69 : 70 : /// The value of the kinetics parameter to output. 71 : const statistics::OutputEnum _output; 72 : };