CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_4_1_8_patch9/src/Alignment/CommonAlignmentMonitor/plugins/AlignmentMonitorMuonSystemMap1D.cc

Go to the documentation of this file.
00001 // -*- C++ -*-
00002 //
00003 // Package:     CommonAlignmentProducer
00004 // Class  :     AlignmentMonitorMuonSystemMap1D
00005 // 
00006 // Implementation:
00007 //     <Notes on implementation>
00008 //
00009 // Original Author:  Jim Pivarski
00010 //         Created:  Mon Nov 12 13:30:14 CST 2007
00011 //
00012 
00013 #include "Alignment/CommonAlignmentMonitor/interface/AlignmentMonitorMuonSystemMap1D.h"
00014 
00015 //
00016 // constants, enums and typedefs
00017 //
00018 
00019 //
00020 // static data member definitions
00021 //
00022 
00023 //
00024 // member functions
00025 //
00026 
00027 AlignmentMonitorMuonSystemMap1D::AlignmentMonitorMuonSystemMap1D(const edm::ParameterSet& cfg)
00028    : AlignmentMonitorBase(cfg, "AlignmentMonitorMuonSystemMap1D")
00029    , m_minTrackPt(cfg.getParameter<double>("minTrackPt"))
00030    , m_maxTrackPt(cfg.getParameter<double>("maxTrackPt"))
00031    , m_minTrackerHits(cfg.getParameter<int>("minTrackerHits"))
00032    , m_maxTrackerRedChi2(cfg.getParameter<double>("maxTrackerRedChi2"))
00033    , m_allowTIDTEC(cfg.getParameter<bool>("allowTIDTEC"))
00034    , m_minDT13Hits(cfg.getParameter<int>("minDT13Hits"))
00035    , m_minDT2Hits(cfg.getParameter<int>("minDT2Hits"))
00036    , m_minCSCHits(cfg.getParameter<int>("minCSCHits"))
00037 {}
00038 
00039 std::string AlignmentMonitorMuonSystemMap1D::num02d(int num) {
00040   int tens = num / 10;
00041   int ones = num % 10;
00042   
00043   std::string s_tens, s_ones;
00044   if (tens == 0) s_tens = std::string("0");
00045   if (tens == 1) s_tens = std::string("1");
00046   if (tens == 2) s_tens = std::string("2");
00047   if (tens == 3) s_tens = std::string("3");
00048   if (tens == 4) s_tens = std::string("4");
00049   if (tens == 5) s_tens = std::string("5");
00050   if (tens == 6) s_tens = std::string("6");
00051   if (tens == 7) s_tens = std::string("7");
00052   if (tens == 8) s_tens = std::string("8");
00053   if (tens == 9) s_tens = std::string("9");
00054 
00055   if (ones == 0) s_ones = std::string("0");
00056   if (ones == 1) s_ones = std::string("1");
00057   if (ones == 2) s_ones = std::string("2");
00058   if (ones == 3) s_ones = std::string("3");
00059   if (ones == 4) s_ones = std::string("4");
00060   if (ones == 5) s_ones = std::string("5");
00061   if (ones == 6) s_ones = std::string("6");
00062   if (ones == 7) s_ones = std::string("7");
00063   if (ones == 8) s_ones = std::string("8");
00064   if (ones == 9) s_ones = std::string("9");
00065 
00066   return s_tens + s_ones;
00067 }
00068 
00069 void AlignmentMonitorMuonSystemMap1D::book() {
00070   for (int sector = 1;  sector <= 14;  sector++) {
00071     if (sector <= 12) {
00072       m_DTvsz_station1[sector-1] = new MuonSystemMapPlot1D(std::string("DTvsz_st1sec") + num02d(sector), this, 60, -660., 660., true);  m_plots.push_back(m_DTvsz_station1[sector-1]);
00073       m_DTvsz_station2[sector-1] = new MuonSystemMapPlot1D(std::string("DTvsz_st2sec") + num02d(sector), this, 60, -660., 660., true);  m_plots.push_back(m_DTvsz_station2[sector-1]);
00074       m_DTvsz_station3[sector-1] = new MuonSystemMapPlot1D(std::string("DTvsz_st3sec") + num02d(sector), this, 60, -660., 660., true);  m_plots.push_back(m_DTvsz_station3[sector-1]);
00075     }
00076     m_DTvsz_station4[sector-1] = new MuonSystemMapPlot1D(std::string("DTvsz_st4sec") + num02d(sector), this, 60, -660., 660., false);  m_plots.push_back(m_DTvsz_station4[sector-1]);
00077   }
00078 
00079   for (int endcap = 1;  endcap <= 2;  endcap++) {
00080     for (int chamber = 1;  chamber <= 36;  chamber++) {
00081       m_CSCvsr_me1[endcap-1][chamber-1] = new MuonSystemMapPlot1D(std::string("CSCvsr_me") + (endcap == 1 ? std::string("p") : std::string("m")) + std::string("1ch") + num02d(chamber), this, 60, 100., 700., false);  m_plots.push_back(m_CSCvsr_me1[endcap-1][chamber-1]);
00082       m_CSCvsr_me2[endcap-1][chamber-1] = new MuonSystemMapPlot1D(std::string("CSCvsr_me") + (endcap == 1 ? std::string("p") : std::string("m")) + std::string("2ch") + num02d(chamber), this, 60, 100., 700., false);  m_plots.push_back(m_CSCvsr_me2[endcap-1][chamber-1]);
00083       m_CSCvsr_me3[endcap-1][chamber-1] = new MuonSystemMapPlot1D(std::string("CSCvsr_me") + (endcap == 1 ? std::string("p") : std::string("m")) + std::string("3ch") + num02d(chamber), this, 60, 100., 700., false);  m_plots.push_back(m_CSCvsr_me3[endcap-1][chamber-1]);
00084       m_CSCvsr_me4[endcap-1][chamber-1] = new MuonSystemMapPlot1D(std::string("CSCvsr_me") + (endcap == 1 ? std::string("p") : std::string("m")) + std::string("4ch") + num02d(chamber), this, 60, 100., 700., false);  m_plots.push_back(m_CSCvsr_me4[endcap-1][chamber-1]);
00085     }
00086   }
00087 
00088   for (int wheel = -2;  wheel <= 2;  wheel++) {
00089     std::string s_wheel;
00090     if (wheel == -2)      s_wheel = std::string("A");
00091     else if (wheel == -1) s_wheel = std::string("B");
00092     else if (wheel == 0)  s_wheel = std::string("C");
00093     else if (wheel == +1) s_wheel = std::string("D");
00094     else if (wheel == +2) s_wheel = std::string("E");
00095 
00096     m_DTvsphi_station1[wheel+2] = new MuonSystemMapPlot1D(std::string("DTvsphi_st1wh") + s_wheel, this, 180, -M_PI, M_PI, true);  m_plots.push_back(m_DTvsphi_station1[wheel+2]);
00097     m_DTvsphi_station2[wheel+2] = new MuonSystemMapPlot1D(std::string("DTvsphi_st2wh") + s_wheel, this, 180, -M_PI, M_PI, true);  m_plots.push_back(m_DTvsphi_station2[wheel+2]);
00098     m_DTvsphi_station3[wheel+2] = new MuonSystemMapPlot1D(std::string("DTvsphi_st3wh") + s_wheel, this, 180, -M_PI, M_PI, true);  m_plots.push_back(m_DTvsphi_station3[wheel+2]);
00099     m_DTvsphi_station4[wheel+2] = new MuonSystemMapPlot1D(std::string("DTvsphi_st4wh") + s_wheel, this, 180, -M_PI, M_PI, false);  m_plots.push_back(m_DTvsphi_station4[wheel+2]);
00100   }
00101 
00102   for (int endcap = 1;  endcap <= 2;  endcap++) {
00103     m_CSCvsphi_me11[endcap-1] = new MuonSystemMapPlot1D(std::string("CSCvsphi_me") + (endcap == 1 ? std::string("p") : std::string("m")) + std::string("11"), this, 180, -M_PI, M_PI, false);  m_plots.push_back(m_CSCvsphi_me11[endcap-1]);
00104     m_CSCvsphi_me12[endcap-1] = new MuonSystemMapPlot1D(std::string("CSCvsphi_me") + (endcap == 1 ? std::string("p") : std::string("m")) + std::string("12"), this, 180, -M_PI, M_PI, false);  m_plots.push_back(m_CSCvsphi_me12[endcap-1]);
00105     m_CSCvsphi_me13[endcap-1] = new MuonSystemMapPlot1D(std::string("CSCvsphi_me") + (endcap == 1 ? std::string("p") : std::string("m")) + std::string("13"), this, 180, -M_PI, M_PI, false);  m_plots.push_back(m_CSCvsphi_me13[endcap-1]);
00106     m_CSCvsphi_me14[endcap-1] = new MuonSystemMapPlot1D(std::string("CSCvsphi_me") + (endcap == 1 ? std::string("p") : std::string("m")) + std::string("14"), this, 180, -M_PI, M_PI, false);  m_plots.push_back(m_CSCvsphi_me14[endcap-1]);
00107     m_CSCvsphi_me21[endcap-1] = new MuonSystemMapPlot1D(std::string("CSCvsphi_me") + (endcap == 1 ? std::string("p") : std::string("m")) + std::string("21"), this, 180, -M_PI, M_PI, false);  m_plots.push_back(m_CSCvsphi_me21[endcap-1]);
00108     m_CSCvsphi_me22[endcap-1] = new MuonSystemMapPlot1D(std::string("CSCvsphi_me") + (endcap == 1 ? std::string("p") : std::string("m")) + std::string("22"), this, 180, -M_PI, M_PI, false);  m_plots.push_back(m_CSCvsphi_me22[endcap-1]);
00109     m_CSCvsphi_me31[endcap-1] = new MuonSystemMapPlot1D(std::string("CSCvsphi_me") + (endcap == 1 ? std::string("p") : std::string("m")) + std::string("31"), this, 180, -M_PI, M_PI, false);  m_plots.push_back(m_CSCvsphi_me31[endcap-1]);
00110     m_CSCvsphi_me32[endcap-1] = new MuonSystemMapPlot1D(std::string("CSCvsphi_me") + (endcap == 1 ? std::string("p") : std::string("m")) + std::string("32"), this, 180, -M_PI, M_PI, false);  m_plots.push_back(m_CSCvsphi_me32[endcap-1]);
00111     m_CSCvsphi_me41[endcap-1] = new MuonSystemMapPlot1D(std::string("CSCvsphi_me") + (endcap == 1 ? std::string("p") : std::string("m")) + std::string("41"), this, 180, -M_PI, M_PI, false);  m_plots.push_back(m_CSCvsphi_me41[endcap-1]);
00112     m_CSCvsphi_me42[endcap-1] = new MuonSystemMapPlot1D(std::string("CSCvsphi_me") + (endcap == 1 ? std::string("p") : std::string("m")) + std::string("42"), this, 180, -M_PI, M_PI, false);  m_plots.push_back(m_CSCvsphi_me42[endcap-1]);
00113   }
00114 
00115   m_counter_event = 0;
00116   m_counter_track = 0;
00117   m_counter_trackpt = 0;
00118   m_counter_trackokay = 0;
00119   m_counter_dt = 0;
00120   m_counter_13numhits = 0;
00121   m_counter_2numhits = 0;
00122   m_counter_csc = 0;
00123   m_counter_cscnumhits = 0;
00124 }
00125 
00126 void AlignmentMonitorMuonSystemMap1D::event(const edm::Event &iEvent, const edm::EventSetup &iSetup, const ConstTrajTrackPairCollection& trajtracks) {
00127    m_counter_event++;
00128 
00129   edm::ESHandle<GlobalTrackingGeometry> globalGeometry;
00130   iSetup.get<GlobalTrackingGeometryRecord>().get(globalGeometry);
00131 
00132   for (ConstTrajTrackPairCollection::const_iterator trajtrack = trajtracks.begin();  trajtrack != trajtracks.end();  ++trajtrack) {
00133     const Trajectory* traj = (*trajtrack).first;
00134     const reco::Track* track = (*trajtrack).second;
00135 
00136     m_counter_track++;
00137 
00138     if (m_minTrackPt < track->pt()  &&  track->pt() < m_maxTrackPt) {
00139       char charge = (track->charge() > 0 ? 1 : -1);
00140       // double qoverpt = track->charge() / track->pt();
00141       // double qoverpz = track->charge() / track->pz();
00142       MuonResidualsFromTrack muonResidualsFromTrack(globalGeometry, traj, pNavigator(), 1000.);
00143 
00144       m_counter_trackpt++;
00145 
00146       if (muonResidualsFromTrack.trackerNumHits() >= m_minTrackerHits  &&  muonResidualsFromTrack.trackerRedChi2() < m_maxTrackerRedChi2  &&  (m_allowTIDTEC  ||  !muonResidualsFromTrack.contains_TIDTEC())) {
00147         std::vector<DetId> chamberIds = muonResidualsFromTrack.chamberIds();
00148 
00149         m_counter_trackokay++;
00150 
00151         for (std::vector<DetId>::const_iterator chamberId = chamberIds.begin();  chamberId != chamberIds.end();  ++chamberId) {
00152 
00153           if (chamberId->det() == DetId::Muon  &&  chamberId->subdetId() == MuonSubdetId::DT) {
00154             MuonChamberResidual *dt13 = muonResidualsFromTrack.chamberResidual(*chamberId, MuonChamberResidual::kDT13);
00155             MuonChamberResidual *dt2 = muonResidualsFromTrack.chamberResidual(*chamberId, MuonChamberResidual::kDT2);
00156             DTChamberId id(chamberId->rawId());
00157 
00158             m_counter_dt++;
00159 
00160             if (dt13 != NULL  &&  dt13->numHits() >= m_minDT13Hits) {
00161                m_counter_13numhits++;
00162 
00163               double residual = dt13->global_residual();
00164               double resslope = dt13->global_resslope();
00165               double chi2 = dt13->chi2();
00166               int dof = dt13->ndof();
00167 
00168               GlobalPoint trackpos = dt13->global_trackpos();
00169               double phi = atan2(trackpos.y(), trackpos.x());
00170               double z = trackpos.z();
00171 
00172               assert(1 <= id.sector()  &&  id.sector() <= 14);
00173 
00174               if (id.station() == 1) m_DTvsz_station1[id.sector()-1]->fill_x(charge, z, residual, chi2, dof);
00175               if (id.station() == 2) m_DTvsz_station2[id.sector()-1]->fill_x(charge, z, residual, chi2, dof);
00176               if (id.station() == 3) m_DTvsz_station3[id.sector()-1]->fill_x(charge, z, residual, chi2, dof);
00177               if (id.station() == 4) m_DTvsz_station4[id.sector()-1]->fill_x(charge, z, residual, chi2, dof);
00178 
00179               if (id.station() == 1) m_DTvsz_station1[id.sector()-1]->fill_dxdz(charge, z, resslope, chi2, dof);
00180               if (id.station() == 2) m_DTvsz_station2[id.sector()-1]->fill_dxdz(charge, z, resslope, chi2, dof);
00181               if (id.station() == 3) m_DTvsz_station3[id.sector()-1]->fill_dxdz(charge, z, resslope, chi2, dof);
00182               if (id.station() == 4) m_DTvsz_station4[id.sector()-1]->fill_dxdz(charge, z, resslope, chi2, dof);
00183 
00184               if (id.station() == 1) m_DTvsphi_station1[id.wheel()+2]->fill_x(charge, phi, residual, chi2, dof);
00185               if (id.station() == 2) m_DTvsphi_station2[id.wheel()+2]->fill_x(charge, phi, residual, chi2, dof);
00186               if (id.station() == 3) m_DTvsphi_station3[id.wheel()+2]->fill_x(charge, phi, residual, chi2, dof);
00187               if (id.station() == 4) m_DTvsphi_station4[id.wheel()+2]->fill_x(charge, phi, residual, chi2, dof);
00188 
00189               if (id.station() == 1) m_DTvsphi_station1[id.wheel()+2]->fill_dxdz(charge, phi, resslope, chi2, dof);
00190               if (id.station() == 2) m_DTvsphi_station2[id.wheel()+2]->fill_dxdz(charge, phi, resslope, chi2, dof);
00191               if (id.station() == 3) m_DTvsphi_station3[id.wheel()+2]->fill_dxdz(charge, phi, resslope, chi2, dof);
00192               if (id.station() == 4) m_DTvsphi_station4[id.wheel()+2]->fill_dxdz(charge, phi, resslope, chi2, dof);
00193             }
00194 
00195             if (dt2 != NULL  &&  dt2->numHits() >= m_minDT2Hits) {
00196                m_counter_2numhits++;
00197 
00198               double residual = dt2->global_residual();
00199               double resslope = dt2->global_resslope();
00200               double chi2 = dt2->chi2();
00201               int dof = dt2->ndof();
00202 
00203               GlobalPoint trackpos = dt2->global_trackpos();
00204               double phi = atan2(trackpos.y(), trackpos.x());
00205               double z = trackpos.z();
00206 
00207               assert(1 <= id.sector()  &&  id.sector() <= 14);
00208 
00209               if (id.station() == 1) m_DTvsz_station1[id.sector()-1]->fill_y(charge, z, residual, chi2, dof);
00210               if (id.station() == 2) m_DTvsz_station2[id.sector()-1]->fill_y(charge, z, residual, chi2, dof);
00211               if (id.station() == 3) m_DTvsz_station3[id.sector()-1]->fill_y(charge, z, residual, chi2, dof);
00212               if (id.station() == 4) m_DTvsz_station4[id.sector()-1]->fill_y(charge, z, residual, chi2, dof);
00213 
00214               if (id.station() == 1) m_DTvsz_station1[id.sector()-1]->fill_dydz(charge, z, resslope, chi2, dof);
00215               if (id.station() == 2) m_DTvsz_station2[id.sector()-1]->fill_dydz(charge, z, resslope, chi2, dof);
00216               if (id.station() == 3) m_DTvsz_station3[id.sector()-1]->fill_dydz(charge, z, resslope, chi2, dof);
00217               if (id.station() == 4) m_DTvsz_station4[id.sector()-1]->fill_dydz(charge, z, resslope, chi2, dof);
00218 
00219               if (id.station() == 1) m_DTvsphi_station1[id.wheel()+2]->fill_y(charge, phi, residual, chi2, dof);
00220               if (id.station() == 2) m_DTvsphi_station2[id.wheel()+2]->fill_y(charge, phi, residual, chi2, dof);
00221               if (id.station() == 3) m_DTvsphi_station3[id.wheel()+2]->fill_y(charge, phi, residual, chi2, dof);
00222               if (id.station() == 4) m_DTvsphi_station4[id.wheel()+2]->fill_y(charge, phi, residual, chi2, dof);
00223 
00224               if (id.station() == 1) m_DTvsphi_station1[id.wheel()+2]->fill_dydz(charge, phi, resslope, chi2, dof);
00225               if (id.station() == 2) m_DTvsphi_station2[id.wheel()+2]->fill_dydz(charge, phi, resslope, chi2, dof);
00226               if (id.station() == 3) m_DTvsphi_station3[id.wheel()+2]->fill_dydz(charge, phi, resslope, chi2, dof);
00227               if (id.station() == 4) m_DTvsphi_station4[id.wheel()+2]->fill_dydz(charge, phi, resslope, chi2, dof);
00228             }
00229           }
00230 
00231           else if (chamberId->det() == DetId::Muon  &&  chamberId->subdetId() == MuonSubdetId::CSC) {
00232             MuonChamberResidual *csc = muonResidualsFromTrack.chamberResidual(*chamberId, MuonChamberResidual::kCSC);
00233             CSCDetId id(chamberId->rawId());
00234 
00235             m_counter_csc++;
00236 
00237             if (csc != NULL  &&  csc->numHits() >= m_minCSCHits) {
00238                m_counter_cscnumhits++;
00239 
00240               double residual = csc->global_residual();
00241               double resslope = csc->global_resslope();
00242               double chi2 = csc->chi2();
00243               int dof = csc->ndof();
00244 
00245               GlobalPoint trackpos = csc->global_trackpos();
00246               double phi = atan2(trackpos.y(), trackpos.x());
00247               double R = sqrt(pow(trackpos.x(), 2) + pow(trackpos.y(), 2));
00248 
00249               int chamber = id.chamber() - 1;
00250               if (id.station() > 1  &&  id.ring() == 1) chamber *= 2;
00251 
00252               assert(1 <= id.endcap()  &&  id.endcap() <= 2  &&  0 <= chamber  &&  chamber <= 35);
00253 
00254               if (id.station() == 1) m_CSCvsr_me1[id.endcap()-1][chamber]->fill_x(charge, R, residual, chi2, dof);
00255               if (id.station() == 2) m_CSCvsr_me2[id.endcap()-1][chamber]->fill_x(charge, R, residual, chi2, dof);
00256               if (id.station() == 3) m_CSCvsr_me3[id.endcap()-1][chamber]->fill_x(charge, R, residual, chi2, dof);
00257               if (id.station() == 4) m_CSCvsr_me4[id.endcap()-1][chamber]->fill_x(charge, R, residual, chi2, dof);
00258 
00259               if (id.station() == 1) m_CSCvsr_me1[id.endcap()-1][chamber]->fill_dxdz(charge, R, resslope, chi2, dof);
00260               if (id.station() == 2) m_CSCvsr_me2[id.endcap()-1][chamber]->fill_dxdz(charge, R, resslope, chi2, dof);
00261               if (id.station() == 3) m_CSCvsr_me3[id.endcap()-1][chamber]->fill_dxdz(charge, R, resslope, chi2, dof);
00262               if (id.station() == 4) m_CSCvsr_me4[id.endcap()-1][chamber]->fill_dxdz(charge, R, resslope, chi2, dof);
00263 
00264               if (id.station() == 1  &&  id.ring() == 1) m_CSCvsphi_me11[id.endcap()-1]->fill_x(charge, phi, residual, chi2, dof);
00265               if (id.station() == 1  &&  id.ring() == 2) m_CSCvsphi_me12[id.endcap()-1]->fill_x(charge, phi, residual, chi2, dof);
00266               if (id.station() == 1  &&  id.ring() == 3) m_CSCvsphi_me13[id.endcap()-1]->fill_x(charge, phi, residual, chi2, dof);
00267               if (id.station() == 1  &&  id.ring() == 4) m_CSCvsphi_me14[id.endcap()-1]->fill_x(charge, phi, residual, chi2, dof);
00268               if (id.station() == 2  &&  id.ring() == 1) m_CSCvsphi_me21[id.endcap()-1]->fill_x(charge, phi, residual, chi2, dof);
00269               if (id.station() == 2  &&  id.ring() == 2) m_CSCvsphi_me22[id.endcap()-1]->fill_x(charge, phi, residual, chi2, dof);
00270               if (id.station() == 3  &&  id.ring() == 1) m_CSCvsphi_me31[id.endcap()-1]->fill_x(charge, phi, residual, chi2, dof);
00271               if (id.station() == 3  &&  id.ring() == 2) m_CSCvsphi_me32[id.endcap()-1]->fill_x(charge, phi, residual, chi2, dof);
00272               if (id.station() == 4  &&  id.ring() == 1) m_CSCvsphi_me41[id.endcap()-1]->fill_x(charge, phi, residual, chi2, dof);
00273               if (id.station() == 4  &&  id.ring() == 2) m_CSCvsphi_me42[id.endcap()-1]->fill_x(charge, phi, residual, chi2, dof);
00274 
00275               if (id.station() == 1  &&  id.ring() == 1) m_CSCvsphi_me11[id.endcap()-1]->fill_dxdz(charge, phi, resslope, chi2, dof);
00276               if (id.station() == 1  &&  id.ring() == 2) m_CSCvsphi_me12[id.endcap()-1]->fill_dxdz(charge, phi, resslope, chi2, dof);
00277               if (id.station() == 1  &&  id.ring() == 3) m_CSCvsphi_me13[id.endcap()-1]->fill_dxdz(charge, phi, resslope, chi2, dof);
00278               if (id.station() == 1  &&  id.ring() == 4) m_CSCvsphi_me14[id.endcap()-1]->fill_dxdz(charge, phi, resslope, chi2, dof);
00279               if (id.station() == 2  &&  id.ring() == 1) m_CSCvsphi_me21[id.endcap()-1]->fill_dxdz(charge, phi, resslope, chi2, dof);
00280               if (id.station() == 2  &&  id.ring() == 2) m_CSCvsphi_me22[id.endcap()-1]->fill_dxdz(charge, phi, resslope, chi2, dof);
00281               if (id.station() == 3  &&  id.ring() == 1) m_CSCvsphi_me31[id.endcap()-1]->fill_dxdz(charge, phi, resslope, chi2, dof);
00282               if (id.station() == 3  &&  id.ring() == 2) m_CSCvsphi_me32[id.endcap()-1]->fill_dxdz(charge, phi, resslope, chi2, dof);
00283               if (id.station() == 4  &&  id.ring() == 1) m_CSCvsphi_me41[id.endcap()-1]->fill_dxdz(charge, phi, resslope, chi2, dof);
00284               if (id.station() == 4  &&  id.ring() == 2) m_CSCvsphi_me42[id.endcap()-1]->fill_dxdz(charge, phi, resslope, chi2, dof);
00285             }
00286           }
00287 
00288           else { assert(false); }
00289 
00290         } // end loop over chambers
00291       } // end if track has enough tracker hits
00292     } // end if track has acceptable momentum
00293   } // end loop over tracks
00294 }
00295 
00296 void AlignmentMonitorMuonSystemMap1D::afterAlignment(const edm::EventSetup &iSetup) {
00297    std::cout << "monitor m_counter_event = " << m_counter_event << std::endl;
00298    std::cout << "monitor m_counter_track = " << m_counter_track << std::endl;
00299    std::cout << "monitor m_counter_trackpt = " << m_counter_trackpt << std::endl;
00300    std::cout << "monitor m_counter_trackokay = " << m_counter_trackokay << std::endl;
00301    std::cout << "monitor m_counter_dt = " << m_counter_dt << std::endl;
00302    std::cout << "monitor m_counter_13numhits = " << m_counter_13numhits << std::endl;
00303    std::cout << "monitor m_counter_2numhits = " << m_counter_2numhits << std::endl;
00304    std::cout << "monitor m_counter_csc = " << m_counter_csc << std::endl;
00305    std::cout << "monitor m_counter_cscnumhits = " << m_counter_cscnumhits << std::endl;
00306 }
00307 
00308 //
00309 // constructors and destructor
00310 //
00311 
00312 // AlignmentMonitorMuonSystemMap1D::AlignmentMonitorMuonSystemMap1D(const AlignmentMonitorMuonSystemMap1D& rhs)
00313 // {
00314 //    // do actual copying here;
00315 // }
00316 
00317 //
00318 // assignment operators
00319 //
00320 // const AlignmentMonitorMuonSystemMap1D& AlignmentMonitorMuonSystemMap1D::operator=(const AlignmentMonitorMuonSystemMap1D& rhs)
00321 // {
00322 //   //An exception safe implementation is
00323 //   AlignmentMonitorMuonSystemMap1D temp(rhs);
00324 //   swap(rhs);
00325 //
00326 //   return *this;
00327 // }
00328 
00329 //
00330 // const member functions
00331 //
00332 
00333 //
00334 // static member functions
00335 //
00336 
00337 //
00338 // SEAL definitions
00339 //
00340 
00341 DEFINE_EDM_PLUGIN(AlignmentMonitorPluginFactory, AlignmentMonitorMuonSystemMap1D, "AlignmentMonitorMuonSystemMap1D");