Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-09-07 04:34:33

0001 #ifndef Alignment_MuonAlignmentAlgorithms_CSCChamberFitter_H
0002 #define Alignment_MuonAlignmentAlgorithms_CSCChamberFitter_H
0003 
0004 /** \class CSCChamberFitter
0005  *  $Date: 2010/05/06 05:57:33 $
0006  *  $Revision: 1.2 $
0007  *  \author J. Pivarski - Texas A&M University <pivarski@physics.tamu.edu>
0008  */
0009 
0010 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0011 #include "DataFormats/DetId/interface/DetId.h"
0012 #include "DataFormats/MuonDetId/interface/CSCDetId.h"
0013 #include "DataFormats/CLHEP/interface/AlgebraicObjects.h"
0014 #include "Alignment/CommonAlignment/interface/Alignable.h"
0015 #include "Alignment/CommonAlignment/interface/AlignableNavigator.h"
0016 #include "Alignment/CommonAlignment/interface/AlignableObjectId.h"
0017 #include "Alignment/CommonAlignment/interface/AlignmentParameters.h"
0018 #include "Alignment/CommonAlignmentAlgorithm/interface/AlignmentParameterStore.h"
0019 
0020 #include "Alignment/MuonAlignmentAlgorithms/interface/CSCPairConstraint.h"
0021 #include "Alignment/MuonAlignmentAlgorithms/plugins/CSCPairResidualsConstraint.h"
0022 #include "Alignment/MuonAlignmentAlgorithms/plugins/CSCAlignmentCorrections.h"
0023 
0024 class CSCChamberFitter {
0025 public:
0026   CSCChamberFitter(const edm::ParameterSet &iConfig, std::vector<CSCPairResidualsConstraint *> &residualsConstraints);
0027   virtual ~CSCChamberFitter() {}
0028 
0029   bool fit(std::vector<CSCAlignmentCorrections *> &corrections) const;
0030   void radiusCorrection(AlignableNavigator *alignableNavigator,
0031                         AlignmentParameterStore *alignmentParameterStore,
0032                         bool combineME11) const;
0033 
0034 protected:
0035   int index(std::string alignable) const;
0036   void walk(std::map<int, bool> &touched, int alignable) const;
0037   long alignableId(std::string alignable) const;
0038   bool isFrame(int i) const;
0039   double chi2(const AlgebraicVector &A, double lambda) const;
0040   double lhsVector(int k) const;
0041   double hessian(int k, int l, double lambda) const;
0042 
0043   std::string m_name;
0044   std::vector<std::string> m_alignables;
0045   std::vector<int> m_frames;
0046   int m_fixed;
0047   std::vector<CSCPairConstraint *> m_constraints;
0048 };
0049 
0050 #endif  // Alignment_MuonAlignmentAlgorithms_CSCChamberFitter_H