11 std::vector<CSCDetectorHit> &
13 const std::vector<CSCDetectorHit> & wireHits)
19 const int nNodes = chamberSpecs->
nNodes();
25 std::vector<CSCDetectorHit>::const_iterator wireHitI;
26 for(wireHitI = wireHits.begin(); wireHitI != wireHits.end(); ++wireHitI){
27 int wire = (*wireHitI).getElement();
28 float wireCharge = (*wireHitI).getCharge();
29 float wireHitTime = (*wireHitI).getTime();
32 float hitX = (*wireHitI).getPosition() *
cos(geom->
wireAngle());
33 float hitY = geom->
yOfWire(wire, hitX);
37 int firstStrip =
std::max(centerStrip - nNodes, 1);
39 for(
int istrip = firstStrip; istrip <= lastStrip; istrip++) {
41 float stripWidth = geom->
stripPitch(wireHitPos);
52 const float igain = 1./0.9;
53 float stripCharge = wireCharge * binValue * igain * 0.5;
54 float stripTime = wireHitTime;
56 CSCDetectorHit newStripHit(istrip, stripCharge, position, stripTime,
57 (*wireHitI).getSimHit());
std::vector< CSCDetectorHit > & simulate(const CSCLayer *layer, const std::vector< CSCDetectorHit > &wireHits)
double binValue(double x, double stripWidth) const
Sin< T >::type sin(const T &t)
std::vector< CSCDetectorHit > newStripHits
int numberOfStrips() const
static int position[TOTALCHAMBERS][3]
float xOfStrip(int strip, float y=0.) const
float yOfWire(float wire, float x=0.) const
const CSCChamberSpecs * specs() const
const T & max(const T &a, const T &b)
void initChamberSpecs(const CSCChamberSpecs &)
Calculates k1, k2, k3, h per chamber type, if necessary.
Cos< T >::type cos(const T &t)
unsigned int offset(bool)
int nearestStrip(const LocalPoint &lp) const
float stripAngle(int strip) const
const CSCChamber * chamber() const
const CSCLayerGeometry * geometry() const
CSCGattiFunction theGattiFunction