MURE
Loading...
Searching...
No Matches
SerpentTally.hxx
Go to the documentation of this file.
1/*
2 This file is part of MURE,
3 Copyright (C) 2007-2021 MURE developers.
4
5 MURE is free software: you can redistribute it and/or modify
6 it under the terms of the GNU Lesser General Public License as published by
7 the Free Software Foundation, either version 3 of the License, or
8 (at your option) any later version.
9
10 MURE is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU Lesser General Public License for more details.
14
15 You should have received a copy of the GNU Lesser General Public License
16 along with MURE. If not, see <http://www.gnu.org/licenses/>.
17*/
18
19#ifndef _TALLY_HXX_
20#define _TALLY_HXX_
21
27#include <vector>
28#include <iosfwd>
29#include <string>
30
31using namespace std;
32
33#include "MureTally.hxx"
34#include "Shape.hxx"
35#include "Reaction.hxx"
36#include "Cell.hxx"
37#include "MureTallyBin.hxx"
38#include "MureSimpleBin.hxx"
39#include "MureLatticeBin.hxx"
40#include "MureGroupBin.hxx"
42#include "MCSource.hxx"
43
44class Cell;
45class PinCell;
46
47namespace Serpent
48{
49
51
60{
61 public:
62 SimpleBin(const SimpleBin &b);
63 SimpleBin(Cell *C);
64 SimpleBin(PinCell *C, int layeridx): MureSimpleBin(C, layeridx) {}
66 SimpleBin(int universe);
67 SimpleBin();
68 SimpleBin *Clone() override
69 {
70 return new SimpleBin(*this);
71 }
72 string Print(int BeforeRparenthesis) override;
73};
74
75
77
94class Tally: public MureTally
95{
96 public:
109 Tally(int type = kCellFlux, const char *particle = "N");
119 Tally(int type, int particle);
120 Tally(const Tally &t);
121 Tally *Clone() override
122 {
123 return new Tally(*this);
124 }
125 ~Tally() override = default;
126
133 void AddFluenceToDoseConversion(bool ELinear = false, bool CFLinear = false);
134
135 string Print() override;
136 string PrintMultiplicator() override;
137
138
139 vector < double > GetBinVolume(int i) override;
140 double GetBinSurface(int i);
141 void SetBinSurface(int i, double S);
142 void SetBinVolume(int i, double V, int k = 0) override;
143
144 string GetParticle()
145 {
146 return fParticle;
147 }
149 {
150 fParticle = "N";
151 }
153 {
154 fParticle = "N, P";
155 }
157 {
158 fParticle = "N, E";
159 }
161 {
162 fParticle = "N, P, E";
163 }
164 void SetParentheses(bool flag = true)
165 {
166 fParentheses = flag;
167 }
168
169 protected:
171
172 private:
173 static const string NAME_PREFIX;
174 string fParticle;
177 vector < double > fEnergy;
178
179};
180
181
182}
183
184#endif
Header file for Cell class.
Header file for Monte-Carlo Source abstract class.
Header file for MureGroupBin class.
Header file for MureLatticeBin class.
Header file for MureSimpleBin class.
Header file for MureTallyBin abstract class.
@ kCellFlux
Definition MureTallyBin.hxx:41
Header file for TallyMultiplicator and MureTally classes.
Header file for Serpent::TimeEnergyGrid class.
Header file for Shape class and Shape_ptr type.
A Cell is composed from a Shape and a Material.
Definition Cell.hxx:84
Define group cell or surface bin.
Definition MureGroupBin.hxx:58
Define Lattice Cell type bin.
Definition MureLatticeBin.hxx:58
Define a general Simple Tally Bin (cell, universe or surface).
Definition MureSimpleBin.hxx:69
Define a MURE Tally.abstract class.
Definition MureTally.hxx:141
PinCell class allows to create cylindrical cell set included as Matrioshka.
Definition PinCell.hxx:53
Define a Serpent Tally simple bin.
Definition SerpentTally.hxx:60
SimpleBin * Clone() override
The "Virtual Copy Constructor".
Definition SerpentTally.hxx:68
string Print(int BeforeRparenthesis) override
Print the Simple Bin (dummy)
Definition SerpentTally.cxx:70
SimpleBin()
Definition SerpentTally.cxx:64
SimpleBin(const SimpleBin &b)
Copy constructor.
SimpleBin(PinCell *C, int layeridx)
Definition SerpentTally.hxx:64
Define a Serpent Tally simple bin.
Definition SerpentTally.hxx:95
string PrintMultiplicator() override
Print the Tally Multiplicator in Serpent.
Definition SerpentTally.cxx:222
vector< double > fEnergy
Energy bin vector.
Definition SerpentTally.hxx:177
vector< double > GetBinVolume(int i) override
returns the ith bin volume of Tally bin
Definition SerpentTally.cxx:242
void SetParticleNPE()
Definition SerpentTally.hxx:160
~Tally() override=default
Destructor.
void SetBinVolume(int i, double V, int k=0) override
set the ith bin volume of (the kth partial bin in a LatticeBin) Tally bin
Definition SerpentTally.cxx:266
string Print() override
Print the Tally in Serpent.
Definition SerpentTally.cxx:170
string GetParticle()
Definition SerpentTally.hxx:144
void AddFluenceToDoseConversion(bool ELinear=false, bool CFLinear=false)
Definition SerpentTally.cxx:288
MureLatticeBin LatticeBin
not implemented in MURE
Definition SerpentTally.hxx:98
bool fETBinForAllTallies
true Energy/time binning for all tallies (E0 or T0 in Serpent)
Definition SerpentTally.hxx:176
void SetParticleNP()
Definition SerpentTally.hxx:152
void SetParentheses(bool flag=true)
Definition SerpentTally.hxx:164
double GetBinSurface(int i)
returns the ith bin surface of Tally bin
Definition SerpentTally.cxx:255
Tally * Clone() override
The only good way to call copy constructor.
Definition SerpentTally.hxx:121
static const string NAME_PREFIX
a string before the tally number for the tally name; e.g. "d"=> "d1"
Definition SerpentTally.hxx:173
void SetBinSurface(int i, double S)
set the ith bin surface of Tally bin
Definition SerpentTally.cxx:282
MureGroupBin GroupBin
not implemented in Serpent
Definition SerpentTally.hxx:97
bool fParentheses
Enclose bins in parentheses.
Definition SerpentTally.hxx:175
void SetParticleN()
Definition SerpentTally.hxx:148
void SetParticleNE()
Definition SerpentTally.hxx:156
TimeEnergyGrid * GetNewTimeEnergyGrid() override
return a Time &Energy grid
Definition SerpentTally.cxx:294
string fParticle
Particle Type (N, P, ..)
Definition SerpentTally.hxx:174
Define a Time and/or Energy Grid for tallies.
Definition SerpentTimeEnergyGrid.hxx:46
the namespace use to couple MURE and Serpent
the namespace of the Standard C++

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