81{
82
83 G4cout << "Defining the materials" << G4endl;
84
86
87 G4Material* air = nistManager->FindOrBuildMaterial(
"G4_AIR");
88 G4Material* pbWO4 = nistManager->FindOrBuildMaterial(
"G4_PbWO4");
89
90
91
92
93 G4double experimentalHall_x = 1000. * cm;
94 G4double experimentalHall_y = 1000. * cm;
95 G4double experimentalHall_z = 1000. * cm;
96
98 experimentalHall_x,
99 experimentalHall_y,
100 experimentalHall_z);
101
102 auto experimentalHallLog =
new G4LogicalVolume(experimentalHall_box, air,
"expHallLog",
103 nullptr,
104 nullptr,
105 nullptr);
108 G4ThreeVector(),
109 "expHall", experimentalHallLog, nullptr, false, 0);
110
111
112
113
114
115
116 G4int nbOfCrystals = 10;
117
118
119
120
121
122
123 G4double calo_xside = 31 * cm;
124 G4double calo_yside = 31 * cm;
125 G4double calo_zside = 24 * cm;
126
127 G4double crystalWidth = 3 * cm;
128 G4double crystalLength = 24 * cm;
129
130 calo_xside = (crystalWidth * nbOfCrystals) + 1 * cm;
131 calo_yside = (crystalWidth * nbOfCrystals) + 1 * cm;
132 calo_zside = crystalLength;
133
134 auto calo_box =
new G4Box(
"CMS calorimeter",
135 calo_xside / 2.,
136 calo_yside / 2., calo_zside / 2.);
138 pbWO4,
139 "calo log",
140 nullptr,
141 nullptr,
142 nullptr);
143
144 G4double xpos = 0.0;
145 G4double ypos = 0.0;
146 G4double zpos = 100.0 * cm;
147 new G4PVPlacement(
nullptr, G4ThreeVector(xpos, ypos, zpos), caloLog,
"calorimeter",
148 experimentalHallLog, false, 1);
149
150
151
152 experimentalHallLog->SetVisAttributes(G4VisAttributes::GetInvisible());
154 caloLog->SetVisAttributes(caloVisAtt);
155
156
159 fRegion->AddRootLogicalVolume(caloLog);
160
161 return experimentalHall_phys;
162}