SND@LHC Software
Loading...
Searching...
No Matches
strawtubes_single.cxx
Go to the documentation of this file.
1// First version of the strawtracker geometry, based on NA62 straws
2// 7/10/2015
3// E. van Herwijnen eric.van.herwijnen@cern.ch
4// Also contains (for the moment) the veto station
5
6#include "strawtubes.h"
7#include "strawtubesPoint.h"
8
9#include "FairVolume.h"
10#include "FairGeoVolume.h"
11#include "FairGeoNode.h"
12#include "FairRootManager.h"
13#include "FairGeoLoader.h"
14#include "FairGeoInterface.h"
15#include "FairGeoMedia.h"
16#include "FairGeoBuilder.h"
17#include "FairRun.h"
18#include "FairRuntimeDb.h"
19#include "ShipDetectorList.h"
20#include "ShipStack.h"
21
22#include "TClonesArray.h"
23#include "TVirtualMC.h"
24#include "TGeoManager.h"
25#include "TGeoBBox.h"
26#include "TGeoCompositeShape.h"
27#include "TGeoTube.h"
28#include "TGeoMaterial.h"
29#include "TGeoMedium.h"
30
31
32#include <iostream>
33using std::cout;
34using std::endl;
35
37 : FairDetector("strawtubes", kTRUE, kVETO),
38 fTrackID(-1),
39 fVolumeID(-1),
40 fPos(),
41 fMom(),
42 fTime(-1.),
43 fLength(-1.),
44 fELoss(-1),
45 fstrawtubesPointCollection(new TClonesArray("strawtubesPoint"))
46{
47}
48
49strawtubes::strawtubes(const char* name, Bool_t active)
50 : FairDetector(name, active, kVETO),
51 fTrackID(-1),
52 fVolumeID(-1),
53 fPos(),
54 fMom(),
55 fTime(-1.),
56 fLength(-1.),
57 fELoss(-1),
58 // these values are initialized in geometry/geometry_config.py, kept here for convenience
59 //fT0z(-2390.), //! z-position of veto station
60 //fT1z(1520.), //! z-position of tracking station 1
61 //fT2z(1720.), //! z-position of tracking station 2
62 //fT3z(2160.), //! z-position of tracking station 3 (avoid overlap with magnet)
63 //fT4z(2380.), //! z-position of tracking station 4 (avoid overlap with ecal)
64
65 //fStraw_length(250.), //! Length (y) of a straw
66 //fInner_Straw_diameter(0.94), //! Inner Straw diameter
67 //fOuter_Straw_diameter(0.98), //! Outer Straw diameter
68 //fStraw_pitch(1.76), //! Distance (x) between straws in one layer
69 //fDeltaz_layer12(1.1), //! Distance (z) between layer 1&2
70 //fDeltaz_plane12(2.6), //! Distance (z) between plane 1&2
71 //fOffset_layer12(fStraw_pitch/2), //! Offset (x) between straws of layer1&2
72 //fOffset_plane12(fStraw_pitch/4), //! Offset (x) between straws of plane1&2
73 //fStraws_per_layer(284), //! Number of straws in one layer
74 //fView_angle(5), //! Stereo angle of layers in a view
75 //fWire_thickness(0.003), //! Thickness of the wire
76 //fDeltaz_view(10.), //! Distance (z) between views
77 //fVacbox_x(300.), //! x of station vacuum box
78 //fVacbox_y(300.), //! y of station vacuum box
79 fstrawtubesPointCollection(new TClonesArray("strawtubesPoint"))
80{
81}
82
84{
88 }
89}
90
92{
93 FairDetector::Initialize();
94// FairRuntimeDb* rtdb= FairRun::Instance()->GetRuntimeDb();
95// vetoGeoPar* par=(vetoGeoPar*)(rtdb->getContainer("vetoGeoPar"));
96}
97
98// ----- Private method InitMedium
99Int_t strawtubes::InitMedium(const char* name)
100{
101 static FairGeoLoader *geoLoad=FairGeoLoader::Instance();
102 static FairGeoInterface *geoFace=geoLoad->getGeoInterface();
103 static FairGeoMedia *media=geoFace->getMedia();
104 static FairGeoBuilder *geoBuild=geoLoad->getGeoBuilder();
105
106 FairGeoMedium *ShipMedium=media->getMedium(name);
107
108 if (!ShipMedium)
109 {
110 Fatal("InitMedium","Material %s not defined in media file.", name);
111 return -1111;
112 }
113 TGeoMedium* medium=gGeoManager->GetMedium(name);
114 if (medium!=NULL)
115 return ShipMedium->getMediumIndex();
116
117 return geoBuild->createMedium(ShipMedium);
118}
119
120Bool_t strawtubes::ProcessHits(FairVolume* vol)
121{
124 //Set parameters at entrance of volume. Reset ELoss.
125 if ( gMC->IsTrackEntering() ) {
126 fELoss = 0.;
127 fTime = gMC->TrackTime() * 1.0e09;
128 fLength = gMC->TrackLength();
129 gMC->TrackPosition(fPos);
130 gMC->TrackMomentum(fMom);
131 }
132
133 // Sum energy loss for all steps in the active volume
134 fELoss += gMC->Edep();
135
136 // Create strawtubesPoint at exit of active volume
137 if ( gMC->IsTrackExiting() ||
138 gMC->IsTrackStop() ||
139 gMC->IsTrackDisappeared() ) {
140 fTrackID = gMC->GetStack()->GetCurrentTrackNumber();
141 fVolumeID = vol->getMCid();
142 if (fELoss == 0. ) { return kFALSE; }
143 AddHit(fTrackID, fVolumeID, TVector3(fPos.X(), fPos.Y(), fPos.Z()),
144 TVector3(fMom.Px(), fMom.Py(), fMom.Pz()), fTime, fLength,
145 fELoss);
146 // Increment number of strawtubes det points in TParticle
147 ShipStack* stack = (ShipStack*) gMC->GetStack();
148 std::cout << "+add straw point"<<std::endl;
149 stack->AddPoint(kVETO);
150 }
151
152 return kTRUE;
153}
154
156{
157
159
160}
161
162
163
165{
166
173 FairRootManager::Instance()->Register("strawtubesPoint", "strawtubes",
175
176}
177
178
179TClonesArray* strawtubes::GetCollection(Int_t iColl) const
180{
181 if (iColl == 0) { return fstrawtubesPointCollection; }
182 else { return NULL; }
183}
184
186{
188}
189void strawtubes::SetZpositions(Double32_t z0, Double32_t z1, Double32_t z2, Double32_t z3, Double32_t z4)
190{
191 fT0z = z0;
192 fT1z = z1;
193 fT2z = z2;
194 fT3z = z3;
195 fT4z = z4;
196 //std::cout << "++++++++++++++++++++++++++++++++++++++++++++++"<<std::endl;
197 //std::cout << "setting z positions " << fT0z << " " << fT1z << fT2z << " " << fT3z << " " << fT4z << std::endl;
198 //std::cout << "++++++++++++++++++++++++++++++++++++++++++++++"<<std::endl;
199}
200
201void strawtubes::SetStrawLength(Double32_t strawlength)
202{
203 fStraw_length = strawlength;
204}
205
206void strawtubes::SetInnerStrawDiameter(Double32_t innerstrawdiameter)
207{
208 fInner_Straw_diameter = innerstrawdiameter;
209}
210
211void strawtubes::SetOuterStrawDiameter(Double32_t outerstrawdiameter)
212{
213 fOuter_Straw_diameter = outerstrawdiameter;
214}
215
216void strawtubes::SetStrawPitch(Double32_t strawpitch)
217{
218 fStraw_pitch = strawpitch;
219 fOffset_layer12 = strawpitch/2;
220 fOffset_plane12 = strawpitch/4;
221}
222
223void strawtubes::SetDeltazLayer(Double32_t deltazlayer)
224{
225 fDeltaz_layer12 = deltazlayer;
226}
227
228void strawtubes::SetDeltazPlane(Double32_t deltazplane)
229{
230 fDeltaz_plane12 = deltazplane;
231}
232
233void strawtubes::SetStrawsPerLayer(Int_t strawsperlayer)
234{
235 fStraws_per_layer = strawsperlayer;
236}
237
238void strawtubes::SetStereoAngle(Int_t stereoangle)
239{
240 fView_angle = stereoangle;
241}
242
243void strawtubes::SetWireThickness(Double32_t wirethickness)
244{
245 fWire_thickness = wirethickness;
246}
247
248void strawtubes::SetDeltazView(Double32_t deltazview)
249{
250 fDeltaz_view = deltazview;
251}
252
253void strawtubes::SetVacBox_x(Double32_t vacbox_x)
254{
255 fVacBox_x = vacbox_x;
256}
257
258void strawtubes::SetVacBox_y(Double32_t vacbox_y)
259{
260 fVacBox_y = vacbox_y;
261}
262
264{
269 //gGeoManager->SetVisLevel(6); //depth level painted - default 3
270 //gGeoManager->SetVisOption(0); //0 show all nodes down to vislevel
271 //gGeoManager->SetTopVisible();
272 std::cout << "start straw geo"<<std::endl;
273 TGeoVolume *top = gGeoManager->GetTopVolume();
274 InitMedium("air");
275 TGeoMedium *air = gGeoManager->GetMedium("air");
276 InitMedium("ShipSens");
277 TGeoMedium *Se = gGeoManager->GetMedium("ShipSens");
278 InitMedium("aluminium");
279 TGeoMedium *Al = gGeoManager->GetMedium("aluminium");
280 InitMedium("mylar");
281 TGeoMedium *mylar = gGeoManager->GetMedium("mylar");
282 InitMedium("STTmix9010_2bar");
283 TGeoMedium *sttmix9010_2bar = gGeoManager->GetMedium("STTmix9010_2bar");
284 InitMedium("tungsten");
285 TGeoMedium *tungsten = gGeoManager->GetMedium("tungsten");
286 InitMedium("vacuum");
287 TGeoMedium *med = gGeoManager->GetMedium("vacuum");
288
289 //epsilon to avoid overlapping volumes
290 Double_t eps=0.0001;
291 //width of frame
292 Double_t framewidth = 40.;
293 //width of view
294 Double_t viewwidth = fDeltaz_view-eps;
295 //width of plane
296 Double_t planewidth = fOuter_Straw_diameter+fDeltaz_layer12-eps;
297 //width of layer
298 Double_t layerwidth = fOuter_Straw_diameter;
299
300 Double_t rmin, rmax, dx, dy, dz, z, density,a,w;
301 Double_t par[20];
302 Int_t nel,numed,isvol,ifield;
303 Double_t radl, absl, TStationz;
304
305 //arguments of box are half-lengths
306 TGeoBBox *detbox1 = new TGeoBBox("detbox1", fStraw_length+5., fStraw_length+5., fDeltaz_view/2.);
307 TGeoBBox *detbox2 = new TGeoBBox("detbox2", fStraw_length+eps, fStraw_length+eps, fDeltaz_view/2.);
308
309 //the station sits inside a vacuum box
310 TGeoBBox *vetovacbox = new TGeoBBox("Vetovacbox", fVacBox_x, fVacBox_y, fDeltaz_view+eps );
311
312
313 TGeoCompositeShape *detcomp1 = new TGeoCompositeShape("detcomp1", "detbox1-detbox2");
314
315 TGeoVolume *vetovac = new TGeoVolume("Veto", vetovacbox, med);
316 //vetovac->SetVisibility(kFALSE);
317 //vetovac->VisibleDaughters(kTRUE);
318 top->AddNode(vetovac, 1, new TGeoTranslation(0, 0, fT0z));
319
320
321 //Veto station
322 //vnb=view number; pnb=plane number; lnb=layer number; snb=straw number
323
324 TString nmveto = "Veto";
325 TStationz=fT0z;
326 for (Int_t vnb=0; vnb<2; vnb++) {
327 //view loop
328 TString nmview;
329 Double_t angle;
330 TGeoRotation r5;
331 TGeoTranslation t5;
332 switch (vnb) {
333 case 0:
334 angle=0.;
335 nmview = nmveto+"_x";
336 break;
337 case 1:
339 nmview = nmveto+"_u";
340 break;
341 default:
342 angle=0.;
343 nmview = nmveto+"_x";
344 }
345
346 TGeoVolume *viewframe = new TGeoVolume(nmview, detcomp1, Al);
347 //z-translate the viewframe from station z pos
348 t5.SetTranslation(0, 0,(vnb-1./2.)*(fDeltaz_view));
349 //rotate the frame box by angle degrees around the z axis (0 if it isn't a stereo view)
350 r5.SetAngles(angle,0,0);
351 TGeoCombiTrans c5(t5, r5);
352 TGeoHMatrix *h5 = new TGeoHMatrix(c5);
353 vetovac->AddNode(viewframe, 4*10000000+vnb*1000000,h5);
354 //viewframe->SetVisibility(kTRUE);
355 //viewframe->VisibleDaughters(kTRUE);
356 viewframe->SetLineColor(kRed);
357
358 TGeoTranslation t5p;
359
360 for (Int_t pnb=0; pnb<2; pnb++) {
361 //plane loop
362 TString nmplane = nmview+"_plane_"; nmplane += pnb;
363 //width of the planes: z distance between layers + outer straw diameter
364 TGeoBBox *plane = new TGeoBBox("plane box", fStraw_length-eps, fStraw_length-eps, planewidth/2.);
365 TGeoVolume *planebox = new TGeoVolume(nmplane, plane, med);
366 //the planebox sits in the viewframe
367 //hence z translate the plane wrt to the view
368 viewframe->AddNode(planebox, 4*10000000+vnb*1000000+pnb*100000,new TGeoTranslation(0, 0,(pnb-1./2.)*fDeltaz_plane12));
369 planebox->SetVisibility(kFALSE);
370 //planebox->VisibleDaughters(kTRUE);
371
372 /* TGeoRotation r5l;
373 TGeoTranslation t5l;
374 for (Int_t lnb=0; lnb<2; lnb++) {
375 TString nmlayer = nmplane+"_layer_"; nmlayer += lnb;
376 //width of the layer: (plane width-2eps)/2
377 TGeoBBox *layer = new TGeoBBox("layer box", fStraw_length-2*eps, fStraw_length-2*eps, layerwidth/2.);
378 TGeoVolume *layerbox = new TGeoVolume(nmlayer, layer, med);
379 //z translate the layerbox wrt the plane box (which is already rotated)
380 planebox->AddNode(layerbox, 4*10000000+vnb*1000000+pnb*100000+lnb*10000,new TGeoTranslation(0,0,(lnb-1./2.)*fDeltaz_layer12));
381 //layerbox->SetVisibility(kFALSE);
382 //layerbox->VisibleDaughters(kTRUE);
383 //std::cout <<nmlayer<<"veto zpos "<<TStationz-(1./2.-vnb)*(fDeltaz_view)+(pnb-1./2.)*fDeltaz_plane12+(lnb-1./2.)*fDeltaz_layer12<<std::endl;
384 //layer loop
385 TGeoRotation r5s;
386 TGeoTranslation t5s;
387 for (Int_t snb=0; snb<fStraws_per_layer; snb++) {
388 //straw loop
389 t5s.SetTranslation(fStraw_length-fStraw_pitch*snb-8*eps+fOffset_plane12*pnb+lnb*fOffset_layer12, 0,0);
390 //straws are tubes defined along the z-axis, so need to rotate them first by 90 degrees around the x-axis to get them vertical
391 //then x translate the straws according to their plane, layer and number
392 r5s.SetAngles(0,90,0);
393 TGeoCombiTrans c5s(t5s, r5s);
394 TGeoHMatrix *h5s = new TGeoHMatrix(c5s);
395
396 // Volume: straw
397 rmin = fInner_Straw_diameter/2.;
398 rmax = fOuter_Straw_diameter/2.;
399 TString nmstraw = nmlayer+"_straw_"; nmstraw += snb;
400 //third argument is halflength of tube
401 TGeoTube *straw_tube = new TGeoTube(nmstraw,rmin,rmax,fStraw_length-4.*eps);
402 TGeoVolume *straw = new TGeoVolume(nmstraw,straw_tube, mylar);
403 straw->SetLineColor(4);
404 //straw->SetVisibility(kTRUE);
405
406 // Volume: gas
407 rmin = fWire_thickness+eps;
408 rmax = fInner_Straw_diameter/2.-eps;
409 TString nmgas = nmlayer+"_gas_"; nmgas += snb;
410 TGeoTube *gas_tube = new TGeoTube(nmgas,rmin,rmax,fStraw_length-6.*eps);
411 TGeoVolume *gas = new TGeoVolume(nmgas,gas_tube, sttmix9010_2bar);
412 gas->SetLineColor(5);
413 //gas->SetVisibility(kTRUE);
414
415 // Volume: wire
416 rmin=0.;
417 rmax = fWire_thickness;
418 TString nmwire = nmlayer+"_wire_"; nmwire += snb;
419 TGeoTube *wire_tube = new TGeoTube("wire",rmin,rmax,fStraw_length-8.*eps);
420 TGeoVolume *wire = new TGeoVolume(nmwire,wire_tube, tungsten);
421 wire->SetLineColor(6);
422 //wire->SetVisibility(kTRUE);
423
424 layerbox->AddNode(straw,4*10000000+vnb*1000000+pnb*100000+lnb*10000+1000+snb,h5s);
425 AddSensitiveVolume(straw);
426 layerbox->AddNode(gas,4*10000000+vnb*1000000+pnb*100000+lnb*10000+2000+snb,h5s);
427 layerbox->AddNode(wire,4*10000000+vnb*1000000+pnb*100000+lnb*10000+3000+snb,h5s);
428 //only the straws are sensitive
429
430 //end of straw loop
431 }
432 //end of layer loop
433 }*/
434 //end of plane loop
435 }
436 //end of view loop
437 }
438 // end of veto station loop
439
440 //Tracking stations
441 //statnb=station number; vnb=view number; pnb=plane number; lnb=layer number; snb=straw number
442 TGeoBBox *vacbox = new TGeoBBox("vacbox", fVacBox_x, fVacBox_y, 2.*fDeltaz_view+eps );
443
444 for (Int_t statnb=0;statnb<4;statnb++) {
445 // tracking station loop
446 TString nmstation = "Tr"; nmstation += statnb;
447
448 switch (statnb) {
449 case 0:
450 TStationz=fT1z;
451 break;
452 case 1:
453 TStationz=fT2z;
454 break;
455 case 2:
456 TStationz=fT3z;
457 break;
458 case 3:
459 TStationz=fT4z;
460 break;
461 default:
462 break;
463 }
464
465 TGeoVolume *vac = new TGeoVolume(nmstation, vacbox, med);
466 //vac->SetVisibility(kFALSE);
467 //vac->VisibleDaughters(kTRUE);
468 top->AddNode(vac, 5, new TGeoTranslation(0, 0, TStationz));
469
470 for (Int_t vnb=0; vnb<4; vnb++) {
471 //view loop
472 TString nmview;
473 Double_t angle;
474 TGeoRotation r5;
475 TGeoTranslation t5;
476
477 switch (vnb) {
478 case 0:
479 angle=0.;
480 nmview = nmstation+"_x1";
481 break;
482 case 1:
484 nmview = nmstation+"_u";
485 break;
486 case 2:
488 nmview = nmstation+"_v";
489 break;
490 case 3:
491 angle=0.;
492 nmview = nmstation+"_x2";
493 break;
494 default:
495 angle=0.;
496 nmview = nmstation+"_x1";
497 }
498
499 TGeoVolume *viewframe = new TGeoVolume(nmview, detcomp1, Al);
500 //z-translate the viewframe from station z pos
501 t5.SetTranslation(0, 0,(vnb-3./2.)*(fDeltaz_view));
502 //rotate the frame box by angle degrees around the z axis (0 if it isn't a stereo view)
503 r5.SetAngles(angle,0,0);
504 TGeoCombiTrans c5(t5, r5);
505 TGeoHMatrix *h5 = new TGeoHMatrix(c5);
506 vac->AddNode(viewframe, statnb*10000000+vnb*1000000,h5);
507 //viewframe->SetVisibility(kTRUE);
508 //viewframe->VisibleDaughters(kTRUE);
509 viewframe->SetLineColor(kRed);
510
511 // Volume: straw
513 rmax = fOuter_Straw_diameter/2.;
514 //third argument is halflength of tube
515 TGeoTube *straw_tube = new TGeoTube("_straw_",rmin,rmax,fStraw_length-4.*eps);
516 TGeoVolume *straw = new TGeoVolume("_straw_",straw_tube, mylar);
517 straw->SetLineColor(4);
518 //straw->SetVisibility(kTRUE);
519 AddSensitiveVolume(straw);
520
521 // Volume: gas
523 rmax = fInner_Straw_diameter/2.-eps;
524 TGeoTube *gas_tube = new TGeoTube("_gas_",rmin,rmax,fStraw_length-6.*eps);
525 TGeoVolume *gas = new TGeoVolume("_gas_",gas_tube, sttmix9010_2bar);
526 gas->SetLineColor(5);
527 //gas->SetVisibility(kTRUE);
528
529 // Volume: wire
530 rmin=0.;
531 rmax = fWire_thickness;
532 TGeoTube *wire_tube = new TGeoTube("wire",rmin,rmax,fStraw_length-8.*eps);
533 TGeoVolume *wire = new TGeoVolume("_wire_",wire_tube, tungsten);
534 wire->SetLineColor(6);
535 //wire->SetVisibility(kTRUE);
536
537 for (Int_t pnb=0; pnb<2; pnb++) {
538 //plane loop
539 TString nmplane = nmview+"_plane_"; nmplane += pnb;
540 //width of the planes: z distance between layers + outer straw diameter
541 TGeoBBox *plane = new TGeoBBox("plane box", fStraw_length-eps, fStraw_length-eps, planewidth/2.);
542 TGeoVolume *planebox = new TGeoVolume(nmplane, plane, med);
543 //the planebox sits in the viewframe
544 //hence z translate the plane wrt to the view
545 viewframe->AddNode(planebox, statnb*10000000+vnb*1000000+pnb*100000,new TGeoTranslation(0, 0,(pnb-1./2.)*fDeltaz_plane12));
546 //planebox->SetVisibility(kFALSE);
547 //planebox->VisibleDaughters(kTRUE);
548 TGeoRotation r5l;
549 TGeoTranslation t5l;
550 for (Int_t lnb=0; lnb<2; lnb++) {
551 TString nmlayer = nmplane+"_layer_"; nmlayer += lnb;
552 //width of the layer: (plane width-2eps)/2
553 TGeoBBox *layer = new TGeoBBox("layer box", fStraw_length-2*eps, fStraw_length-2*eps, layerwidth/2.);
554 TGeoVolume *layerbox = new TGeoVolume(nmlayer, layer, med);
555 //z translate the layerbox wrt the plane box (which is already rotated)
556 planebox->AddNode(layerbox, statnb*10000000+vnb*1000000+pnb*100000+lnb*10000,new TGeoTranslation(0,0,(lnb-1./2.)*fDeltaz_layer12));
557 //layerbox->SetVisibility(kTRUE);
558 //layerbox->VisibleDaughters(kTRUE);
559 //std::cout <<nmlayer<<" zpos "<<TStationz-(1./2.-vnb)*(fDeltaz_view)+(pnb-1./2.)*fDeltaz_plane12+(lnb-1./2.)*fDeltaz_layer12<<std::endl;
560
561 //layer loop
562 TGeoRotation r6s;
563 TGeoTranslation t6s;
564 for (Int_t snb=0; snb<fStraws_per_layer; snb++) {
565 //straw loop
566 t6s.SetTranslation(fStraw_length-fStraw_pitch*snb-8*eps+fOffset_plane12*pnb+lnb*fOffset_layer12, 0,0);
567 //straws are tubes defined along the z-axis, so need to rotate them first by 90 degrees around the x-axis to get them vertical
568 //then x translate the straws according to their plane, layer and number
569 r6s.SetAngles(0,90,0);
570 TGeoCombiTrans c6s(t6s, r6s);
571 TGeoHMatrix *h6s = new TGeoHMatrix(c6s);
572
573
574 layerbox->AddNode(straw,statnb*10000000+vnb*1000000+pnb*100000+lnb*10000+1000+snb,h6s);
575 layerbox->AddNode(gas,statnb*10000000+vnb*1000000+pnb*100000+lnb*10000+2000+snb,h6s);
576 layerbox->AddNode(wire,statnb*10000000+vnb*1000000+pnb*100000+lnb*10000+3000+snb,h6s);
577 //only the straws are sensitive
578
579 //end of straw loop
580 }
581 //end of layer loop
582 }
583 //end of plane loop
584 }
585 //end of view loop
586 }
587 //end of station
588 }
589 std::cout << "end straw geo"<<std::endl;
590}
591
592strawtubesPoint* strawtubes::AddHit(Int_t trackID, Int_t detID,
593 TVector3 pos, TVector3 mom,
594 Double_t time, Double_t length,
595 Double_t eLoss)
596{
597 TClonesArray& clref = *fstrawtubesPointCollection;
598 Int_t size = clref.GetEntriesFast();
599 cout << "strawtubes hit called pos.z="<< pos.z()<< " detID= "<<detID<<endl;
600 return new(clref[size]) strawtubesPoint(trackID, detID, pos, mom,
601 time, length, eLoss);
602}
603
@ kVETO
Double_t fT2z
z-position of tracking station 1
Definition strawtubes.h:118
Int_t fVolumeID
track index
Definition strawtubes.h:110
virtual void EndOfEvent()
strawtubesPoint * AddHit(Int_t trackID, Int_t detID, TVector3 pos, TVector3 mom, Double_t time, Double_t length, Double_t eLoss, Int_t pdgCode, Double_t dist2Wire)
void SetDeltazPlane(Double_t deltazplane)
void SetZpositions(Double_t z0, Double_t z1, Double_t z2, Double_t z3, Double_t z4)
void SetVacBox_x(Double_t vacbox_x)
TLorentzVector fMom
position at entrance
Definition strawtubes.h:112
Double_t fDeltaz_view
Material of the view frame.
Definition strawtubes.h:139
TLorentzVector fPos
volume id
Definition strawtubes.h:111
Int_t fStraws_per_layer
Offset (x) between straws of plane1&2.
Definition strawtubes.h:131
TClonesArray * fstrawtubesPointCollection
spatial resolution
Definition strawtubes.h:152
Double_t fInner_Straw_diameter
strawlength for veto station
Definition strawtubes.h:124
void SetInnerStrawDiameter(Double_t innerstrawdiameter)
void ConstructGeometry()
Double_t fDeltaz_plane12
Distance (z) between layer 1&2.
Definition strawtubes.h:128
virtual void Reset()
virtual void Initialize()
void SetStrawsPerLayer(Int_t strawsperlayer)
Double_t fOffset_layer12
Distance (z) between plane 1&2.
Definition strawtubes.h:129
void SetStereoAngle(Int_t stereoangle)
virtual TClonesArray * GetCollection(Int_t iColl) const
Double_t fWire_thickness
Definition strawtubes.h:135
Int_t InitMedium(const char *name)
Double_t fStraw_length
z-position of tracking station 4
Definition strawtubes.h:121
Double_t fT3z
z-position of tracking station 2
Definition strawtubes.h:119
void SetStrawLength(Double_t strawlength)
virtual void Register()
Double_t fELoss
length
Definition strawtubes.h:115
virtual ~strawtubes()
Double_t fT1z
z-position of veto station
Definition strawtubes.h:117
Double_t fStraw_pitch
Outer Straw diameter.
Definition strawtubes.h:126
Double_t fDeltaz_layer12
Distance (x) between straws in one layer.
Definition strawtubes.h:127
Double_t fOffset_plane12
Offset (x) between straws of layer2&1.
Definition strawtubes.h:130
Double_t fT0z
energy loss
Definition strawtubes.h:116
Double_t fTime
momentum at entrance
Definition strawtubes.h:113
void SetOuterStrawDiameter(Double_t outerstrawdiameter)
void SetWireThickness(Double_t wirethickness)
void SetStrawPitch(Double_t strawpitch, Double_t layer_offset, Double_t plane_offset)
Double_t fLength
time
Definition strawtubes.h:114
Int_t fTrackID
Definition strawtubes.h:109
void SetDeltazLayer(Double_t deltazlayer)
virtual Bool_t ProcessHits(FairVolume *v=0)
Double_t fVacBox_x
Distance (z) between views.
Definition strawtubes.h:140
void SetDeltazView(Double_t deltazview)
Double_t fVacBox_y
x size of station vacuumbox
Definition strawtubes.h:141
Double_t fView_angle
Number of straws in one layer.
Definition strawtubes.h:132
Double_t fOuter_Straw_diameter
Inner Straw diameter.
Definition strawtubes.h:125
void SetVacBox_y(Double_t vacbox_y)
Double_t fT4z
z-position of tracking station 3
Definition strawtubes.h:120
ClassImp(ecalContFact) ecalContFact
real(dp), parameter, public eps