Newer
Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
#ifndef Tiara_h
#define Tiara_h 1
/*****************************************************************************
* Copyright (C) 2009-2013 this file is part of the NPTool Project *
* *
* For the licensing terms see $NPTOOL/Licence/NPTool_Licence *
* For the list of contributors see $NPTOOL/Licence/Contributors *
*****************************************************************************/
/*****************************************************************************
* Original Author: Adrien MATTA contact address: a.matta@surrey.ac.uk *
* *
* Creation Date : November 2012 *
* Last update : *
*---------------------------------------------------------------------------*
* Decription: *
* This class describe the Tiara Silicon detector *
* *
*---------------------------------------------------------------------------*
* Comment: *
* *
*****************************************************************************/
// C++ header
#include <string>
#include <vector>
// G4 header defining G4 types
#include "globals.hh"
// G4 headers
#include "G4ThreeVector.hh"
#include "G4RotationMatrix.hh"
#include "G4LogicalVolume.hh"
#include "G4VisAttributes.hh"
#include "G4MultiFunctionalDetector.hh"
// NPSimulation header
#include "VDetector.hh"
// NPLib
#include "TTiaraBarrelData.h"
#include "TTiaraHyballData.h"
using namespace std;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
namespace TIARA
{
// Energy and time Resolution
const G4double ResoTime = 0 ;
//const G4double ResoEnergy = 0.035*MeV ;// = zzkeV of Resolution // Unit is MeV/2.35
const G4double ResoEnergy = 0.042*MeV ;// = zzkeV of Resolution // Unit is MeV/2.35
// Geometric Information //
// Chanber //
// Central Tube
const G4double CHAMBER_CentralTube_Inner_Radius = 4.86*cm; //4.05->Original Value for the Single stage barrel
const G4double CHAMBER_CentralTube_Outer_Radius = 5.05*cm; //4.25->Original Value for the Single stage barrel
const G4double CHAMBER_CentralTube_Length = 4.12*cm;
// Outer Cone
const G4double CHAMBER_OuterCone_Length = 4.94*cm;
const G4double CHAMBER_OuterCone_Z_Pos = 9.06*cm;
// Outer Cylinder
const G4double CHAMBER_OuterCylinder_Inner_Radius = 24.6*cm;
const G4double CHAMBER_OuterCylinder_Outer_Radius = 25.0*cm;
const G4double CHAMBER_OuterCylinder_Length = 6.04*cm;
const G4double CHAMBER_OuterCylinder_Z_Pos = 19.96*cm;
// Inner Barrel //
const G4double INNERBARREL_PCB_Length = 98.00*mm;
const G4double INNERBARREL_PCB_Width = 27.76*mm;
const G4double INNERBARREL_PCB_Thickness = 1.60*mm;
const G4double INNERBARREL_PCB_Offset = 15*mm; // offset between the edge of the PCB and the Edge of the Waffer
const G4double INNERBARREL_Wafer_Length = 82.00*mm;// Different from Marc code, to be checked
const G4double INNERBARREL_Wafer_Width = 24.80*mm;
const G4double INNERBARREL_Wafer_Thickness =400*um;
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
}
using namespace TIARA;
class Tiara : public VDetector
{
////////////////////////////////////////////////////
/////// Default Constructor and Destructor /////////
////////////////////////////////////////////////////
public:
Tiara() ;
~Tiara() ;
////////////////////////////////////////////////////
//////// Specific Function of this Class ///////////
////////////////////////////////////////////////////
public:
// To add a box detector
// Effectively construct Volume
void ConstructBarrel(G4LogicalVolume* world);
void ConstructHyball(G4LogicalVolume* world);
void ConstructChamber(G4LogicalVolume* world);
////////////////////////////////////////////////////
///////// Inherite from VDetector class ///////////
////////////////////////////////////////////////////
public:
// Read stream at Configfile to pick-up parameters of detector (Position,...)
// Called in DetecorConstruction::ReadDetextorConfiguration Method
void ReadConfiguration(string Path) ;
// Construct detector and inialise sensitive part.
// Called After DetecorConstruction::AddDetector Method
void ConstructDetector(G4LogicalVolume* world) ;
// Add Detector branch to the EventTree.
// Called After DetecorConstruction::AddDetector Method
void InitializeRootOutput() ;
// Read sensitive part and fill the Root tree.
// Called at in the EventAction::EndOfEventAvtion
void ReadSensitive(const G4Event* event) ;
////////////////////////////////////////////////////
///////////Event class to store Data////////////////
////////////////////////////////////////////////////
private:
TTiaraBarrelData* m_EventBarrel ;
TTiaraHyballData* m_EventHyball ;
////////////////////////////////////////////////////
///////////////// Scorer Related ///////////////////
////////////////////////////////////////////////////
private:
// Initialize all Scorer
void InitializeScorers() ;
// Scorer Associate to the Silicon
G4MultiFunctionalDetector* m_BOXScorer ;
G4MultiFunctionalDetector* m_PADScorer ;
G4MultiFunctionalDetector* m_QQQScorer ;
private:
// Initialize material used in detector definition
void InitializeMaterial();
// List of material
G4Material* m_MaterialSilicon ;
G4Material* m_MaterialAl ;
G4Material* m_MaterialVacuum ;
G4Material* m_MaterialPCB ;
////////////////////////////////////////////////////
///////////////Private intern Data//////////////////
////////////////////////////////////////////////////
private:
// True if the detector is a Box, false if a quadrant
vector<bool> m_Type ;
// Used for Quadrant detectors
vector<G4ThreeVector> m_Pos ; // R , Phi , Z
vector<G4double> m_ThicknessQQQ;
// Used for Box detectors
vector<G4double> m_Z ;
vector< vector<G4double> > m_ThicknessBOX;
vector< vector<G4double> > m_ThicknessPAD;
// Set to true if you want to see Telescope Frame in your visualisation
bool m_non_sensitive_part_visiualisation ;
private:/// Visualisation Attribute:
// Dark Grey
G4VisAttributes* SiliconVisAtt ;
// Green
G4VisAttributes* PCBVisAtt;
// Gold Yellow
G4VisAttributes* PADVisAtt ;
// Light Grey
G4VisAttributes* FrameVisAtt ;
};
#endif