CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
CSCChamberSpecs.h
Go to the documentation of this file.
1 #ifndef Geometry_CSCGeometry_CSCChamberSpecs_H
2 #define Geometry_CSCGeometry_CSCChamberSpecs_H
3 
28 
29 #include <cmath>
30 #include <string>
31 #include <vector>
32 
33 class CSCGeometry;
34 class CSCLayerGeometry;
36 class Topology; //@@ Can go once GeomDetType has it removed.
38 
39 class CSCChamberSpecs : public GeomDetType {
40 
41 public:
42 
43  typedef std::vector<float> CSCSpecsParcel;
44 
47 
49  CSCChamberSpecs( const CSCGeometry* geom, int iChamberType ,
50  const TrapezoidalPlaneBounds& mediaShape,
51  const CSCSpecsParcel& fupar,
52  const CSCWireGroupPackage& wg
53  );
54 
57 
59  bool operator!=( const CSCChamberSpecs& specs ) const;
60  bool operator==( const CSCChamberSpecs& specs ) const;
61 
62  //@@ Topology() will be removed from GeomDetType interface (good, so we're no longer forced to pick something)
63  //@@ But still there as of Aug-2007. So much for design.
64 
66  virtual const Topology& topology() const;
67 
69  const CSCLayerGeometry* oddLayerGeometry( int iendcap ) const
70  { return (iendcap==1? poszOddLayerGeometry:negzOddLayerGeometry);}
71  const CSCLayerGeometry* evenLayerGeometry( int iendcap ) const
72  { return (iendcap==1? poszEvenLayerGeometry:negzEvenLayerGeometry);}
73 
84  int chamberType() const;
85 
90  std::string chamberTypeName() const;
91 
92 
93  // CHAMBER 'PARAMETER' FUNCTIONS
94  //@@ FIXME these must all be sorted out in a world of real conditions & calibration
95 
96  float stripResolution() const {return specsValue(0);}
97  float wireResolution() const {return specsValue(1);}
98  float efficiency() const {return specsValue(2);}
99  float timeWindow() const {return specsValue(3);}
100 
104  float neutronRate() const {return specsValue(4);}
105 
109  int nStrips() const {return nstrips;}
110 
114  int nNodes() const {return int( specsValue(6) );}
115  int nWiresPerGroup() const {return int( specsValue(7) );}
116  int nFloatingStrips() const {return int( specsValue(8) );}
117 
121  float stripPhiPitch() const {return 1.E-03 * stripDeltaPhi;}
122 
127  float ctiOffset() const {return centreToIntersectionOffset;}
128 
132  float wireSpacing() const;
133 
137  float anodeCathodeSpacing() const {return specsValue(9);}
138 
139  float gasGain() const;
140 
141  float voltage() const {return specsValue(11);}
142 
143  float calibrationError() const {return specsValue(13);}
144 
145  float electronAttraction() const {return specsValue(14);}
146 
150  float fractionQS() const {return specsValue(15);}
151 
155  float chargePerCount() const;
156 
160  float wireRadius() const {return specsValue(17);}
161 
165  float shaperPeakingTime() const {return specsValue(18);}
166 
170  float constantNoise() const {return specsValue(22);}
171 
175  float e_pF() const {return specsValue(23);}
176 
182  //@@ Why 1/sqrt(time)?!?
183  float wireNoise(float timeInterval) const {
184  const float WIRE_CAPACITANCE = 8.; // in pF
185  return (constantNoise() + nWiresPerGroup()*WIRE_CAPACITANCE)
186  / sqrt(timeInterval/100.);
187  }
188 
189  float stripNoise(float timeInterval) const;
190 
191  //@@ The following is nonsense to be fixed at some stage
192  // float adcThreshold() const {return 9.99;}
193 
194 
195  // STATIC FUNCTION
196 
200  static int whatChamberType( int istation, int iring );
201 
202  private:
203 
205  float specsValue( int index ) const {
206  return theSpecsValues[ index ];
207  }
208 
209  // A ChamberSpecs has 4 associated LayerGeometry's
214 
215  // theChamberType is a unique integer 1-10 for a station, ring pair.
216 
217  // The type value is defined as <br>
218  // 1 for S = 1 and R=A=4 split strips in ME11 <br>
219  // 2,3,4 = R+1 for S = 1 and R = 1,2,3 <br>
220  // 5-10 = 2*S+R for S = 2,3,4 and R = 1,2 <br>
221 
223 
224  // Careful that the following order of data members is required to ensure
225  // correct initialization in constructor initialization list!
226 
227  // Store for specs parameter values
229 
230  int nstrips; // no. of strips per layer
231  float stripDeltaPhi; // Delta-phi width of strip in this chamber type (in mrad)
232  float centreToIntersectionOffset; // Possible correction to whereStripsMeet
233 
234  // Names of chamber types
235  static const std::string theName[10];
236 
237  // Name of this class
238  static const std::string myName;
239 
240 };
241 
242 #endif // Geometry_CSCGeometry_CSCChamberSpecs_H
int nStrips() const
CSCLayerGeometry * poszOddLayerGeometry
float timeWindow() const
float fractionQS() const
int nFloatingStrips() const
bool operator!=(const CSCChamberSpecs &specs) const
Allow comparison of Specs objects.
CSCLayerGeometry * negzOddLayerGeometry
static int whatChamberType(int istation, int iring)
int nWiresPerGroup() const
float voltage() const
float e_pF() const
float chargePerCount() const
float neutronRate() const
float wireRadius() const
float centreToIntersectionOffset
std::string chamberTypeName() const
float calibrationError() const
float stripPhiPitch() const
int nNodes() const
float wireNoise(float timeInterval) const
T sqrt(T t)
Definition: SSEVec.h:46
CSCLayerGeometry * negzEvenLayerGeometry
bool operator==(const CSCChamberSpecs &specs) const
const CSCLayerGeometry * evenLayerGeometry(int iendcap) const
float stripResolution() const
static const std::string myName
~CSCChamberSpecs()
Destructor.
float specsValue(int index) const
Accessor to chamber specs values.
float wireSpacing() const
virtual const Topology & topology() const
Returns StripTopology of the odd-layer, positive-z geometry.
CSCLayerGeometry * poszEvenLayerGeometry
float shaperPeakingTime() const
int chamberType() const
const CSCLayerGeometry * oddLayerGeometry(int iendcap) const
Accessors for LayerGeometry&#39;s.
float gasGain() const
float efficiency() const
float stripNoise(float timeInterval) const
CSCChamberSpecs()
Default ctor.
float anodeCathodeSpacing() const
std::vector< float > CSCSpecsParcel
CSCSpecsParcel theSpecsValues
float ctiOffset() const
float wireResolution() const
float constantNoise() const
static const std::string theName[10]
float electronAttraction() const