Geant4 Cross Reference

Cross-Referencing   Geant4
Geant4/examples/advanced/human_phantom/src/G4PhantomBuilder.cc

Version: [ ReleaseNotes ] [ 1.0 ] [ 1.1 ] [ 2.0 ] [ 3.0 ] [ 3.1 ] [ 3.2 ] [ 4.0 ] [ 4.0.p1 ] [ 4.0.p2 ] [ 4.1 ] [ 4.1.p1 ] [ 5.0 ] [ 5.0.p1 ] [ 5.1 ] [ 5.1.p1 ] [ 5.2 ] [ 5.2.p1 ] [ 5.2.p2 ] [ 6.0 ] [ 6.0.p1 ] [ 6.1 ] [ 6.2 ] [ 6.2.p1 ] [ 6.2.p2 ] [ 7.0 ] [ 7.0.p1 ] [ 7.1 ] [ 7.1.p1 ] [ 8.0 ] [ 8.0.p1 ] [ 8.1 ] [ 8.1.p1 ] [ 8.1.p2 ] [ 8.2 ] [ 8.2.p1 ] [ 8.3 ] [ 8.3.p1 ] [ 8.3.p2 ] [ 9.0 ] [ 9.0.p1 ] [ 9.0.p2 ] [ 9.1 ] [ 9.1.p1 ] [ 9.1.p2 ] [ 9.1.p3 ] [ 9.2 ] [ 9.2.p1 ] [ 9.2.p2 ] [ 9.2.p3 ] [ 9.2.p4 ] [ 9.3 ] [ 9.3.p1 ] [ 9.3.p2 ] [ 9.4 ] [ 9.4.p1 ] [ 9.4.p2 ] [ 9.4.p3 ] [ 9.4.p4 ] [ 9.5 ] [ 9.5.p1 ] [ 9.5.p2 ] [ 9.6 ] [ 9.6.p1 ] [ 9.6.p2 ] [ 9.6.p3 ] [ 9.6.p4 ] [ 10.0 ] [ 10.0.p1 ] [ 10.0.p2 ] [ 10.0.p3 ] [ 10.0.p4 ] [ 10.1 ] [ 10.1.p1 ] [ 10.1.p2 ] [ 10.1.p3 ] [ 10.2 ] [ 10.2.p1 ] [ 10.2.p2 ] [ 10.2.p3 ] [ 10.3 ] [ 10.3.p1 ] [ 10.3.p2 ] [ 10.3.p3 ] [ 10.4 ] [ 10.4.p1 ] [ 10.4.p2 ] [ 10.4.p3 ] [ 10.5 ] [ 10.5.p1 ] [ 10.6 ] [ 10.6.p1 ] [ 10.6.p2 ] [ 10.6.p3 ] [ 10.7 ] [ 10.7.p1 ] [ 10.7.p2 ] [ 10.7.p3 ] [ 10.7.p4 ] [ 11.0 ] [ 11.0.p1 ] [ 11.0.p2 ] [ 11.0.p3, ] [ 11.0.p4 ] [ 11.1 ] [ 11.1.1 ] [ 11.1.2 ] [ 11.1.3 ] [ 11.2 ] [ 11.2.1 ] [ 11.2.2 ] [ 11.3.0 ]

Diff markup

Differences between /examples/advanced/human_phantom/src/G4PhantomBuilder.cc (Version 11.3.0) and /examples/advanced/human_phantom/src/G4PhantomBuilder.cc (Version 10.0.p3)


  1 //                                                  1 //
  2 // *******************************************      2 // ********************************************************************
  3 // * License and Disclaimer                         3 // * License and Disclaimer                                           *
  4 // *                                                4 // *                                                                  *
  5 // * The  Geant4 software  is  copyright of th      5 // * The  Geant4 software  is  copyright of the Copyright Holders  of *
  6 // * the Geant4 Collaboration.  It is provided      6 // * the Geant4 Collaboration.  It is provided  under  the terms  and *
  7 // * conditions of the Geant4 Software License      7 // * conditions of the Geant4 Software License,  included in the file *
  8 // * LICENSE and available at  http://cern.ch/      8 // * LICENSE and available at  http://cern.ch/geant4/license .  These *
  9 // * include a list of copyright holders.           9 // * include a list of copyright holders.                             *
 10 // *                                               10 // *                                                                  *
 11 // * Neither the authors of this software syst     11 // * Neither the authors of this software system, nor their employing *
 12 // * institutes,nor the agencies providing fin     12 // * institutes,nor the agencies providing financial support for this *
 13 // * work  make  any representation or  warran     13 // * work  make  any representation or  warranty, express or implied, *
 14 // * regarding  this  software system or assum     14 // * regarding  this  software system or assume any liability for its *
 15 // * use.  Please see the license in the file      15 // * use.  Please see the license in the file  LICENSE  and URL above *
 16 // * for the full disclaimer and the limitatio     16 // * for the full disclaimer and the limitation of liability.         *
 17 // *                                               17 // *                                                                  *
 18 // * This  code  implementation is the result      18 // * This  code  implementation is the result of  the  scientific and *
 19 // * technical work of the GEANT4 collaboratio     19 // * technical work of the GEANT4 collaboration.                      *
 20 // * By using,  copying,  modifying or  distri     20 // * By using,  copying,  modifying or  distributing the software (or *
 21 // * any work based  on the software)  you  ag     21 // * any work based  on the software)  you  agree  to acknowledge its *
 22 // * use  in  resulting  scientific  publicati     22 // * use  in  resulting  scientific  publications,  and indicate your *
 23 // * acceptance of all terms of the Geant4 Sof     23 // * acceptance of all terms of the Geant4 Software license.          *
 24 // *******************************************     24 // ********************************************************************
 25 //                                                 25 //
 26 // Previous authors: G. Guerrieri, S. Guatelli <<  26 // Authors: S. Guatelli and M. G. Pia, INFN Genova and F. Ambroglini INFN Perugia, Italy
 27 // Authors (since 2007): S. Guatelli, Universi << 
 28 //                                                 27 // 
                                                   >>  28 // Based on code developed by the undergraduate student G. Guerrieri 
                                                   >>  29 // Note: this is a preliminary beta-version of the code; an improved 
                                                   >>  30 // version will be distributed in the next Geant4 public release, compliant
                                                   >>  31 // with the design in a forthcoming publication, and subject to a 
                                                   >>  32 // design and code review.
 29 //                                                 33 //
 30 #include "G4PhantomBuilder.hh"                     34 #include "G4PhantomBuilder.hh"
 31 #include "G4VBodyFactory.hh"                       35 #include "G4VBodyFactory.hh"
 32 #include "G4MIRDBodyFactory.hh"                    36 #include "G4MIRDBodyFactory.hh"
 33 #include "G4ORNLFemaleBodyFactory.hh"              37 #include "G4ORNLFemaleBodyFactory.hh"
 34 #include "G4ORNLMaleBodyFactory.hh"                38 #include "G4ORNLMaleBodyFactory.hh"
 35 #include "G4RunManager.hh"                         39 #include "G4RunManager.hh"
 36 #include "G4Element.hh"                            40 #include "G4Element.hh"
 37 #include "G4Material.hh"                           41 #include "G4Material.hh"
 38 #include "G4Box.hh"                                42 #include "G4Box.hh"
 39 #include "G4LogicalVolume.hh"                      43 #include "G4LogicalVolume.hh"
 40 #include "G4PVPlacement.hh"                        44 #include "G4PVPlacement.hh"
 41 #include "G4Colour.hh"                             45 #include "G4Colour.hh"
 42 #include "G4VisAttributes.hh"                      46 #include "G4VisAttributes.hh"
 43                                                    47 
 44 G4PhantomBuilder::G4PhantomBuilder(): fModel(" <<  48 G4PhantomBuilder::G4PhantomBuilder(): model("MIRD")
 45 {                                                  49 {  
 46   // sex can be "female" or "male"                 50   // sex can be "female" or "male"
 47   fBody = nullptr;                             <<  51   body = 0;
 48   fMotherVolume = nullptr;                     <<  52   motherVolume = 0;
 49   fHeadVolume = nullptr;                       <<  53   headVolume = 0;
 50   fTrunkVolume = nullptr;                      <<  54   trunkVolume = 0;
 51   fLeftLegVolume =nullptr;                     <<  55   leftLegVolume =0;
 52   fRightLegVolume = nullptr;                   <<  56   rightLegVolume =0;
 53   fMaleGenitaliaVolume = nullptr;              <<  57   maleGenitaliaVolume = 0;  
 54 }                                                  58 }
 55                                                    59 
                                                   >>  60 G4PhantomBuilder::~G4PhantomBuilder()
                                                   >>  61 {
                                                   >>  62 } 
 56 void G4PhantomBuilder::BuildTrunk(const G4Stri     63 void G4PhantomBuilder::BuildTrunk(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
 57 {                                                  64 { 
 58   if (fMotherVolume == nullptr)                <<  65   if (motherVolume == 0)
 59     G4Exception("G4PhantomBuilder::BuildTrunk(     66     G4Exception("G4PhantomBuilder::BuildTrunk()", "human_phantom0014", FatalException, "The world volume is missing !!!!!");
 60                                                    67   
 61   G4cout <<"MotherVolume: " <<  fMotherVolume  <<  68   G4cout <<"MotherVolume: " <<  motherVolume -> GetName()<< G4endl;
 62   G4cout << "sensitivity : "<< sensitivity <<      69   G4cout << "sensitivity : "<< sensitivity << G4endl; 
 63   fTrunkVolume = fBody -> CreateOrgan("Trunk", <<  70   trunkVolume = body -> CreateOrgan("Trunk", motherVolume, colourName, solidVis, sensitivity);
 64 }                                                  71 }
 65                                                    72 
 66 void G4PhantomBuilder::BuildLeftLeg(const G4St     73 void G4PhantomBuilder::BuildLeftLeg(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
 67 {                                                  74 { 
 68   if (fMotherVolume == nullptr)                <<  75   if (motherVolume == 0)
 69     G4Exception("G4PhantomBuilder::BuildLeftLe     76     G4Exception("G4PhantomBuilder::BuildLeftLeg()", "human_phantom0015", FatalException, "The world volume is missing !!!!!");
 70                                                    77   
 71   G4cout <<"MotherVolume: " <<  fMotherVolume  <<  78   G4cout <<"MotherVolume: " <<  motherVolume -> GetName()<< G4endl;
 72   G4cout << "sensitivity : "<< sensitivity <<      79   G4cout << "sensitivity : "<< sensitivity << G4endl; 
 73   fLeftLegVolume = fBody -> CreateOrgan("LeftL <<  80   leftLegVolume = body -> CreateOrgan("LeftLeg", motherVolume, colourName, solidVis, sensitivity);
 74 }                                                  81 }
 75 void G4PhantomBuilder::BuildRightLeg(const G4S     82 void G4PhantomBuilder::BuildRightLeg(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
 76 {                                                  83 { 
 77   if (fMotherVolume == nullptr)                <<  84   if (motherVolume == 0)
 78     G4Exception("G4PhantomBuilder::BuildRightL     85     G4Exception("G4PhantomBuilder::BuildRightLeg()", "human_phantom0016", FatalException, "The world volume is missing !!!!!");
 79                                                    86   
 80   G4cout <<"MotherVolume: " <<  fMotherVolume  <<  87   G4cout <<"MotherVolume: " <<  motherVolume -> GetName()<< G4endl;
 81   G4cout << "sensitivity : "<< sensitivity <<      88   G4cout << "sensitivity : "<< sensitivity << G4endl; 
 82   fRightLegVolume = fBody -> CreateOrgan("Righ <<  89   rightLegVolume = body -> CreateOrgan("RightLeg", motherVolume, colourName, solidVis, sensitivity);
 83 }                                                  90 }
 84                                                    91 
 85 void G4PhantomBuilder::BuildLeftLegBone(const      92 void G4PhantomBuilder::BuildLeftLegBone(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
 86 {                                                  93 { 
 87   if (fLeftLegVolume == nullptr)               <<  94   if (leftLegVolume == 0)
 88     G4Exception("G4PhantomBuilder::BuildLeftLe     95     G4Exception("G4PhantomBuilder::BuildLeftLegBone()", "human_phantom0017", FatalException, "The left leg volume is missing !!!!!");
 89                                                    96   
 90   G4cout <<"MotherVolume: " <<  fLeftLegVolume <<  97   G4cout <<"MotherVolume: " <<  leftLegVolume -> GetName()<< G4endl;
 91   G4cout << "sensitivity : "<< sensitivity <<      98   G4cout << "sensitivity : "<< sensitivity << G4endl; 
 92   fBody -> CreateOrgan("LeftLegBone", fLeftLeg <<  99   body -> CreateOrgan("LeftLegBone", leftLegVolume,colourName, solidVis, sensitivity);
 93 }                                                 100 }
 94                                                   101 
 95 void G4PhantomBuilder::BuildRightLegBone(const    102 void G4PhantomBuilder::BuildRightLegBone(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
 96 {                                                 103 { 
 97   if (fTrunkVolume == nullptr)                 << 104   if (trunkVolume == 0)
 98     G4Exception("G4PhantomBuilder::BuildRightL    105     G4Exception("G4PhantomBuilder::BuildRightLegBone()", "human_phantom0018", FatalException, "The right leg volume is missing !!!!!");
 99                                                   106   
100   G4cout <<"MotherVolume: " << fRightLegVolume << 107   G4cout <<"MotherVolume: " << rightLegVolume -> GetName()<< G4endl;
101   G4cout << "sensitivity : "<< sensitivity <<     108   G4cout << "sensitivity : "<< sensitivity << G4endl; 
102   fBody -> CreateOrgan("RightLegBone", fRightL << 109   body -> CreateOrgan("RightLegBone", rightLegVolume, colourName, solidVis, sensitivity);
103 }                                                 110 }
104                                                   111 
105 void G4PhantomBuilder::BuildLeftArmBone(const     112 void G4PhantomBuilder::BuildLeftArmBone(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
106 {                                                 113 { 
107   if (fTrunkVolume == nullptr)                 << 114   if (trunkVolume == 0)
108     G4Exception("G4PhantomBuilder::BuildLeftAr    115     G4Exception("G4PhantomBuilder::BuildLeftArmBone()", "human_phantom0019", FatalException, "The world volume is missing !!!!!");
109                                                   116   
110   G4cout <<"MotherVolume: " << fTrunkVolume -> << 117   G4cout <<"MotherVolume: " <<  trunkVolume -> GetName()<< G4endl;
111   G4cout << "sensitivity : "<< sensitivity <<     118   G4cout << "sensitivity : "<< sensitivity << G4endl; 
112   fBody -> CreateOrgan("LeftArmBone", fTrunkVo << 119   body -> CreateOrgan("LeftArmBone" ,trunkVolume,colourName,solidVis, sensitivity);
113 }                                                 120 }
114 void G4PhantomBuilder::BuildRightArmBone(const    121 void G4PhantomBuilder::BuildRightArmBone(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
115 {                                                 122 { 
116   if (fTrunkVolume == nullptr)                 << 123   if (trunkVolume == 0)
117     G4Exception("G4PhantomBuilder::BuildRightA    124     G4Exception("G4PhantomBuilder::BuildRightArmBone()", "human_phantom0020", FatalException, "The trunk volume is missing !!!!!");
118                                                   125   
119   G4cout <<"MotherVolume: " << fTrunkVolume -> << 126   G4cout <<"MotherVolume: " <<  trunkVolume -> GetName()<< G4endl;
120   G4cout << "sensitivity : "<< sensitivity <<     127   G4cout << "sensitivity : "<< sensitivity << G4endl; 
121   fBody -> CreateOrgan("RightArmBone", fTrunkV << 128   body -> CreateOrgan("RightArmBone",trunkVolume,colourName,solidVis, sensitivity);
122 }                                                 129 }
123                                                   130 
124 void G4PhantomBuilder::BuildLeftScapula(const     131 void G4PhantomBuilder::BuildLeftScapula(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
125 {                                                 132 { 
126   if (fTrunkVolume == nullptr)                 << 133   if (trunkVolume == 0)
127     G4Exception("G4PhantomBuilder::BuildLeftSc    134     G4Exception("G4PhantomBuilder::BuildLeftScapula()", "human_phantom0021", FatalException, "The trunk volume is missing !!!!!");
128                                                   135   
129   G4cout <<"MotherVolume: " << fTrunkVolume -> << 136   G4cout <<"MotherVolume: " <<  trunkVolume -> GetName()<< G4endl;
130   G4cout << "sensitivity : "<< sensitivity <<     137   G4cout << "sensitivity : "<< sensitivity << G4endl; 
131   fBody -> CreateOrgan("LeftScapula",fTrunkVol << 138   body -> CreateOrgan("LeftScapula",trunkVolume,colourName,solidVis, sensitivity);
132 }                                                 139 }
133                                                   140 
134 void G4PhantomBuilder::BuildRightScapula(const    141 void G4PhantomBuilder::BuildRightScapula(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
135 {                                                 142 { 
136   if (fTrunkVolume == nullptr)                 << 143   if (trunkVolume == 0)
137     G4Exception("G4PhantomBuilder::BuildRightS    144     G4Exception("G4PhantomBuilder::BuildRightScapula()", "human_phantom0022", FatalException, "The trunk volume is missing !!!!!");
138                                                   145   
139   G4cout <<"MotherVolume: " <<  fTrunkVolume - << 146   G4cout <<"MotherVolume: " <<  trunkVolume -> GetName()<< G4endl;
140   G4cout << "sensitivity : "<< sensitivity <<     147   G4cout << "sensitivity : "<< sensitivity << G4endl; 
141   fBody -> CreateOrgan("RightScapula",fTrunkVo << 148   body -> CreateOrgan("RightScapula",trunkVolume,colourName,solidVis, sensitivity);
142 }                                                 149 }
143                                                   150 
144 void G4PhantomBuilder::BuildLeftClavicle(const    151 void G4PhantomBuilder::BuildLeftClavicle(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
145 {                                                 152 { 
146   if (fTrunkVolume == nullptr)                 << 153   if (trunkVolume == 0)
147     G4Exception("G4PhantomBuilder::BuildLeftCl    154     G4Exception("G4PhantomBuilder::BuildLeftClavicle()", "human_phantom0023", FatalException, "The trunk volume is missing !!!!!");
148                                                   155   
149   G4cout <<"MotherVolume: " <<  fTrunkVolume - << 156   G4cout <<"MotherVolume: " <<  trunkVolume -> GetName()<< G4endl;
150   G4cout << "sensitivity : "<< sensitivity <<     157   G4cout << "sensitivity : "<< sensitivity << G4endl; 
151   fBody -> CreateOrgan("LeftClavicle", fTrunkV << 158   body -> CreateOrgan("LeftClavicle",trunkVolume,colourName,solidVis, sensitivity);
152 }                                                 159 }
153                                                   160 
154 void G4PhantomBuilder::BuildRightClavicle(cons    161 void G4PhantomBuilder::BuildRightClavicle(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
155 {                                                 162 { 
156   if (fTrunkVolume == nullptr)                 << 163   if (trunkVolume == 0)
157     G4Exception("G4PhantomBuilder::BuildRightC    164     G4Exception("G4PhantomBuilder::BuildRightClavicle()", "human_phantom0024", FatalException, "The trunk volume is missing !!!!!");
158                                                   165   
159   G4cout <<"MotherVolume: " << fTrunkVolume -> << 166   G4cout <<"MotherVolume: " <<  trunkVolume -> GetName()<< G4endl;
160   G4cout << "sensitivity : "<< sensitivity <<     167   G4cout << "sensitivity : "<< sensitivity << G4endl; 
161   fBody -> CreateOrgan("RightClavicle",fTrunkV << 168   body -> CreateOrgan("RightClavicle",trunkVolume,colourName,solidVis, sensitivity);
162 }                                                 169 }
163                                                   170 
                                                   >> 171 
164 void G4PhantomBuilder::BuildHead(const G4Strin    172 void G4PhantomBuilder::BuildHead(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
165 {                                                 173 { 
166   if (fMotherVolume == nullptr)                << 174   if (motherVolume == 0)
167     G4Exception("G4PhantomBuilder::BuildHead()    175     G4Exception("G4PhantomBuilder::BuildHead()", "human_phantom0025", FatalException, "The mother volume is missing !!!!!");
168                                                   176   
169   G4cout <<"MotherVolume: " <<  fMotherVolume  << 177   G4cout <<"MotherVolume: " <<  motherVolume -> GetName()<< G4endl;
170   G4cout << "sensitivity : "<< sensitivity <<     178   G4cout << "sensitivity : "<< sensitivity << G4endl; 
171   fHeadVolume = fBody -> CreateOrgan("Head", f << 179   headVolume = body -> CreateOrgan("Head",motherVolume, colourName, solidVis, sensitivity);
172 }                                                 180 }
173                                                   181 
174 void G4PhantomBuilder::BuildSkull(const G4Stri    182 void G4PhantomBuilder::BuildSkull(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
175 {                                                 183 { 
176   if (fHeadVolume == nullptr)                  << 184   if (headVolume == 0)
177     G4Exception("G4PhantomBuilder::BuildSkull(    185     G4Exception("G4PhantomBuilder::BuildSkull()", "human_phantom0026", FatalException, "The head volume is missing !!!!!");
178                                                   186   
179   G4cout <<"MotherVolume: " << fHeadVolume ->  << 187   G4cout <<"MotherVolume: " <<  headVolume -> GetName()<< G4endl;
180   G4cout << "sensitivity : "<< sensitivity <<     188   G4cout << "sensitivity : "<< sensitivity << G4endl; 
181   fBody -> CreateOrgan( "Skull", fHeadVolume,  << 189   body -> CreateOrgan( "Skull",headVolume, colourName, solidVis, sensitivity);
182 }                                                 190 }
183                                                   191 
184 void G4PhantomBuilder::BuildUpperSpine(const G    192 void G4PhantomBuilder::BuildUpperSpine(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
185 {                                                 193 { 
186   if (fHeadVolume == nullptr)                  << 194   if (headVolume == 0)
187     G4Exception("G4PhantomBuilder::BuildUpperS    195     G4Exception("G4PhantomBuilder::BuildUpperSpine()", "human_phantom0027", FatalException, "The head volume is missing !!!!!");
188                                                   196   
189   G4cout <<"MotherVolume: " << fHeadVolume ->  << 197   G4cout <<"MotherVolume: " <<  headVolume -> GetName()<< G4endl;
190   G4cout << "sensitivity : "<< sensitivity <<     198   G4cout << "sensitivity : "<< sensitivity << G4endl; 
191   fBody -> CreateOrgan("UpperSpine", fHeadVolu << 199   body -> CreateOrgan("UpperSpine",headVolume,colourName, solidVis, sensitivity);
192 }                                                 200 }
193                                                   201 
194 void G4PhantomBuilder::BuildMiddleLowerSpine(c    202 void G4PhantomBuilder::BuildMiddleLowerSpine(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
195 {                                                 203 { 
196   if (fTrunkVolume == nullptr)                 << 204   if (trunkVolume == 0)
197     G4Exception("G4PhantomBuilder::BuildMiddle    205     G4Exception("G4PhantomBuilder::BuildMiddleLowerSpine()", "human_phantom0028", FatalException, "The trunk volume is missing !!!!!");
198                                                   206   
199   G4cout <<"MotherVolume: " << fTrunkVolume -> << 207   G4cout <<"MotherVolume: " <<  trunkVolume -> GetName()<< G4endl;
200   G4cout << "sensitivity : "<< sensitivity <<     208   G4cout << "sensitivity : "<< sensitivity << G4endl; 
201   fBody -> CreateOrgan("MiddleLowerSpine",fTru << 209   body -> CreateOrgan("MiddleLowerSpine",trunkVolume, colourName, solidVis, sensitivity);
202 }                                                 210 }
203                                                   211 
204 void G4PhantomBuilder::BuildPelvis(const G4Str    212 void G4PhantomBuilder::BuildPelvis(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
205 {                                                 213 { 
206   if (fTrunkVolume == nullptr)                 << 214   if (trunkVolume == 0)
207     G4Exception("G4PhantomBuilder::BuildPelvis    215     G4Exception("G4PhantomBuilder::BuildPelvis()", "human_phantom0029", FatalException, "The trunk volume is missing !!!!!");
208                                                   216 
209   fBody -> CreateOrgan( "Pelvis", fTrunkVolume << 217     body -> CreateOrgan( "Pelvis",trunkVolume, 
                                                   >> 218       colourName, solidVis, sensitivity);
210 }                                                 219 }
211                                                   220 
212 void G4PhantomBuilder::BuildBrain(const G4Stri    221 void G4PhantomBuilder::BuildBrain(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
213 {                                                 222 { 
214   if (fHeadVolume == nullptr)                  << 223  if (headVolume == 0)
215     G4Exception("G4PhantomBuilder::BuildBrain( << 224    G4Exception("G4PhantomBuilder::BuildBrain()", "human_phantom0030", FatalException, "The head volume is missing !!!!!");
216                                                   225 
217   fBody -> CreateOrgan("Brain", fHeadVolume, c << 226     body -> CreateOrgan("Brain",headVolume, colourName, solidVis, sensitivity);
218 }                                                 227 }
219                                                   228 
220 void G4PhantomBuilder::BuildHeart(const G4Stri    229 void G4PhantomBuilder::BuildHeart(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
221 {                                                 230 { 
222   if (fTrunkVolume == nullptr)                 << 231     if (trunkVolume == 0)
223     G4Exception("G4PhantomBuilder::BuildHeart( << 232       G4Exception("G4PhantomBuilder::BuildHeart()", "human_phantom0031", FatalException, "The trunk volume is missing !!!!!");
224   fBody -> CreateOrgan("Heart", fTrunkVolume,c << 233     body -> CreateOrgan("Heart", trunkVolume,colourName, solidVis, sensitivity);
225 }                                                 234 }
226                                                   235 
227 void G4PhantomBuilder::BuildLeftLung(const G4S    236 void G4PhantomBuilder::BuildLeftLung(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
228 {                                                 237 { 
229   if (fTrunkVolume == nullptr)                 << 238    if (trunkVolume == 0)
230     G4Exception("G4PhantomBuilder::BuildLeftLu << 239      G4Exception("G4PhantomBuilder::BuildLeftLung()", "human_phantom0032", FatalException, "The trunk volume is missing !!!!!");
231                                                   240 
232   fBody -> CreateOrgan("LeftLung", fTrunkVolum << 241     body -> CreateOrgan("LeftLung",trunkVolume,colourName,solidVis, sensitivity);
233 }                                                 242 }
234                                                   243 
235 void G4PhantomBuilder::BuildRightLung(const G4    244 void G4PhantomBuilder::BuildRightLung(const G4String& colourName, G4bool solidVis, G4bool sensitivity )
236 {                                                 245 { 
237   if (fTrunkVolume == nullptr)                 << 246    if (trunkVolume == 0)
238     G4Exception("G4PhantomBuilder::BuildRightL << 247      G4Exception("G4PhantomBuilder::BuildRightLung()", "human_phantom0033", FatalException, "The trunk volume is missing !!!!!");
239                                                   248 
240   fBody -> CreateOrgan("RightLung", fTrunkVolu << 249     body -> CreateOrgan("RightLung",trunkVolume,colourName, solidVis, sensitivity);
241 }                                                 250 }
242                                                   251 
243 void G4PhantomBuilder::BuildStomach(const G4St    252 void G4PhantomBuilder::BuildStomach(const G4String& colourName, G4bool solidVis, G4bool sensitivity )
244 {                                                 253 { 
245   if (fTrunkVolume == nullptr)                 << 254   if (trunkVolume == 0)
246     G4Exception("G4PhantomBuilder::BuildStomac    255     G4Exception("G4PhantomBuilder::BuildStomach()", "human_phantom0034", FatalException, "The trunk volume is missing !!!!!");
247                                                   256 
248   fBody -> CreateOrgan("Stomach", fTrunkVolume << 257     body -> CreateOrgan("Stomach",trunkVolume,colourName, solidVis, sensitivity);
249 }                                                 258 }
250                                                   259 
251 void G4PhantomBuilder::BuildRibCage(const G4St    260 void G4PhantomBuilder::BuildRibCage(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
252 {                                                 261 { 
253   if (fTrunkVolume == nullptr)                 << 262    if (trunkVolume == 0)
254     G4Exception("G4PhantomBuilder::BuildRibCag << 263      G4Exception("G4PhantomBuilder::BuildRibCage()", "human_phantom0035", FatalException, "The trunk volume is missing !!!!!");
255                                                   264 
256   fBody -> CreateOrgan("RibCage", fTrunkVolume << 265     body -> CreateOrgan("RibCage",trunkVolume,colourName, solidVis, sensitivity);
257 }                                                 266 }
258                                                   267 
259 void G4PhantomBuilder::BuildSpleen(const G4Str    268 void G4PhantomBuilder::BuildSpleen(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
260 {                                                 269 { 
261   if (fTrunkVolume == nullptr)                 << 270    if (trunkVolume == 0)
262     G4Exception("G4PhantomBuilder::BuildSpleen << 271      G4Exception("G4PhantomBuilder::BuildSpleen()", "human_phantom0036", FatalException, "The trunk volume is missing !!!!!");
263                                                   272 
264   fBody -> CreateOrgan("Spleen", fTrunkVolume, << 273     body -> CreateOrgan("Spleen", trunkVolume,colourName, solidVis, sensitivity);
265 }                                                 274 }
266                                                   275 
267 void G4PhantomBuilder::BuildUpperLargeIntestin    276 void G4PhantomBuilder::BuildUpperLargeIntestine(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
268 {                                                 277 { 
269   if (fTrunkVolume == nullptr)                 << 278    if (trunkVolume == 0)
270     G4Exception("G4PhantomBuilder::BuildUpperL << 279      G4Exception("G4PhantomBuilder::BuildUpperLargeIntestine()", "human_phantom0037", FatalException, "The trunk volume is missing !!!!!");
271                                                   280 
272   fBody -> CreateOrgan("UpperLargeIntestine",  << 281     body -> CreateOrgan("UpperLargeIntestine",trunkVolume, colourName, solidVis, sensitivity);
273 }                                                 282 }
274                                                   283 
275 void G4PhantomBuilder::BuildLowerLargeIntestin    284 void G4PhantomBuilder::BuildLowerLargeIntestine(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
276 {                                                 285 { 
277   if (fTrunkVolume == nullptr)                 << 286   if (trunkVolume == 0)
278     G4Exception("G4PhantomBuilder::BuildLowerL    287     G4Exception("G4PhantomBuilder::BuildLowerLargeIntestine()", "human_phantom0038", FatalException, "The trunk volume is missing !!!!!");
279                                                   288 
280   fBody -> CreateOrgan("LowerLargeIntestine",  << 289    body -> CreateOrgan("LowerLargeIntestine", trunkVolume, colourName,solidVis, sensitivity);
281 }                                                 290 }
282                                                   291 
283 void G4PhantomBuilder::BuildSmallIntestine(con    292 void G4PhantomBuilder::BuildSmallIntestine(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
284 {                                                 293 { 
285   if (fTrunkVolume == nullptr)                 << 294   if (trunkVolume == 0)
286     G4Exception("G4PhantomBuilder::BuildSamllI    295     G4Exception("G4PhantomBuilder::BuildSamllIntestine()", "human_phantom0039", FatalException, "The trunk volume is missing !!!!!");
287                                                   296 
288   fBody -> CreateOrgan("SmallIntestine", fTrun << 297   body -> CreateOrgan("SmallIntestine",trunkVolume, colourName, solidVis, sensitivity);
289 }                                                 298 }
290                                                   299 
291 void G4PhantomBuilder::BuildLeftKidney(const G    300 void G4PhantomBuilder::BuildLeftKidney(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
292 {                                                 301 { 
293   if (fTrunkVolume == nullptr)                 << 302  if (trunkVolume == 0)
294     G4Exception("G4PhantomBuilder::BuildLeftKi << 303    G4Exception("G4PhantomBuilder::BuildLeftKidney()", "human_phantom0040", FatalException, "The trunk volume is missing !!!!!");
295                                                   304 
296   fBody -> CreateOrgan("LeftKidney", fTrunkVol << 305     body -> CreateOrgan("LeftKidney", trunkVolume,colourName, solidVis, sensitivity);
297 }                                                 306 }
298 void G4PhantomBuilder::BuildRightKidney(const     307 void G4PhantomBuilder::BuildRightKidney(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
299 {                                                 308 { 
300   if (fTrunkVolume == nullptr)                 << 309    if (trunkVolume == 0)
301     G4Exception("G4PhantomBuilder::BuildRightK << 310      G4Exception("G4PhantomBuilder::BuildRightKidney()", "human_phantom0041", FatalException, "The trunk volume is missing !!!!!");
302                                                   311 
303   fBody -> CreateOrgan("RightKidney", fTrunkVo << 312     body -> CreateOrgan("RightKidney",trunkVolume,colourName, solidVis, sensitivity);
304 }                                                 313 }
305                                                   314 
306 void G4PhantomBuilder::BuildLeftAdrenal(const     315 void G4PhantomBuilder::BuildLeftAdrenal(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
307 {                                                 316 { 
308   if (fTrunkVolume == nullptr)                 << 317   if (trunkVolume == 0)
309     G4Exception("G4PhantomBuilder::BuildLeftAd    318     G4Exception("G4PhantomBuilder::BuildLeftAdrenal()", "human_phantom0042", FatalException, "The trunk volume is missing !!!!!");
310                                                   319 
311   fBody -> CreateOrgan("LeftAdrenal", fTrunkVo << 320     body -> CreateOrgan("LeftAdrenal", trunkVolume,colourName, solidVis, sensitivity);
312 }                                                 321 }
313                                                   322 
314 void G4PhantomBuilder::BuildRightAdrenal(const    323 void G4PhantomBuilder::BuildRightAdrenal(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
315 {                                                 324 { 
316   if (fTrunkVolume == nullptr)                 << 325   if (trunkVolume == 0)
317     G4Exception("G4PhantomBuilder::BuildRightA    326     G4Exception("G4PhantomBuilder::BuildRightAdrenal()", "human_phantom0043", FatalException, "The trunk volume is missing !!!!!");
318                                                   327 
319   fBody -> CreateOrgan("RightAdrenal", fTrunkV << 328     body -> CreateOrgan("RightAdrenal", trunkVolume,colourName, solidVis, sensitivity);
320 }                                                 329 }
321                                                   330 
                                                   >> 331 
322 void G4PhantomBuilder::BuildLiver(const G4Stri    332 void G4PhantomBuilder::BuildLiver(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
323 {                                                 333 { 
324   if (fTrunkVolume == nullptr)                 << 334   if (trunkVolume == 0)
325     G4Exception("G4PhantomBuilder::BuildLiver(    335     G4Exception("G4PhantomBuilder::BuildLiver()", "human_phantom0044", FatalException, "The trunk volume is missing !!!!!");
326                                                   336 
327   fBody -> CreateOrgan("Liver", fTrunkVolume,c << 337     body -> CreateOrgan("Liver", trunkVolume,colourName, solidVis, sensitivity);
328 }                                                 338 }
329 void G4PhantomBuilder::BuildPancreas(const G4S    339 void G4PhantomBuilder::BuildPancreas(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
330 {                                                 340 { 
331   if (fTrunkVolume == nullptr)                 << 341    if (trunkVolume == 0)
332     G4Exception("G4PhantomBuilder::BuildPancre << 342      G4Exception("G4PhantomBuilder::BuildPancreas()", "human_phantom0045", FatalException, "The trunk volume is missing !!!!!");
333                                                   343 
334   fBody -> CreateOrgan("Pancreas", fTrunkVolum << 344     body -> CreateOrgan("Pancreas",trunkVolume,colourName, solidVis, sensitivity);
335 }                                                 345 }
336                                                   346 
337 void G4PhantomBuilder::BuildUrinaryBladder(con    347 void G4PhantomBuilder::BuildUrinaryBladder(const G4String& colourName, G4bool solidVis, G4bool sensitivity)
338 {                                                 348 { 
339   if (fTrunkVolume == nullptr)                 << 349   if (trunkVolume == 0)
340     G4Exception("G4PhantomBuilder::BuildUrinar    350     G4Exception("G4PhantomBuilder::BuildUrinaryBladder()", "human_phantom0046", FatalException, "The trunk volume is missing !!!!!");
341                                                   351 
342   fBody -> CreateOrgan("UrinaryBladder", fTrun << 352     body -> CreateOrgan("UrinaryBladder",trunkVolume, colourName, solidVis, sensitivity);
343 }                                                 353 }
344                                                   354 
345 void G4PhantomBuilder::BuildThyroid(const G4St    355 void G4PhantomBuilder::BuildThyroid(const G4String& colourName, G4bool solidVis, G4bool sensitivity )
346 {                                                 356 { 
347   if (fHeadVolume == nullptr)                  << 357    if (headVolume == 0)
348     G4Exception("G4PhantomBuilder::BuildThyroi << 358      G4Exception("G4PhantomBuilder::BuildThyroid()", "human_phantom0047", FatalException, "The trunk volume is missing !!!!!");
349                                                   359 
350   fBody -> CreateOrgan("Thyroid", fHeadVolume, << 360    body -> CreateOrgan("Thyroid",headVolume, colourName,solidVis, sensitivity);
351 }                                                 361 }
352                                                   362 
353 void G4PhantomBuilder::BuildThymus(const G4Str    363 void G4PhantomBuilder::BuildThymus(const G4String& colourName, G4bool solidVis, G4bool sensitivity )
354 {                                                 364 { 
355   if (fTrunkVolume == nullptr)                 << 365   if (trunkVolume == 0)
356     G4Exception("G4PhantomBuilder::BuildThymus    366     G4Exception("G4PhantomBuilder::BuildThymus()", "human_phantom0048", FatalException, "The trunk volume is missing !!!!!");
357                                                   367   
358   fBody -> CreateOrgan("Thymus",fTrunkVolume,  << 368   body -> CreateOrgan("Thymus",trunkVolume, colourName,solidVis, sensitivity);
359 }                                                 369 }
360                                                   370 
                                                   >> 371 
361 G4VPhysicalVolume* G4PhantomBuilder::GetPhanto    372 G4VPhysicalVolume* G4PhantomBuilder::GetPhantom()
362 {                                                 373 {
363   return fMotherVolume;                        << 374   return motherVolume;
364 }                                                 375 }
365                                                   376 
366 void G4PhantomBuilder::SetMotherVolume(G4VPhys    377 void G4PhantomBuilder::SetMotherVolume(G4VPhysicalVolume* mother)
367 {                                                 378 {
368   fMotherVolume = mother;                      << 379   motherVolume = mother;
369 }                                                 380 }
370                                                   381 
                                                   >> 382 
371 void G4PhantomBuilder::SetModel(G4String model    383 void G4PhantomBuilder::SetModel(G4String modelFlag)
372 {                                                 384 {
373   fModel = modelFlag;                          << 385   model = modelFlag;
                                                   >> 386 
                                                   >> 387   if(model=="MIRD" || model =="MIX") body = new G4MIRDBodyFactory();
                                                   >> 388   if(model=="ORNLFemale")
                                                   >> 389  {
374                                                   390 
375   if(fModel=="MIRD") fBody = new G4MIRDBodyFac << 
376   else if(fModel=="ORNLFemale")                << 
377   {                                            << 
378 #ifdef G4LIB_USE_GDML                             391 #ifdef G4LIB_USE_GDML
379     fBody = new G4ORNLFemaleBodyFactory();     << 392  body = new G4ORNLFemaleBodyFactory();
380 #else                                             393 #else
381     G4cout << fModel << " Working with GDML on << 394  G4cout << model << " Working with GDML only! set G4LIB_USE_GDML 1" << G4endl;
382 #endif                                            395 #endif
383   }                                            << 396  }
384   else if(fModel=="ORNLMale")                  << 397 
385   {                                            << 398   if(model=="ORNLMale") 
                                                   >> 399 {
386 #ifdef G4LIB_USE_GDML                             400 #ifdef G4LIB_USE_GDML
387     fBody = new G4ORNLMaleBodyFactory();       << 401 body = new G4ORNLMaleBodyFactory();
388 #else                                             402 #else
389     G4cout << fModel << " Working with GDML on << 403 G4cout << model << " Working with GDML only! set G4LIB_USE_GDML 1" << G4endl;
390 #endif                                            404 #endif
391   }                                            << 405 }
392 }                                                 406 }
393                                                   407