13 const std::string&
name,
23 std::vector<StgcHitData>& stgcHits,
24 std::vector<MmHitData>& mmHits,
35 ATH_CHECK( outlierMm(muonRoad, trackPattern, mmHits) );
36 ATH_CHECK( outlierStgc(muonRoad, trackPattern, stgcHits) );
41 return StatusCode::SUCCESS;
53 double dz =
x - (
y-bw)*ia;
54 return dz/std::sqrt(1.+iaq);
60 double dphi = std::abs(hitphi - roadphi);
61 if( dphi >
M_PI*2 ) dphi = dphi -
M_PI*2;
62 if( dphi >
M_PI ) dphi =
M_PI*2 - dphi;
75 const double aw = muonRoad.
aw[
chamber][0];
76 const double bw = muonRoad.
bw[
chamber][0];
77 const double roadphi = muonRoad.
phi[
chamber][0];
82 double residualR = -1;
83 double residualPhi = -1;
84 unsigned int i_layer = 999;
87 for(
unsigned int i_hit=0; i_hit<mmHits.size(); i_hit++) {
91 phi = mmHits[i_hit].phi;
92 i_layer = mmHits[i_hit].layerNumber;
93 residualR = calc_residualR(aw,bw,
z,
r);
94 residualPhi = calc_dPhi(phi, roadphi);
95 mmHits[i_hit].ResidualR = residualR;
96 mmHits[i_hit].ResidualPhi = residualPhi;
99 ATH_MSG_DEBUG(
"Mm .../z/r/aw/bw/residualR/residualPhi/rWidth="
100 <<
z <<
"/" <<
r <<
"/" << aw <<
"/" << bw <<
"/" << residualR <<
"/" << residualPhi <<
"/" << rWidth);
102 if( std::abs(residualR) > rWidth ) {
103 mmHits[i_hit].isOutlier = 2;
107 mmSegment.push_back(mmHits[i_hit]);
112 return StatusCode::SUCCESS;
122 const double aw = muonRoad.
aw[
chamber][0];
123 const double bw = muonRoad.
bw[
chamber][0];
124 const double roadphi = muonRoad.
phi[
chamber][0];
129 double residualR = -1;
130 double residualPhi = -1;
131 unsigned int i_layer = 999;
134 int channelType = -1;
136 for(
unsigned int i_hit=0; i_hit<stgcHits.size(); i_hit++) {
138 z = stgcHits[i_hit].z;
139 r = stgcHits[i_hit].r;
140 phi = stgcHits[i_hit].phi;
141 i_layer = stgcHits[i_hit].layerNumber;
142 channelType = stgcHits[i_hit].channelType;
144 residualR = calc_residualR(aw,bw,
z,
r);
145 residualPhi = calc_dPhi(phi, roadphi);
147 stgcHits[i_hit].ResidualR = residualR;
148 stgcHits[i_hit].ResidualPhi = residualPhi;
153 ATH_MSG_DEBUG(
"Stgc pad .../z/r/aw/bw/residualR/residualPhi/rWidth="
154 <<
z <<
"/" <<
r <<
"/" << aw <<
"/" << bw <<
"/" << residualR <<
"/" << residualPhi <<
"/" << rWidth);
157 if( std::abs(residualPhi) >
phiWidth ) {
158 stgcHits[i_hit].isOutlier = 3;
161 if( std::abs(residualR) > rWidth ) {
162 stgcHits[i_hit].isOutlier = 2;
167 else if(channelType==1) {
170 ATH_MSG_DEBUG(
"Stgc strip .../z/r/aw/bw/residualR/residualPhi/rWidth="
171 <<
z <<
"/" <<
r <<
"/" << aw <<
"/" << bw <<
"/" << residualR <<
"/" << residualPhi <<
"/" << rWidth);
173 if( std::abs(residualR) > rWidth ) {
174 stgcHits[i_hit].isOutlier = 2;
179 else if(channelType==2) {
180 ATH_MSG_DEBUG(
"Stgc wire .../z/r/aw/bw/residualR/residualPhi/rWidth="
181 <<
z <<
"/" <<
r <<
"/" << aw <<
"/" << bw <<
"/" << residualR <<
"/" << residualPhi <<
"/" << rWidth);
183 if( std::abs(residualPhi) >
phiWidth ) {
184 stgcHits[i_hit].isOutlier = 3;
191 stgcSegment.push_back(stgcHits[i_hit]);
196 return StatusCode::SUCCESS;