Project
Loading...
Searching...
No Matches
Detector.cxx
Go to the documentation of this file.
1// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
2// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
3// All rights not expressly granted are reserved.
4//
5// This software is distributed under the terms of the GNU General Public
6// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
7//
8// In applying this license CERN does not waive the privileges and immunities
9// granted to it by virtue of its status as an Intergovernmental Organization
10// or submit itself to any jurisdiction.
11
14
20
21#include "DetectorsBase/Stack.h"
23
24// FairRoot includes
25#include "FairDetector.h" // for FairDetector
26#include <fairlogger/Logger.h> // for LOG, LOG_IF
27#include "FairModule.h" // for FairModule
28#include "FairRootManager.h" // for FairRootManager
29#include "FairRun.h" // for FairRun
30#include "FairVolume.h" // for FairVolume
31#include "FairRootManager.h"
32
33#include "TGeoManager.h" // for TGeoManager, gGeoManager
34#include "TGeoMedium.h" // for TGeoMedium
35#include "TGeoTube.h" // for TGeoTube
36#include "TGeoPcon.h" // for TGeoPcon
37#include "TGeoVolume.h" // for TGeoVolume, TGeoVolumeAssembly
38#include "TParticle.h" // for TParticle
39#include "TString.h" // for TString, operator+
40#include "TVirtualMC.h" // for gMC, TVirtualMC
41#include "TVirtualMCStack.h" // for TVirtualMCStack
42#include "TMath.h" // for Abs, ATan, Exp, Tan
43#include "TCanvas.h"
44#include "TDatime.h" // for GetDate, GetTime
45
46#include <cstdio> // for NULL, snprintf
47
48using namespace o2::fct;
49using o2::itsmft::Hit;
50
51//_________________________________________________________________________________________________
53 : o2::base::DetImpl<Detector>("FCT", kTRUE),
54 mTrackData(),
55 mHits(o2::utils::createSimVector<o2::itsmft::Hit>())
56{
57}
58
59//_________________________________________________________________________________________________
60void Detector::buildFCTFromFile(std::string configFileName)
61{
62 // Geometry description from file. One line per disk
63 // z_layer r_in r_out Layerx2X0
64 // This simple file reader is not failproof. Do not add empty lines!
65
66 /*
67 # Sample MFT configuration
68 # z_layer r_in r_out Layerx2X0 layerType (0 disks, 1 squares)
69 -45.3 2.5 9.26 0.0042 1
70 -46.7 2.5 9.26 0.0042 1
71 -48.6 2.5 9.8 0.0042 1
72 -50.0 2.5 9.8 0.0042 1
73 -52.4 2.5 10.43 0.0042 1
74 -53.8 2.5 10.43 0.0042 1
75 -67.7 3.82 13.01 0.0042 1
76 -69.1 3.82 13.01 0.0042 1
77 -76.1 3.92 14.35 0.0042 1
78 -77.5 3.92 14.35 0.0042 1
79 */
80
81 mLayerName.clear();
82 mLayers.clear();
83 mConverterLayers.clear();
84 mLayerID.clear();
85
86 LOG(info) << "Building FCT Detector: From file";
87 LOG(info) << " FCT detector configuration: " << configFileName;
88 std::ifstream ifs(configFileName.c_str());
89 if (!ifs.good()) {
90 LOG(fatal) << " Invalid FCTBase.configFile!";
91 }
92 std::string tempstr;
93 float z_layer, r_in, r_out_l_side, Layerx2X0;
94 int layerNumber = 0;
95 int layerNumberSquare = 0;
96 int layerNumberDisk = 0;
97 int pseumin = 3;
98 int pseumax = 5;
99 int layerType;
100 bool r_toggle = false;
101
102 while (std::getline(ifs, tempstr)) {
103 if (tempstr[0] == '#') {
104 LOG(info) << " Comment: " << tempstr;
105 int loc_r_toggle = tempstr.find("r_toggle");
106 if (loc_r_toggle != -1) {
107 r_toggle = true;
108 LOG(info) << " Comment: R toggle activated";
109 }
110 continue;
111 }
112 std::istringstream iss(tempstr);
113 iss >> layerType;
114 iss >> z_layer;
115 if (r_toggle) {
116 auto pseurap_to_ang = [](float eta) { return 2. * TMath::ATan(TMath::Exp(-eta)); };
117 r_in = TMath::Abs(z_layer) * TMath::Tan(pseurap_to_ang(pseumax));
118 r_out_l_side = TMath::Abs(z_layer) * TMath::Tan(pseurap_to_ang(pseumin));
119 } else {
120 iss >> r_in;
121 iss >> r_out_l_side;
122 }
123 iss >> Layerx2X0;
124
125 std::string layerName = GeometryTGeo::getFCTLayerPattern() + std::string("_") + std::to_string(layerNumber);
126 mLayerName.push_back(layerName);
127 if (layerType == 0) {
128 LOG(info) << "Adding Disk Layer " << layerName << " at z = " << z_layer << " ; r_in = " << r_in << " ; r_out = " << r_out_l_side << " x/X0 = " << Layerx2X0;
129 layerNumberDisk++;
130 } else if (layerType == 1) {
131 LOG(info) << "Adding Square Layer " << layerName << " at z = " << z_layer << " ; r_in = " << r_in << " ; l_side = " << r_out_l_side << " x/X0 = " << Layerx2X0;
132 layerNumberSquare++;
133 } else if (layerType == 2) {
134 LOG(info) << "Adding passive converter Layer " << layerName << " at z = " << z_layer << " ; r_in = " << r_in << " ; r_out = " << r_out_l_side << " x/X0 = " << Layerx2X0;
135 }
136
137 if (layerType == 0 || layerType == 1) {
138 mLayers.emplace_back(layerNumber, layerName, z_layer, r_in, r_out_l_side, Layerx2X0, layerType);
139 } else if (layerType == 2) {
140 mConverterLayers.emplace_back(layerNumber, layerName, z_layer, r_in, r_out_l_side, Layerx2X0, layerType);
141 }
142 layerNumber++;
143 }
144
145 mNumberOfLayers = layerNumber;
146 LOG(info) << " Loaded FCT Detector with " << mNumberOfLayers << " layers";
147 LOG(info) << " Of which " << layerNumberDisk << " are disks";
148 LOG(info) << " Of which " << layerNumberSquare << " are disks";
149}
150
151//_________________________________________________________________________________________________
153{
154 // Export FCT Layout description to file. One line per disk
155 // z_layer r_in r_out Layerx2X0
156 TString configFileName = "FCT_layout.cfg";
157
158 LOG(info) << "Exporting FCT Detector layout to " << configFileName;
159
160 std::ofstream fOut(configFileName, std::ios::out);
161 if (!fOut) {
162 printf("Cannot open file\n");
163 return;
164 }
165 fOut << "# z_layer r_in r_out_l_side Layerx2X0" << std::endl;
166 for (auto layer : mLayers) {
167 if (layer.getType() == 0) {
168 fOut << layer.getZ() << " " << layer.getInnerRadius() << " " << layer.getOuterRadius() << " " << layer.getx2X0() << std::endl;
169 } else if (layer.getType() == 1) {
170 fOut << layer.getZ() << " " << layer.getInnerRadius() << " " << layer.getSideLength() << " " << layer.getx2X0() << std::endl;
171 }
172 }
173}
174
175//_________________________________________________________________________________________________
177{
178 // Build a basic parametrized FCT detector with nLayers equally spaced between z_first and z_first+z_length
179 // Covering pseudo rapidity [etaIn,etaOut]. Silicon thinkness computed to match layer x/X0
180
181 LOG(info) << "Building FCT Detector: Conical Telescope";
182
183 auto z_first = param.z0;
184 auto z_length = param.zLength;
185 auto etaIn = param.etaIn;
186 auto etaOut = param.etaOut;
187 auto Layerx2X0 = param.Layerx2X0;
188 mNumberOfLayers = param.nLayers;
189 mLayerID.clear();
190
191 Int_t type = 0; // Disk
192
193 for (Int_t layerNumber = 0; layerNumber < mNumberOfLayers; layerNumber++) {
194 std::string layerName = GeometryTGeo::getFCTLayerPattern() + std::to_string(layerNumber); // + mNumberOfLayers * direction);
195 mLayerName.push_back(layerName);
196
197 // Adds evenly spaced layers
198 Float_t layerZ = z_first + (layerNumber * z_length / (mNumberOfLayers - 1)) * std::copysign(1, z_first);
199 Float_t rIn = std::abs(layerZ * std::tan(2.f * std::atan(std::exp(-etaIn))));
200 Float_t rOut = std::abs(layerZ * std::tan(2.f * std::atan(std::exp(-etaOut))));
201 mLayers.emplace_back(layerNumber, layerName, layerZ, rIn, rOut, Layerx2X0, type);
202 }
203}
204
205//_________________________________________________________________________________________________
207{
208 // Build FCT according to Scoping Document
209
210 LOG(info) << "Building FCT Detector: V1";
211
212 mNumberOfLayers = 11;
213 Float_t layersx2X0 = 1.e-2;
214
215 std::vector<std::array<Float_t, 4>> layersConfig{
216 {442.0, 5.0, 17.0, layersx2X0}, // {z_layer, r_in, r_out, Layerx2X0}
217 {444.0, 5.0, 17.0, layersx2X0},
218 {446.0, 5.0, 17.0, layersx2X0},
219 {448.0, 5.0, 17.0, layersx2X0},
220 {450.0, 5.0, 17.0, layersx2X0},
221 {452.0, 5.0, 17.0, layersx2X0},
222 {460.0, 5.0, 17.0, layersx2X0},
223 {470.0, 5.0, 18.0, layersx2X0},
224 {480.0, 5.0, 18.0, layersx2X0},
225 {490.0, 5.0, 19.0, layersx2X0},
226 {500.0, 5.0, 19.0, layersx2X0}};
227
228 mLayerID.clear();
229 mLayerName.clear();
230 mLayers.clear();
231
232 Int_t type = 0; // Disk
233
234 for (int layerNumber = 0; layerNumber < mNumberOfLayers; layerNumber++) {
235 std::string layerName = GeometryTGeo::getFCTLayerPattern() + std::to_string(layerNumber);
236 mLayerName.push_back(layerName);
237 Float_t z = layersConfig[layerNumber][0];
238
239 Float_t rIn = layersConfig[layerNumber][1];
240 Float_t rOut = layersConfig[layerNumber][2];
241 Float_t x0 = layersConfig[layerNumber][3];
242
243 LOG(info) << "Adding Layer " << layerName << " at z = " << z;
244 // Add layers
245 mLayers.emplace_back(layerNumber, layerName, z, rIn, rOut, x0, type);
246 }
247}
248
249//_________________________________________________________________________________________________
251 : o2::base::DetImpl<Detector>("FCT", active),
252 mTrackData(),
253 mHits(o2::utils::createSimVector<o2::itsmft::Hit>())
254{
255}
256
257//_________________________________________________________________________________________________
259 : o2::base::DetImpl<Detector>(rhs),
260 mTrackData(),
261
263 mHits(o2::utils::createSimVector<o2::itsmft::Hit>())
264{
265 mLayerID = rhs.mLayerID;
266 mLayerName = rhs.mLayerName;
267 mNumberOfLayers = rhs.mNumberOfLayers;
268}
269
270//_________________________________________________________________________________________________
272{
273
274 if (mHits) {
275 // delete mHits;
277 }
278}
279
280//_________________________________________________________________________________________________
281Detector& Detector::operator=(const Detector& rhs)
282{
283 // The standard = operator
284 // Inputs:
285 // Detector &h the sourse of this copy
286 // Outputs:
287 // none.
288 // Return:
289 // A copy of the sourse hit h
290
291 if (this == &rhs) {
292 return *this;
293 }
294
295 // base class assignment
297
298 mLayerID = rhs.mLayerID;
299 mLayerName = rhs.mLayerName;
300 mNumberOfLayers = rhs.mNumberOfLayers;
301 mLayers = rhs.mLayers;
302 mTrackData = rhs.mTrackData;
303
305 mHits = nullptr;
306
307 return *this;
308}
309
310//_________________________________________________________________________________________________
312{
313 // Define the list of sensitive volumes
314 LOG(info) << "Initialize FCT O2Detector";
315
317
318 defineSensitiveVolumes();
319}
320
321//_________________________________________________________________________________________________
323{
324 // This method is called from the MC stepping
325 if (!(fMC->TrackCharge())) {
326 return kFALSE;
327 }
328
329 Int_t lay = 0, volID = vol->getMCid();
330 while ((lay <= mLayerID.size()) && (volID != mLayerID[lay])) {
331 ++lay;
332 }
333
334 auto stack = (o2::data::Stack*)fMC->GetStack();
335
336 bool startHit = false, stopHit = false;
337 unsigned char status = 0;
338 if (fMC->IsTrackEntering()) {
339 status |= Hit::kTrackEntering;
340 }
341 if (fMC->IsTrackInside()) {
342 status |= Hit::kTrackInside;
343 }
344 if (fMC->IsTrackExiting()) {
345 status |= Hit::kTrackExiting;
346 }
347 if (fMC->IsTrackOut()) {
348 status |= Hit::kTrackOut;
349 }
350 if (fMC->IsTrackStop()) {
351 status |= Hit::kTrackStopped;
352 }
353 if (fMC->IsTrackAlive()) {
354 status |= Hit::kTrackAlive;
355 }
356
357 // track is entering or created in the volume
358 if ((status & Hit::kTrackEntering) || (status & Hit::kTrackInside && !mTrackData.mHitStarted)) {
359 startHit = true;
360 } else if ((status & (Hit::kTrackExiting | Hit::kTrackOut | Hit::kTrackStopped))) {
361 stopHit = true;
362 }
363
364 // increment energy loss at all steps except entrance
365 if (!startHit) {
366 mTrackData.mEnergyLoss += fMC->Edep();
367 }
368 if (!(startHit | stopHit)) {
369 return kFALSE; // do nothing
370 }
371 if (startHit) {
372 mTrackData.mEnergyLoss = 0.;
373 fMC->TrackMomentum(mTrackData.mMomentumStart);
374 fMC->TrackPosition(mTrackData.mPositionStart);
375 mTrackData.mTrkStatusStart = status;
376 mTrackData.mHitStarted = true;
377 }
378 if (stopHit) {
379 TLorentzVector positionStop;
380 fMC->TrackPosition(positionStop);
381 // Retrieve the indices with the volume path
382 int chipindex = lay;
383
384 Hit* p = addHit(stack->GetCurrentTrackNumber(), chipindex, mTrackData.mPositionStart.Vect(), positionStop.Vect(),
385 mTrackData.mMomentumStart.Vect(), mTrackData.mMomentumStart.E(), positionStop.T(),
386 mTrackData.mEnergyLoss, mTrackData.mTrkStatusStart, status);
387 // p->SetTotalEnergy(vmc->Etot());
388
389 // RS: not sure this is needed
390 // Increment number of Detector det points in TParticle
391 stack->addHit(GetDetId());
392 }
393
394 return kTRUE;
395}
396
397//_________________________________________________________________________________________________
398void Detector::createMaterials()
399{
400 Int_t ifield = 2;
401 Float_t fieldm = 10.0;
403
404 Float_t tmaxfdSi = 0.1; // .10000E+01; // Degree
405 Float_t stemaxSi = 0.0075; // .10000E+01; // cm
406 Float_t deemaxSi = 0.1; // 0.30000E-02; // Fraction of particle's energy 0<deemax<=1
407 Float_t epsilSi = 1.0E-4; // .10000E+01;
408 Float_t stminSi = 0.0; // cm "Default value used"
409
410 Float_t tmaxfdAir = 0.1; // .10000E+01; // Degree
411 Float_t stemaxAir = .10000E+01; // cm
412 Float_t deemaxAir = 0.1; // 0.30000E-02; // Fraction of particle's energy 0<deemax<=1
413 Float_t epsilAir = 1.0E-4; // .10000E+01;
414 Float_t stminAir = 0.0; // cm "Default value used"
415
416 Float_t tmaxfdPb = 10.; // .10000E+01; // Degree
417 Float_t stemaxPb = 0.01; // .10000E+01; // cm
418 Float_t deemaxPb = 0.1; // .10000E+01; // Fraction of particle's energy 0<deemax<=1
419 Float_t epsilPb = 0.1; // .10000E+01;
420 Float_t stminPb = 0.0; // cm "Default value used"
421
422 // AIR
423 Float_t aAir[4] = {12.0107, 14.0067, 15.9994, 39.948};
424 Float_t zAir[4] = {6., 7., 8., 18.};
425 Float_t wAir[4] = {0.000124, 0.755267, 0.231781, 0.012827};
426 Float_t dAir = 1.20479E-3;
427
428 o2::base::Detector::Mixture(1, "AIR$", aAir, zAir, dAir, 4, wAir);
429 o2::base::Detector::Medium(1, "AIR$", 1, 0, ifield, fieldm, tmaxfdAir, stemaxAir, deemaxAir, epsilAir, stminAir);
430
431 // Add Silicon
432 o2::base::Detector::Material(3, "SILICON$", 0.28086E+02, 0.14000E+02, 0.23300E+01, 0.93600E+01, 0.99900E+03);
433 o2::base::Detector::Medium(3, "SILICON$", 3, 0, ifield, fieldm, tmaxfdSi, stemaxSi, deemaxSi, epsilSi, stminSi);
434
435 // Add Lead (copied from EMCAL)
436 o2::base::Detector::Material(2, "LEAD$", 207.2, 82, 11.35, 0.56, 18.5);
437 o2::base::Detector::Medium(2, "LEAD$", 2, 0, ifield, fieldm, tmaxfdPb, stemaxPb, deemaxPb, epsilPb, stminPb);
438}
439
440//_________________________________________________________________________________________________
442
443//_________________________________________________________________________________________________
445{
446 // This will create a branch in the output tree called Hit, setting the last
447 // parameter to kFALSE means that this collection will not be written to the file,
448 // it will exist only during the simulation
449
451 FairRootManager::Instance()->RegisterAny(addNameTo("Hit").data(), mHits, kTRUE);
452 }
453}
454
455//_________________________________________________________________________________________________
457{
458 if (!o2::utils::ShmManager::Instance().isOperational()) {
459 mHits->clear();
460 }
461}
462
463//_________________________________________________________________________________________________
465{
466 // FCT Base configuration parameters
467 auto& fctBaseParam = FCTBaseParam::Instance();
468
469 // Set the parameters for the detector layout
470 if (fctBaseParam.configFile != "") {
471 LOG(info) << "FCT Geometry configuration file provided. Overriding FCTBase.geoModel configuration.";
472 buildFCTFromFile(fctBaseParam.configFile);
473 } else {
474 switch (fctBaseParam.geoModel) {
475 case Default:
476 buildFCTV1(); // FCTV1
477 break;
478 case Telescope:
479 buildBasicFCT(fctBaseParam); // BasicFCT = Parametrized telescopic detector (equidistant layers)
480 break;
481 default:
482 LOG(fatal) << "Invalid Geometry.\n";
483 break;
484 }
485 }
486
487 exportLayout();
488
489 // Create detector materials
490 createMaterials();
491
492 // Construct the detector geometry
493 createGeometry();
494}
495
496//_________________________________________________________________________________________________
497void Detector::createGeometry()
498{
499
501
502 TGeoVolume* volFCT = new TGeoVolumeAssembly(GeometryTGeo::getFCTVolPattern());
503 TGeoVolume* volIFCT = new TGeoVolumeAssembly(GeometryTGeo::getFCTInnerVolPattern());
504
505 LOG(info) << "GeometryBuilder::buildGeometry volume name = " << GeometryTGeo::getFCTVolPattern();
506
507 TGeoVolume* vALIC = gGeoManager->GetVolume("barrel");
508 if (!vALIC) {
509 LOG(fatal) << "Could not find the top volume";
510 }
511
512 TGeoVolume* A3IPvac = gGeoManager->GetVolume("OUT_PIPEVACUUM");
513 if (!A3IPvac) {
514 LOG(info) << "Running simulation with no beam pipe.";
515 }
516
517 LOG(debug) << "FCT createGeometry: "
518 << Form("gGeoManager name is %s title is %s", gGeoManager->GetName(), gGeoManager->GetTitle());
519
520 LOG(info) << "Creating FCT layers:";
521 if (A3IPvac) {
522 for (Int_t iLayer = 0; iLayer < mLayers.size(); iLayer++) {
523 if (std::abs(mLayers[iLayer].getZ()) < 25) {
524 mLayers[iLayer].createLayer(volIFCT);
525 } else {
526 mLayers[iLayer].createLayer(volFCT);
527 }
528 }
529 A3IPvac->AddNode(volIFCT, 2, new TGeoTranslation(0., 0., 0.));
530 vALIC->AddNode(volFCT, 2, new TGeoTranslation(0., 30., 0.));
531 } else {
532 for (Int_t iLayer = 0; iLayer < mLayers.size(); iLayer++) {
533 mLayers[iLayer].createLayer(volFCT);
534 }
535 for (Int_t iLayer = 0; iLayer < mConverterLayers.size(); iLayer++) {
536 mConverterLayers[iLayer].createLayer(volFCT);
537 }
538 vALIC->AddNode(volFCT, 2, new TGeoTranslation(0., 30., 0.));
539 }
540
541 LOG(info) << "Registering FCT SensitiveLayerIDs:";
542 for (int iLayer = 0; iLayer < mLayers.size(); iLayer++) {
543 auto layerID = gMC ? TVirtualMC::GetMC()->VolId(Form("%s_%d", GeometryTGeo::getFCTSensorPattern(), mLayers[iLayer].getLayerNumber())) : 0;
544 mLayerID.push_back(layerID);
545 LOG(info) << " mLayerID[" << mLayers[iLayer].getLayerNumber() << "] = " << layerID;
546 }
547}
548
549//_________________________________________________________________________________________________
550void Detector::defineSensitiveVolumes()
551{
552 TGeoManager* geoManager = gGeoManager;
553 TGeoVolume* v;
554
555 TString volumeName;
556 LOG(info) << "Adding FCT Sensitive Volumes";
557
558 // The names of the FCT sensitive volumes have the format: FCTSensor_(0,1)_(0...sNumberLayers-1)
559 for (Int_t iLayer = 0; iLayer < mLayers.size(); iLayer++) {
560 volumeName = o2::fct::GeometryTGeo::getFCTSensorPattern() + std::to_string(mLayers[iLayer].getLayerNumber());
561 v = geoManager->GetVolume(Form("%s_%d", GeometryTGeo::getFCTSensorPattern(), mLayers[iLayer].getLayerNumber()));
562 LOG(info) << "Adding FCT Sensitive Volume => " << v->GetName();
564 }
565}
566
567//_________________________________________________________________________________________________
568Hit* Detector::addHit(int trackID, int detID, const TVector3& startPos, const TVector3& endPos,
569 const TVector3& startMom, double startE, double endTime, double eLoss, unsigned char startStatus,
570 unsigned char endStatus)
571{
572 mHits->emplace_back(trackID, detID, startPos, endPos, startMom, startE, endTime, eLoss, startStatus, endStatus);
573 return &(mHits->back());
574}
575
Definition of the Stack class.
Definition of the ITSMFT Hit class.
std::ostringstream debug
Definition of the FCTLayer class.
ClassImp(IdPath)
uint32_t stack
Definition RawData.h:1
Definition of the GeometryTGeo class.
Definition of the Detector class.
Int_t GetDetId()
void AddSensitiveVolume(TGeoVolume *v)
TVirtualMC * fMC
flag for initialisation
Definition FairModule.h:160
void RegisterAny(const char *name, T *&obj, Bool_t toFile)
static FairRootManager * Instance()
Int_t getMCid()
Definition FairVolume.h:57
Detector & operator=(const Detector &)
Definition Detector.cxx:46
void Mixture(Int_t imat, const char *name, Float_t *a, Float_t *z, Float_t dens, Int_t nlmat, Float_t *wmat)
Definition Detector.cxx:66
void Medium(Int_t numed, const char *name, Int_t nmat, Int_t isvol, Int_t ifield, Float_t fieldm, Float_t tmaxfd, Float_t stemax, Float_t deemax, Float_t epsil, Float_t stmin, Float_t *ubuf=nullptr, Int_t nbuf=0)
Definition Detector.cxx:72
static void initFieldTrackingParams(int &mode, float &maxfield)
Definition Detector.cxx:143
void Material(Int_t imat, const char *name, Float_t a, Float_t z, Float_t dens, Float_t radl, Float_t absl, Float_t *buf=nullptr, Int_t nwbuf=0)
Definition Detector.cxx:59
std::string addNameTo(const char *ext) const
Definition Detector.h:151
~Detector() override
Default destructor.
Definition Detector.cxx:271
void InitializeO2Detector() override
Initialization of the detector is done here.
Definition Detector.cxx:311
void EndOfEvent() override
Definition Detector.cxx:441
o2::itsmft::Hit * addHit(int trackID, int detID, const TVector3 &startPos, const TVector3 &endPos, const TVector3 &startMom, double startE, double endTime, double eLoss, unsigned char startStatus, unsigned char endStatus)
This method is an example of how to add your own point of type Hit to the clones array.
Definition Detector.cxx:568
void buildBasicFCT(const FCTBaseParam &param)
Definition Detector.cxx:176
void Register() override
Registers the produced collections in FAIRRootManager.
Definition Detector.cxx:444
Bool_t ProcessHits(FairVolume *v=nullptr) override
This method is called for each step during simulation (see FairMCApplication::Stepping())
Definition Detector.cxx:322
void buildFCTFromFile(std::string)
Definition Detector.cxx:60
void ConstructGeometry() override
Base class to create the detector geometry.
Definition Detector.cxx:464
Detector()
Default constructor.
Definition Detector.cxx:52
GeometryTGeo * mGeometryTGeo
Definition Detector.h:118
void Reset() override
Has to be called after each event to reset the containers.
Definition Detector.cxx:456
void exportLayout()
access to geometry details
Definition Detector.cxx:152
static const char * getFCTVolPattern()
static const char * getFCTInnerVolPattern()
static GeometryTGeo * Instance()
static const char * getFCTLayerPattern()
static const char * getFCTSensorPattern()
static ShmManager & Instance()
Definition ShmManager.h:62
const GLdouble * v
Definition glcorearb.h:832
GLint GLint GLsizei GLint GLenum GLenum type
Definition glcorearb.h:275
GLuint GLfloat x0
Definition glcorearb.h:5034
GLenum GLuint GLint GLint layer
Definition glcorearb.h:1310
GLenum GLfloat param
Definition glcorearb.h:271
GLdouble GLdouble GLdouble z
Definition glcorearb.h:843
void freeSimVector(std::vector< T > *ptr)
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...
std::string to_string(gsl::span< T, Size > span)
Definition common.h:52
Common utility functions.
LOG(info)<< "Compressed in "<< sw.CpuTime()<< " s"