FairShip
Loading...
Searching...
No Matches
veto.h
Go to the documentation of this file.
1// SPDX-License-Identifier: LGPL-3.0-or-later
2// SPDX-FileCopyrightText: Copyright CERN for the benefit of the SHiP
3// Collaboration
4
5#ifndef VETO_VETO_H_
6#define VETO_VETO_H_
7
8#include <map>
9#include <vector>
10
11#include "Detector.h"
12#include "TGeoVolume.h"
13#include "TLorentzVector.h"
14#include "TVector3.h"
15
16class vetoPoint;
17class FairVolume;
18class TClonesArray;
19
29class veto : public SHiP::Detector<vetoPoint> {
30 public:
36 veto();
37
41 Bool_t ProcessHits(FairVolume* v = 0) override;
42
43 void SetFastMuon() { fFastMuon = true; } // kill all tracks except of muons
45 fFollowMuon = true;
46 } // make muon shield active to follow muons
47 void SetVesselDimensions(Float_t x1, Float_t x2, Float_t y1, Float_t y2,
48 Float_t vesselstart) {
49 VetoStartInnerX = x1;
50 VetoEndInnerX = x2;
51 VetoStartInnerY = y1;
52 VetoEndInnerY = y2;
53 zStartDecayVol = vesselstart;
54 }
55
57 void ConstructGeometry() override;
58
59 void SetVesselStructure(Float_t a, Float_t b, Float_t c, TString d, Float_t l,
60 TString e, TString f, TString v, Float_t r) {
66 vetoMed_name = e;
70 }
71
76 void PreTrack() override;
77
78 inline void SetUseSupport(Int_t use = 1) { fUseSupport = use; }
79 inline Int_t GetUseSupport() const { return fUseSupport; }
80
81 inline void SetLiquidVeto(Int_t liquid = 1) { fLiquidVeto = liquid; }
82 inline Int_t GetLiquidVeto() const { return fLiquidVeto; }
83
84 private:
90
93
99
108
109 TGeoMedium* vetoMed;
110 TGeoMedium* supportMedIn;
111 TGeoMedium* supportMedOut;
112 TGeoMedium* decayVolumeMed;
113
122
125
129
130 veto(const veto&) = delete;
131 veto& operator=(const veto&) = delete;
136 TGeoVolume* GeoTrapezoid(TString xname, Double_t wz, Double_t wX_start,
137 Double_t wX_end, Double_t wY_start, Double_t wY_end,
138 Int_t color, TGeoMedium* material, Bool_t sens);
139
146 TGeoVolume* GeoTrapezoidHollow(TString xname, Double_t thick, Double_t wz,
147 Double_t wX_start, Double_t wX_end,
148 Double_t wY_start, Double_t wY_end,
149 Int_t color, TGeoMedium* material,
150 Bool_t sens);
151
155 void AddBlock(TGeoVolumeAssembly* tInnerWall,
156 TGeoVolumeAssembly* tDecayVacuum,
157 TGeoVolumeAssembly* tOuterWall, TGeoVolumeAssembly* tLongitRib,
158 TGeoVolumeAssembly* tVerticalRib, TGeoVolumeAssembly* ttLiSc,
159 int& liScCounter, int blockNr, int nx, int ny, double z1,
160 double z2, double Zshift, double dist, double wallThick,
161 double liscThick1, double liscThick2, double ribThick);
164 TGeoVolumeAssembly* GeoCornerRib(TString xname, double ribThick, double lt1,
165 double lt2, double dz, double slopeX,
166 double slopeY, Int_t color,
167 TGeoMedium* material, Bool_t sens);
168
171 int makeId(double z, double x, double y);
174 int liscId(TString ShapeTypeName, int blockNr, int Zlayer, int number,
175 int position);
177 double wx(double z);
179 double wy(double z);
182 TGeoVolume* GeoSideObj(TString xname, double dz, double a1, double b1,
183 double a2, double b2, double dA, double dB,
184 Int_t color, TGeoMedium* material, Bool_t sens);
187 TGeoVolume* GeoCornerLiSc1(TString xname, double dz, bool isClockwise,
188 double a1, double a2, double b1, double b2,
189 double dA, double dB, Int_t color,
190 TGeoMedium* material, Bool_t sens);
193 TGeoVolume* GeoCornerLiSc2(TString xname, double dz, bool isClockwise,
194 double a1, double a2, double b1, double b2,
195 double dA, double dB, Int_t color,
196 TGeoMedium* material, Bool_t sens);
197
198 TGeoVolume* MakeSegments();
199
200 ClassDefOverride(veto, 3)
201};
202
203#endif // VETO_VETO_H_
Definition: veto.h:29
TGeoVolume * GeoTrapezoidHollow(TString xname, Double_t thick, Double_t wz, Double_t wX_start, Double_t wX_end, Double_t wY_start, Double_t wY_end, Int_t color, TGeoMedium *material, Bool_t sens)
Definition: veto.cxx:99
TString supportMedIn_name
medium of internal support structure(Default = Aluminum).
Definition: veto.h:103
void SetFollowMuon()
Definition: veto.h:44
int liscId(TString ShapeTypeName, int blockNr, int Zlayer, int number, int position)
Definition: veto.cxx:337
TString decayVolumeMed_name
medium of decay volume(Default= helium).
Definition: veto.h:107
Int_t fUseSupport
Definition: veto.h:126
Bool_t ProcessHits(FairVolume *v=0) override
Processes a hit in the veto detector.
Definition: veto.cxx:760
void SetUseSupport(Int_t use=1)
Definition: veto.h:78
int makeId(double z, double x, double y)
Definition: veto.cxx:323
void SetVesselDimensions(Float_t x1, Float_t x2, Float_t y1, Float_t y2, Float_t vesselstart)
Definition: veto.h:47
Bool_t fFollowMuon
Definition: veto.h:89
void SetVesselStructure(Float_t a, Float_t b, Float_t c, TString d, Float_t l, TString e, TString f, TString v, Float_t r)
Definition: veto.h:59
TGeoMedium * vetoMed
Definition: veto.h:109
TGeoMedium * supportMedOut
Definition: veto.h:111
TGeoMedium * decayVolumeMed
Definition: veto.h:112
TGeoVolume * GeoCornerLiSc2(TString xname, double dz, bool isClockwise, double a1, double a2, double b1, double b2, double dA, double dB, Int_t color, TGeoMedium *material, Bool_t sens)
Definition: veto.cxx:237
TGeoVolume * MakeSegments()
Definition: veto.cxx:663
Float_t VetoStartInnerX
Width of the Vessel along X at the start.
Definition: veto.h:115
double wy(double z)
slope along the length (y)
Definition: veto.cxx:161
Float_t f_LidThickness
Thickness of the entrance/exit lid of the Decay Volume.
Definition: veto.h:95
Float_t VetoEndInnerX
Width of the Vessel along X at the end.
Definition: veto.h:119
TGeoVolume * GeoSideObj(TString xname, double dz, double a1, double b1, double a2, double b2, double dA, double dB, Int_t color, TGeoMedium *material, Bool_t sens)
Definition: veto.cxx:171
void PreTrack() override
Definition: veto.cxx:806
TGeoVolumeAssembly * GeoCornerRib(TString xname, double ribThick, double lt1, double lt2, double dz, double slopeX, double slopeY, Int_t color, TGeoMedium *material, Bool_t sens)
Definition: veto.cxx:274
veto & operator=(const veto &)=delete
Int_t GetLiquidVeto() const
Definition: veto.h:82
Float_t f_OuterSupportThickness
Definition: veto.h:92
Float_t f_VetoThickness
Thickness of the liquid scintillator along z(Default = 20cm).
Definition: veto.h:97
void SetLiquidVeto(Int_t liquid=1)
Definition: veto.h:81
void AddBlock(TGeoVolumeAssembly *tInnerWall, TGeoVolumeAssembly *tDecayVacuum, TGeoVolumeAssembly *tOuterWall, TGeoVolumeAssembly *tLongitRib, TGeoVolumeAssembly *tVerticalRib, TGeoVolumeAssembly *ttLiSc, int &liScCounter, int blockNr, int nx, int ny, double z1, double z2, double Zshift, double dist, double wallThick, double liscThick1, double liscThick2, double ribThick)
Definition: veto.cxx:364
void SetFastMuon()
Definition: veto.h:43
Float_t VetoEndInnerY
Length of the Vessel along Y at the end.
Definition: veto.h:121
TGeoVolume * GeoCornerLiSc1(TString xname, double dz, bool isClockwise, double a1, double a2, double b1, double b2, double dA, double dB, Int_t color, TGeoMedium *material, Bool_t sens)
Definition: veto.cxx:200
Float_t zStartDecayVol
z Position of the Decay Volume start in the global coordinate system
Definition: veto.h:124
TGeoMedium * supportMedIn
Definition: veto.h:110
TString supportMedOut_name
medium of external support structure(Default = Aluminum).
Definition: veto.h:105
Bool_t fFastMuon
Definition: veto.h:89
veto(const veto &)=delete
Float_t f_InnerSupportThickness
Definition: veto.h:91
TGeoVolume * GeoTrapezoid(TString xname, Double_t wz, Double_t wX_start, Double_t wX_end, Double_t wY_start, Double_t wY_end, Int_t color, TGeoMedium *material, Bool_t sens)
Definition: veto.cxx:71
void ConstructGeometry() override
Constructs the detector geometry.
Definition: veto.cxx:823
TString vetoMed_name
medium of veto counter, liquid or plastic scintillator
Definition: veto.h:101
double wx(double z)
slope along the width (x)
Definition: veto.cxx:151
Float_t f_RibThickness
Definition: veto.h:98
veto()
Constructor for the Veto class.
Definition: veto.cxx:63
Float_t VetoStartInnerY
Length of the Vessel along Y at the start.
Definition: veto.h:117
Int_t fLiquidVeto
Flag option for Liquid Scintillator (Default=True).
Definition: veto.h:128
Int_t GetUseSupport() const
Definition: veto.h:79