VMC Examples Version 6.6
Loading...
Searching...
No Matches
Ex06DetectorConstructionOld Class Reference

The detector construction (via TGeo ) More...

#include <Ex06DetectorConstructionOld.h>

Inheritance diagram for Ex06DetectorConstructionOld:

Public Member Functions

 Ex06DetectorConstructionOld ()
 
virtual ~Ex06DetectorConstructionOld ()
 
void ConstructMaterials ()
 
void ConstructGeometry ()
 

Private Attributes

Double_t fWorldSize
 The world size.
 
Double_t fExpHallSize
 The experimental hall size.
 
Double_t fTankSize
 The tank size.
 
Double_t fBubbleSize
 The bubble size.
 
Int_t fImedAir
 The Air medium Id.
 
Int_t fImedWater
 The Water medium Id.
 

Detailed Description

The detector construction (via TGeo )

Date
16/05/2005
Author
I. Hrivnacova; IPN, Orsay

Definition at line 34 of file Ex06DetectorConstructionOld.h.

Constructor & Destructor Documentation

◆ Ex06DetectorConstructionOld()

Ex06DetectorConstructionOld::Ex06DetectorConstructionOld ( )

Default constuctor

Definition at line 31 of file Ex06DetectorConstructionOld.cxx.

32 : TObject(),
33 fWorldSize(1500), // 15*m
34 fExpHallSize(1000), // 10*m
35 fTankSize(500), // 5*m
36 fBubbleSize(50), // 0.5*m
37 fImedAir(-1),
38 fImedWater(-1)
39{
40 /// Default constuctor
41}
Double_t fExpHallSize
The experimental hall size.

◆ ~Ex06DetectorConstructionOld()

Ex06DetectorConstructionOld::~Ex06DetectorConstructionOld ( )
virtual

Destructor

Definition at line 44 of file Ex06DetectorConstructionOld.cxx.

45{
46 /// Destructor
47}

Member Function Documentation

◆ ConstructMaterials()

void Ex06DetectorConstructionOld::ConstructMaterials ( )

Construct materials using VMC functions

Definition at line 54 of file Ex06DetectorConstructionOld.cxx.

55{
56 /// Construct materials using VMC functions
57
58 Double_t a1[2] = { 14.01, 16.00 };
59 Double_t z1[2] = { 7.0, 8.0 };
60 Double_t w1[2] = { 0.7, 0.3 };
61 Double_t density = 1.29e-03;
62 Int_t imatAir;
63 gMC->Mixture(imatAir, "Air", a1, z1, density, 2, w1);
64
65 Double_t a2[2] = { 1.01, 16.00 };
66 Double_t z2[2] = { 1.0, 8.0 };
67 Double_t w2[2] = { 2.0, 1.0 };
68 density = 1.0;
69 Int_t imatWater;
70 gMC->Mixture(imatWater, "Water", a2, z2, density, -2, w2);
71
72 //
73 // Tracking medias
74 //
75
76 Int_t ifield = 0; // No magnetic field
77 Double_t fieldm = 0.; //
78 Double_t epsil = .001; // Tracking precision,
79 Double_t stemax = -0.01; // Maximum displacement for multiple scat
80 Double_t tmaxfd = -20.; // Maximum angle due to field deflection
81 Double_t deemax = -.3; // Maximum fractional energy loss, DLS
82 Double_t stmin = -.8;
83 Float_t* ubuf = 0;
84 gMC->Medium(fImedAir, "Air", imatAir, 0, ifield, fieldm, tmaxfd, stemax,
85 deemax, epsil, stmin, ubuf, 0);
86 gMC->Medium(fImedWater, "Water", imatWater, 0, ifield, fieldm, tmaxfd, stemax,
87 deemax, epsil, stmin, ubuf, 0);
88}

◆ ConstructGeometry()

void Ex06DetectorConstructionOld::ConstructGeometry ( )

Contruct volumes using VMC functions

Definition at line 91 of file Ex06DetectorConstructionOld.cxx.

92{
93 /// Contruct volumes using VMC functions
94
95 // The world
96 //
97 Double_t world[3];
98 world[0] = fWorldSize;
99 world[1] = fWorldSize;
100 world[2] = fWorldSize;
101 gMC->Gsvolu("WRLD", "BOX", fImedAir, world, 3);
102
103 // The experimental Hall
104 //
105 Double_t expHall[3];
106 expHall[0] = fExpHallSize;
107 expHall[1] = fExpHallSize;
108 expHall[2] = fExpHallSize;
109 gMC->Gsvolu("EXPH", "BOX", fImedAir, expHall, 3);
110
111 Double_t posX = 0.;
112 Double_t posY = 0.;
113 Double_t posZ = 0.;
114 gMC->Gspos("EXPH", 1, "WRLD", posX, posY, posZ, 0, "ONLY");
115
116 // The Water Tank
117 //
118 Double_t waterTank[3];
119 waterTank[0] = fTankSize;
120 waterTank[1] = fTankSize;
121 waterTank[2] = fTankSize;
122 gMC->Gsvolu("TANK", "BOX", fImedWater, waterTank, 3);
123
124 gMC->Gspos("TANK", 1, "EXPH", posX, posY, posZ, 0, "ONLY");
125
126 // The Air Bubble
127 //
128 Double_t bubbleAir[3];
129 bubbleAir[0] = fBubbleSize;
130 bubbleAir[1] = fBubbleSize;
131 bubbleAir[2] = fBubbleSize;
132 gMC->Gsvolu("BUBL", "BOX", fImedAir, bubbleAir, 3);
133
134 posX = 0.;
135 posY = 250.;
136 posZ = 0.;
137 gMC->Gspos("BUBL", 1, "TANK", posX, posY, posZ, 0, "ONLY");
138}

Member Data Documentation

◆ fWorldSize

Double_t Ex06DetectorConstructionOld::fWorldSize
private

The world size.

Definition at line 46 of file Ex06DetectorConstructionOld.h.

◆ fExpHallSize

Double_t Ex06DetectorConstructionOld::fExpHallSize
private

The experimental hall size.

Definition at line 47 of file Ex06DetectorConstructionOld.h.

◆ fTankSize

Double_t Ex06DetectorConstructionOld::fTankSize
private

The tank size.

Definition at line 48 of file Ex06DetectorConstructionOld.h.

◆ fBubbleSize

Double_t Ex06DetectorConstructionOld::fBubbleSize
private

The bubble size.

Definition at line 49 of file Ex06DetectorConstructionOld.h.

◆ fImedAir

Int_t Ex06DetectorConstructionOld::fImedAir
private

The Air medium Id.

Definition at line 50 of file Ex06DetectorConstructionOld.h.

◆ fImedWater

Int_t Ex06DetectorConstructionOld::fImedWater
private

The Water medium Id.

Definition at line 51 of file Ex06DetectorConstructionOld.h.


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