Geant4  10.03.p03
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
G4MIRDLeftKidney Class Reference

#include <G4MIRDLeftKidney.hh>

Inheritance diagram for G4MIRDLeftKidney:
Collaboration diagram for G4MIRDLeftKidney:

Public Member Functions

 G4MIRDLeftKidney ()
 
 ~G4MIRDLeftKidney ()
 
G4VPhysicalVolumeConstruct (const G4String &, G4VPhysicalVolume *, const G4String &, G4bool, G4bool)
 
- Public Member Functions inherited from G4VOrgan
 G4VOrgan ()
 
virtual ~G4VOrgan ()
 

Detailed Description

Definition at line 42 of file G4MIRDLeftKidney.hh.

Constructor & Destructor Documentation

G4MIRDLeftKidney::G4MIRDLeftKidney ( )

Definition at line 55 of file G4MIRDLeftKidney.cc.

56 {
57 }
G4MIRDLeftKidney::~G4MIRDLeftKidney ( )

Definition at line 59 of file G4MIRDLeftKidney.cc.

60 {
61 }

Member Function Documentation

G4VPhysicalVolume * G4MIRDLeftKidney::Construct ( const G4String volumeName,
G4VPhysicalVolume mother,
const G4String colourName,
G4bool  wireFrame,
G4bool   
)
virtual

Implements G4VOrgan.

Definition at line 64 of file G4MIRDLeftKidney.cc.

66 {
67  G4cout<<"Construct "<<volumeName<<" with mother volume "<<mother->GetName()<<G4endl;
68 
70  G4Material* soft = material -> GetMaterial("soft_tissue");
71  delete material;
72 
73  G4double ax= 4.5 *cm; //a
74  G4double by= 1.5 *cm; //b
75  G4double cz= 5.5 *cm; //c
76 
77  G4VSolid* oneLeftKidney = new G4Ellipsoid("OneLeftKidney",ax, by, cz);
78 
79  G4double xx = 6. * cm;
80  G4double yy = 12.00*cm;
81  G4double zz = 12.00*cm;
82  G4VSolid* subtrLeftKidney = new G4Box("SubtrLeftKidney",xx/2., yy/2., zz/2.);
83 
84  G4SubtractionSolid* leftKidney = new G4SubtractionSolid("LeftKidney",
85  oneLeftKidney,
86  subtrLeftKidney,
87  0,
88  G4ThreeVector(-6. *cm, // x0
89  0.0 *cm,
90  0.0 * cm));
91 
92  G4LogicalVolume* logicLeftKidney = new G4LogicalVolume(leftKidney,
93  soft,
94  "logical" + volumeName,
95  0, 0, 0);
96 
97  G4VPhysicalVolume* physLeftKidney = new G4PVPlacement(0 ,G4ThreeVector(6.*cm, // xo
98  6. *cm, //yo
99  -2.50 *cm),//zo
100  "physicalLeftKidney", logicLeftKidney,
101  mother,
102  false,
103  0, true);
104 
105 
106 
107  // Visualization Attributes
108  // G4VisAttributes* LeftKidneyVisAtt = new G4VisAttributes(G4Colour(0.72,0.52,0.04));
109  G4HumanPhantomColour* colourPointer = new G4HumanPhantomColour();
110  G4Colour colour = colourPointer -> GetColour(colourName);
111  G4VisAttributes* LeftKidneyVisAtt = new G4VisAttributes(colour);
112  LeftKidneyVisAtt->SetForceSolid(wireFrame);
113  logicLeftKidney->SetVisAttributes(LeftKidneyVisAtt);
114 
115  G4cout << "Left LeftKidney created !!!!!!" << G4endl;
116 
117  // Testing LeftKidney Volume
118  G4double LeftKidneyVol = logicLeftKidney->GetSolid()->GetCubicVolume();
119  G4cout << "Volume of LeftKidney = " << LeftKidneyVol/cm3 << " cm^3" << G4endl;
120 
121  // Testing LeftKidney Material
122  G4String LeftKidneyMat = logicLeftKidney->GetMaterial()->GetName();
123  G4cout << "Material of LeftKidney = " << LeftKidneyMat << G4endl;
124 
125  // Testing Density
126  G4double LeftKidneyDensity = logicLeftKidney->GetMaterial()->GetDensity();
127  G4cout << "Density of Material = " << LeftKidneyDensity*cm3/g << " g/cm^3" << G4endl;
128 
129  // Testing Mass
130  G4double LeftKidneyMass = (LeftKidneyVol)*LeftKidneyDensity;
131  G4cout << "Mass of LeftKidney = " << LeftKidneyMass/gram << " g" << G4endl;
132 
133 
134  return physLeftKidney;
135 }
G4Material * GetMaterial() const
CLHEP::Hep3Vector G4ThreeVector
Definition: G4Box.hh:64
const G4String & GetName() const
Definition: G4Material.hh:178
virtual G4double GetCubicVolume()
Definition: G4VSolid.cc:189
G4double GetDensity() const
Definition: G4Material.hh:180
G4VSolid * GetSolid() const
void SetForceSolid(G4bool=true)
static constexpr double gram
Definition: G4SIunits.hh:178
string material
Definition: eplot.py:19
function g(Y1, Y2, PT2)
Definition: hijing1.383.f:5205
G4GLOB_DLL std::ostream G4cout
const G4String & GetName() const
static constexpr double cm
Definition: G4SIunits.hh:119
static constexpr double cm3
Definition: G4SIunits.hh:121
#define G4endl
Definition: G4ios.hh:61
double G4double
Definition: G4Types.hh:76
void SetVisAttributes(const G4VisAttributes *pVA)

Here is the call graph for this function:


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