MURE
Loading...
Searching...
No Matches
MureLatticeBin.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 _MURELATTICEBIN_HXX_
20#define _MURELATTICEBIN_HXX_
21
27#include <vector>
28#include <algorithm>
29#include <iosfwd>
30#include <string>
31
32using namespace std;
33
34#include "MureTallyBin.hxx"
35#include "Shape.hxx"
36#include "Reaction.hxx"
37#include "Cell.hxx"
38
39class Cell;
40class PinCell;
41
43
58{
59 public:
61 MureLatticeBin(Cell *C, string pos = "");
62 MureLatticeBin(PinCell *C, int layeridx, string pos = "");
63 MureLatticeBin(MureTallyBin *theTallyBin);
64 MureLatticeBin(int universe);
65 ~MureLatticeBin() override;
66 MureTallyBin *Clone() override
67 {
68 return new MureLatticeBin(*this);
69 }
70
71 bool IsLatticeBin() override
72 {
73 return 1;
74 }
75
84 void Add(Cell *C, int InclusionLevel = 0, string pos = "");
85
94 void Add(PinCell *C, int layeridx, int InclusionLevel, string pos = "");
95
103 void Add(MureTallyBin *theTallyBin, int InclusionLevel = 0);
104
105 void Add(int universe, int InclusionLevel = 0);
106
107 void AddContainer(Cell *C, string pos = "");
108 void AddContainer(MureTallyBin *theTallyBin);
109 void AddContainer(int universe);
110
111 string Print(int BeforeRparenthesis = 0) override;
112 string PrintVolume() override;
113 bool IsInBin(int num) override;
114 bool IsInBin(Cell *C) override;
115
116 vector < vector < MureTallyBin *> > GetLevelVector()
117 {
118 return fLevel;
119 }
120
121 void UpdateTallyBinVolume() override;
122
123 protected:
124 vector < vector < MureTallyBin *> > fLevel;
125 vector < vector < bool > > fHasPosition;
126 vector < vector < string > > fPosition;
127};
128
129
130
131
132#endif
Header file for Cell class.
Header file for MureTallyBin abstract 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 Lattice Cell type bin.
Definition MureLatticeBin.hxx:58
void AddContainer(Cell *C, string pos="")
Add a Cell in a new outer level.
Definition MureLatticeBin.cxx:289
vector< vector< MureTallyBin * > > fLevel
array of array of MureTallyBin.
Definition MureLatticeBin.hxx:124
string Print(int BeforeRparenthesis=0) override
Print the MureLatticeBin in MCNP.
Definition MureLatticeBin.cxx:307
void UpdateTallyBinVolume() override
Reread all bins and assign necessary volume.
Definition MureLatticeBin.cxx:315
bool IsLatticeBin() override
Definition MureLatticeBin.hxx:71
vector< vector< bool > > fHasPosition
flag to know if a given cell has restricted positions in a lattice
Definition MureLatticeBin.hxx:125
void Add(Cell *C, int InclusionLevel=0, string pos="")
Definition MureLatticeBin.cxx:190
string PrintVolume() override
Print the MureLatticeBin list of volume in MCNP.
Definition MureLatticeBin.cxx:320
MureTallyBin * Clone() override
The "Virtual Copy Constructor".
Definition MureLatticeBin.hxx:66
bool IsInBin(int num) override
whether or not the universe "num" is in the bin
Definition MureLatticeBin.cxx:348
~MureLatticeBin() override
Destructor.
Definition MureLatticeBin.cxx:161
vector< vector< MureTallyBin * > > GetLevelVector()
Definition MureLatticeBin.hxx:116
vector< vector< string > > fPosition
array of the positions of each cell in each level.
Definition MureLatticeBin.hxx:126
Define a general Tally Bin.
Definition MureTallyBin.hxx:62
PinCell class allows to create cylindrical cell set included as Matrioshka.
Definition PinCell.hxx:53
the namespace of the Standard C++

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