11 const std::vector<CSCDetectorHit> &wireHits) {
16 const int nNodes = chamberSpecs->
nNodes();
21 newStripHits.reserve((2 * nNodes + 1) * wireHits.size());
22 std::vector<CSCDetectorHit>::const_iterator wireHitI;
23 for (wireHitI = wireHits.begin(); wireHitI != wireHits.end(); ++wireHitI) {
24 int wire = (*wireHitI).getElement();
25 float wireCharge = (*wireHitI).getCharge();
26 float wireHitTime = (*wireHitI).getTime();
29 float hitX = (*wireHitI).getPosition() *
cos(geom->
wireAngle());
30 float hitY = geom->
yOfWire(wire, hitX);
34 int firstStrip =
std::max(centerStrip - nNodes, 1);
36 for (
int istrip = firstStrip; istrip <= lastStrip; istrip++) {
38 float stripWidth = geom->
stripPitch(wireHitPos);
49 const float igain = 1. / 0.9;
50 float stripCharge = wireCharge * binValue * igain * 0.5;
51 float stripTime = wireHitTime;
53 CSCDetectorHit newStripHit(istrip, stripCharge, position, stripTime, (*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
float xOfStrip(int strip, float y=0.) const
float yOfWire(float wire, float x=0.) const
const CSCChamberSpecs * specs() const
void initChamberSpecs(const CSCChamberSpecs &)
Calculates k1, k2, k3, h per chamber type, if necessary.
Cos< T >::type cos(const T &t)
int nearestStrip(const LocalPoint &lp) const
static int position[264][3]
float stripAngle(int strip) const
const CSCChamber * chamber() const
const CSCLayerGeometry * geometry() const
CSCGattiFunction theGattiFunction