CGEM BOSS 6.6.5.i
BESIII Offline Software System
Loading...
Searching...
No Matches
BesPip Class Reference

#include <BesPip.hh>

+ Inheritance diagram for BesPip:

Public Member Functions

 BesPip ()
 
virtual ~BesPip ()
 
void Construct (G4LogicalVolume *logicbes)
 
void DefineMaterial ()
 
- Public Member Functions inherited from BesSubdetector
 BesSubdetector ()
 
virtual ~BesSubdetector ()
 
G4LogicalVolume * FindLogicalVolume (const G4String &vn)
 

Additional Inherited Members

- Protected Attributes inherited from BesSubdetector
SAXProcessor m_sxp
 
ProcessingConfigurator m_config
 

Detailed Description

Definition at line 19 of file BesPip.hh.

Constructor & Destructor Documentation

◆ BesPip()

BesPip::BesPip ( )

Definition at line 25 of file BesPip.cc.

26{
27 pipPar = new BesPipParameter();
28 pipPar->ReadData();
29 for(G4int i=0; i<3; i++)
30 {
31 goldLayer[i] = pipPar->getGoldLayer(i);
32 innerBe[i] = pipPar->getInnerBe(i);
33 oilLayer[i] = pipPar->getOilLayer(i);
34 outerBe[i] = pipPar->getOuterBe(i);
35 }
36
37 for(G4int i=0; i<5; i++)
38 {
39 innerBeSide[i] = pipPar->getInnerBeSide(i);
40 innerAl[i] = pipPar->getInnerAl(i);
41 AlRing[i] = pipPar->getAlRing(i);
42 outerAl[i] = pipPar->getOuterAl(i);
43 AgLayer[i] = pipPar->getAgLayer(i);
44 CuLayer[i] = pipPar->getCuLayer(i);
45 AlCover[i] = pipPar->getAlCover(i);
46 }
47
48 logicalPip = 0;
49 physicalPip = 0;
50
51 logicalgoldLayer = 0;
52 physicalgoldLayer = 0;
53
54 logicalinnerBe = 0;
55 physicalinnerBe = 0;
56
57 logicaloilLayer = 0;
58 physicaloilLayer = 0;
59
60 logicalouterBe = 0;
61 physicalouterBe = 0;
62
63 logicalinnerBeSide = 0;
64 physicalinnerBeSide = 0;
65
66 logicalinnerAl = 0;
67 physicalinnerAl = 0;
68
69 logicalAlRing = 0;
70 physicalAlRing = 0;
71
72 logicalouterAl = 0;
73 physicalouterAl = 0;
74
75 logicalAgLayer = 0;
76 physicalAgLayer = 0;
77
78 logicalCuLayer = 0;
79 physicalCuLayer = 0;
80
81 logicalAlCover = 0;
82 physicalAlCover = 0;
83
84 Au = 0;
85 Ag = 0;
86 Oil = 0;
87}
G4double getOilLayer(G4int i)
G4double getInnerBe(G4int i)
G4double getInnerAl(G4int i)
G4double getOuterBe(G4int i)
G4double getAlRing(G4int i)
G4double getAlCover(G4int i)
G4double getAgLayer(G4int i)
G4double getInnerBeSide(G4int i)
G4double getOuterAl(G4int i)
G4double getCuLayer(G4int i)
G4double getGoldLayer(G4int i)

◆ ~BesPip()

virtual BesPip::~BesPip ( )
inlinevirtual

Definition at line 24 of file BesPip.hh.

24{;}

Member Function Documentation

◆ Construct()

void BesPip::Construct ( G4LogicalVolume * logicbes)
virtual

Implements BesSubdetector.

Definition at line 115 of file BesPip.cc.

116{
118
119 //G4RotationMatrix* xRot = new G4RotationMatrix;
120 //xRot->rotateX(90*deg);
121
122 //the logical volume of beam pipe
123 G4Tubs* solidPip1 = new G4Tubs("solidPip1",0.,33.7,134,0,360);
124 G4Tubs* solidPip2 = new G4Tubs("solidPip2",0.,48,66,0,360);
125 G4UnionSolid* solidPip_tmp = new G4UnionSolid("solidPip_tmp",solidPip1,solidPip2,0,G4ThreeVector(0,0,-167));
126 G4UnionSolid* solidPip = new G4UnionSolid("solidPip",solidPip_tmp,solidPip2,0,G4ThreeVector(0,0,167));
127 logicalPip = new G4LogicalVolume(solidPip, G4Material::GetMaterial("Beam"),"logicalPip");
128 physicalPip = new G4PVPlacement(0,G4ThreeVector(0,0,0),logicalPip,"physicalPip",logicalbes,false,0);
129
130 //the volume of gold layer
131 G4Tubs* solidgoldLayer = new G4Tubs("solidgoldLayer",goldLayer[0],goldLayer[1],goldLayer[2]/2,0,360);
132 logicalgoldLayer = new G4LogicalVolume(solidgoldLayer, Au,"logicalgoldLayer");
133 physicalgoldLayer = new G4PVPlacement(0,G4ThreeVector(0,0,0),logicalgoldLayer,"physicalgoldLayer",logicalPip,false,0);
134
135 //the volume of inner Be pipe
136 G4Tubs* solidinnerBe = new G4Tubs("solidinnerBe",innerBe[0],innerBe[1],innerBe[2]/2,0,360);
137 logicalinnerBe = new G4LogicalVolume(solidinnerBe, G4Material::GetMaterial("Beryllium"),"logicalinnerBe");
138 physicalinnerBe = new G4PVPlacement(0,G4ThreeVector(0,0,0),logicalinnerBe,"physicalinnerBe",logicalPip,false,0);
139
140 //the volume of oil layer
141 G4Tubs* solidoilLayer = new G4Tubs("solidoilLayer",oilLayer[0],oilLayer[1],oilLayer[2]/2,0,360);
142 logicaloilLayer = new G4LogicalVolume(solidoilLayer, Oil,"logicaloilLayer");
143 physicaloilLayer = new G4PVPlacement(0,G4ThreeVector(0,0,0),logicaloilLayer,"physicaloilLayer",logicalPip,false,0);
144
145 //the volume of outer Be pipe
146 G4Tubs* solidouterBe = new G4Tubs("solidouterBe",outerBe[0],outerBe[1],outerBe[2]/2,0,360);
147 logicalouterBe = new G4LogicalVolume(solidouterBe, G4Material::GetMaterial("Beryllium"),"logicalouterBe");
148 physicalouterBe = new G4PVPlacement(0,G4ThreeVector(0,0,0),logicalouterBe,"physicalouterBe",logicalPip,false,0);
149
150 //the volume of inner side Be layer
151 G4Tubs* solidinnerBeSide = new G4Tubs("solidinnerBeSide",innerBeSide[0],innerBeSide[1],innerBeSide[2]/2,0,360);
152 logicalinnerBeSide = new G4LogicalVolume(solidinnerBeSide, G4Material::GetMaterial("Beryllium"),"logicalinnerBeSide");
153 physicalinnerBeSide = new G4PVPlacement(0,G4ThreeVector(0,0,innerBeSide[3]),logicalinnerBeSide,"physicalinnerBeSide1",logicalPip,false,0);
154 new G4PVPlacement(0,G4ThreeVector(0,0,innerBeSide[4]),logicalinnerBeSide,"physicalinnerBeSide2",logicalPip,false,1);
155
156 //the volume of inner Al layer
157 G4Tubs* solidinnerAl = new G4Tubs("solidinnerAl",innerAl[0],innerAl[1],innerAl[2]/2,0,360);
158 logicalinnerAl = new G4LogicalVolume(solidinnerAl, G4Material::GetMaterial("Aluminium"),"logicalinnerAl");
159 physicalinnerAl = new G4PVPlacement(0,G4ThreeVector(0,0,innerAl[3]),logicalinnerAl,"physicalinnerAl1",logicalPip,false,0);
160 new G4PVPlacement(0,G4ThreeVector(0,0,innerAl[4]),logicalinnerAl,"physicalinnerAl2",logicalPip,false,1);
161
162 //the volume of Al ring
163 G4Tubs* solidAlRing = new G4Tubs("solidAlRing",AlRing[0],AlRing[1],AlRing[2]/2,0,360);
164 logicalAlRing = new G4LogicalVolume(solidAlRing, G4Material::GetMaterial("Aluminium"),"logicalAlRing");
165 physicalAlRing = new G4PVPlacement(0,G4ThreeVector(0,0,AlRing[3]),logicalAlRing,"physicalAlRing1",logicalPip,false,0);
166 new G4PVPlacement(0,G4ThreeVector(0,0,AlRing[4]),logicalAlRing,"physicalAlRing2",logicalPip,false,1);
167
168 //the volume of outer Al layer
169 G4Tubs* solidouterAl = new G4Tubs("solidouterAl",outerAl[0],outerAl[1],outerAl[2]/2,0,360);
170 logicalouterAl = new G4LogicalVolume(solidouterAl, G4Material::GetMaterial("Aluminium"),"logicalouterAl");
171 physicalouterAl = new G4PVPlacement(0,G4ThreeVector(0,0,outerAl[3]),logicalouterAl,"physicalouterAl1",logicalPip,false,0);
172 new G4PVPlacement(0,G4ThreeVector(0,0,outerAl[4]),logicalouterAl,"physicalouterAl2",logicalPip,false,1);
173
174 //the volume of Ag layer
175 G4Tubs* solidAgLayer = new G4Tubs("solidAgLayer",AgLayer[0],AgLayer[1],AgLayer[2]/2,0,360);
176 logicalAgLayer = new G4LogicalVolume(solidAgLayer, Ag,"logicalAgLayer");
177 physicalAgLayer = new G4PVPlacement(0,G4ThreeVector(0,0,AgLayer[3]),logicalAgLayer,"physicalAgLayer1",logicalPip,false,0);
178 new G4PVPlacement(0,G4ThreeVector(0,0,AgLayer[4]),logicalAgLayer,"physicalAgLayer2",logicalPip,false,1);
179
180 //the volume of Cu layer
181 G4Tubs* solidCuLayer = new G4Tubs("solidCuLayer",CuLayer[0],CuLayer[1],CuLayer[2]/2,0,360);
182 logicalCuLayer = new G4LogicalVolume(solidCuLayer, G4Material::GetMaterial("Copper"),"logicalCuLayer");
183 physicalCuLayer = new G4PVPlacement(0,G4ThreeVector(0,0,CuLayer[3]),logicalCuLayer,"physicalCuLayer1",logicalPip,false,0);
184 new G4PVPlacement(0,G4ThreeVector(0,0,CuLayer[4]),logicalCuLayer,"physicalCuLayer2",logicalPip,false,1);
185
186 //the volume of Al cover
187 G4Tubs* solidAlCover = new G4Tubs("solidAlCover",AlCover[0],AlCover[1],AlCover[2]/2,0,360);
188 logicalAlCover = new G4LogicalVolume(solidAlCover, G4Material::GetMaterial("Aluminium"),"logicalAlCover");
189 physicalAlCover = new G4PVPlacement(0,G4ThreeVector(0,0,AlCover[3]),logicalAlCover,"physicalAlCover1",logicalPip,false,0);
190 new G4PVPlacement(0,G4ThreeVector(0,0,AlCover[4]),logicalAlCover,"physicalAlCover2",logicalPip,false,1);
191
192 G4VisAttributes* visPip = new G4VisAttributes(G4Colour(0.,0.,1.));
193 logicalPip->SetVisAttributes(visPip);
194 //logicalPip->SetVisAttributes(G4VisAttributes::Invisible);
195 G4VisAttributes* visgold = new G4VisAttributes(G4Colour(1.,1.,0.));
196 logicalgoldLayer->SetVisAttributes(visgold);
197// logicalgoldLayer->SetVisAttributes(G4VisAttributes::Invisible);
198 G4VisAttributes* visBe = new G4VisAttributes(G4Colour(0.,1.,0.));
199 logicalinnerBe->SetVisAttributes(visBe);
200// logicalinnerBe->SetVisAttributes(G4VisAttributes::Invisible);
201 G4VisAttributes* visOil = new G4VisAttributes(G4Colour(1.,1.,1.));
202 logicaloilLayer->SetVisAttributes(visOil);
203// logicaloilLayer->SetVisAttributes(G4VisAttributes::Invisible);
204 logicalouterBe->SetVisAttributes(visBe);
205// logicalouterBe->SetVisAttributes(G4VisAttributes::Invisible);
206 logicalinnerBeSide->SetVisAttributes(visBe);
207// logicalinnerBeSide->SetVisAttributes(G4VisAttributes::Invisible);
208 logicalinnerAl->SetVisAttributes(visOil);
209// logicalinnerAl->SetVisAttributes(G4VisAttributes::Invisible);
210 logicalAlRing->SetVisAttributes(visOil);
211// logicalAlRing->SetVisAttributes(G4VisAttributes::Invisible);
212 logicalouterAl->SetVisAttributes(visOil);
213// logicalouterAl->SetVisAttributes(G4VisAttributes::Invisible);
214 logicalAgLayer->SetVisAttributes(visBe);
215// logicalAgLayer->SetVisAttributes(G4VisAttributes::Invisible);
216 logicalCuLayer->SetVisAttributes(visPip);
217// logicalCuLayer->SetVisAttributes(G4VisAttributes::Invisible);
218 logicalAlCover->SetVisAttributes(visOil);
219// logicalAlCover->SetVisAttributes(G4VisAttributes::Invisible);
220}
void DefineMaterial()
Definition BesPip.cc:89

Referenced by BesDetectorConstruction::Construct().

◆ DefineMaterial()

void BesPip::DefineMaterial ( )

Definition at line 89 of file BesPip.cc.

90{
91 G4double density, a, z,fractionmass;
92 G4int nel,natoms;
93 G4String name, symbol;
94
95 density=19.32*g/cm3;
96 a = 196.967*g/mole;
97 Au= new G4Material("Gold",79,a,density);
98
99 density=10.5*g/cm3;
100 a = 107.9*g/mole;
101 Ag= new G4Material("Silver",47,a,density);
102
103 a = 1.01*g/mole;
104 G4Element* H = new G4Element(name="Hydrogen",symbol="H" , z= 1., a);
105
106 a = 12.01*g/mole;
107 G4Element* C = new G4Element(name="Carbon" ,symbol="C" , z= 6., a);
108
109 density = 0.810*g/cm3;
110 Oil = new G4Material(name="Oil",density,nel=2);
111 Oil->AddElement(C, natoms=18);
112 Oil->AddElement(H, natoms=38);
113}
***************************************************************************************Pseudo Class RRes *****************************************************************************************Parameters and physical constants **Maarten sept ************************************************************************DOUBLE PRECISION xsmu **************************************************************************PARTICLE DATA all others are from PDG *Only resonances with known widths into electron pairs are sept ************************************************************************C Declarations C
Definition RRes.h:29
IMPLICIT REAL *A H
Definition myXsection.h:1

Referenced by Construct().


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