CMS 3D CMS Logo

/afs/cern.ch/work/a/aaltunda/public/www/CMSSW_5_3_14/src/Alignment/MillePedeAlignmentAlgorithm/interface/MillePedeVariables.h

Go to the documentation of this file.
00001 #ifndef MILLEPEDEVARIABLES_H
00002 #define MILLEPEDEVARIABLES_H
00003 
00016 #include "Alignment/CommonAlignment/interface/AlignmentUserVariables.h"
00017 
00018 #include <vector>
00019 
00020 class MillePedeVariables : public AlignmentUserVariables {
00021  public:
00022   
00024   MillePedeVariables(unsigned int nParams, unsigned int label);
00026   virtual ~MillePedeVariables() {}
00028   virtual MillePedeVariables* clone() const { return new MillePedeVariables(*this);}
00029 
00031   bool setAllDefault(unsigned int nParam);
00033   unsigned int size() const {return myIsValid.size();}
00034 
00036   const std::vector<bool>& isValid() const { return myIsValid;}
00038   std::vector<bool>& isValid() { return myIsValid;}
00039 
00041   const std::vector<float>& diffBefore() const {return myDiffBefore;}
00043   std::vector<float>& diffBefore() {return myDiffBefore;}
00044 
00046   const std::vector<float>& globalCor() const {return myGlobalCor;}
00048   std::vector<float>& globalCor() {return myGlobalCor;}
00049 
00051   const std::vector<float>& preSigma() const {return myPreSigma;}
00053   std::vector<float>& preSigma() {return myPreSigma;}
00054 
00056   const std::vector<float>& sigma() const {return mySigma;}
00058   std::vector<float>& sigma() {return mySigma;}
00059 
00061   const std::vector<float>& parameter() const {return myParameter;}
00063   std::vector<float>& parameter() {return myParameter;}
00064 
00066   unsigned int label() const {return myLabel;}
00068   void setLabel(unsigned int label) { myLabel = label;}
00069 
00071   unsigned int hitsX() const {return myHitsX;}
00073   void increaseHitsX(unsigned int add = 1) { myHitsX += add;}
00074   void setHitsX(unsigned int hitsX) { myHitsX = hitsX;}
00075 
00077   unsigned int hitsY() const {return myHitsY;}
00079   void increaseHitsY(unsigned int add = 1) { myHitsY += add;}
00080   void setHitsY(unsigned int hitsY) { myHitsY = hitsY;}
00081 
00083   bool isFixed(unsigned int nParam) const;
00084 
00085  private:
00086   MillePedeVariables() {} // make unusable default constructor
00087 
00088   std::vector<bool>  myIsValid;
00089   std::vector<float> myDiffBefore;
00090   std::vector<float> myGlobalCor;
00091   std::vector<float> myPreSigma; 
00092   std::vector<float> myParameter;
00093   std::vector<float> mySigma;
00094   unsigned int       myHitsX;
00095   unsigned int       myHitsY;
00096   unsigned int       myLabel;
00097 };
00098 
00099 #endif