]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Coding conventions fixed
authorshahoian <shahoian@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sun, 29 Jan 2012 17:56:54 +0000 (17:56 +0000)
committershahoian <shahoian@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sun, 29 Jan 2012 17:56:54 +0000 (17:56 +0000)
28 files changed:
STEER/ESD/AliESDv0.cxx
STEER/STEER/AliGRPManager.cxx
STEER/STEER/AliGRPManager.h
STEER/STEER/AliGRPRecoParam.h
STEER/STEER/AliLHCData.cxx
STEER/STEER/AliLHCData.h
STEER/STEER/AliMatrixSparse.cxx
STEER/STEER/AliMatrixSparse.h
STEER/STEER/AliMatrixSq.cxx
STEER/STEER/AliMatrixSq.h
STEER/STEER/AliMillePede2.cxx
STEER/STEER/AliMillePede2.h
STEER/STEER/AliMillePedeRecord.cxx
STEER/STEER/AliParamSolver.cxx
STEER/STEER/AliParamSolver.h
STEER/STEER/AliQAChecker.h
STEER/STEER/AliRectMatrix.cxx
STEER/STEER/AliRectMatrix.h
STEER/STEER/AliSymMatrix.cxx
STEER/STEER/AliSymMatrix.h
STEER/STEER/AliTrackFitter.cxx
STEER/STEER/AliTrackFitter.h
STEER/STEER/AliVectorSparse.cxx
STEER/STEER/AliVectorSparse.h
STEER/STEERBase/AliMagF.cxx
STEER/STEERBase/AliMagWrapCheb.cxx
STEER/STEERBase/AliMagWrapCheb.h
STEER/STEERBase/AliRefArray.cxx

index 8390b06cbe44c4b463fb4a932c81273a79d6f813..97aa14a9bedabf5446e25183f9ba84a972612f74 100644 (file)
@@ -786,12 +786,12 @@ Double_t AliESDv0::GetKFInfo(UInt_t p1, UInt_t p2, Int_t type) const{
   }
   AliKFParticle kfp1(  *(paramP), spdg[p1] *TMath::Sign(1,p1) );
   AliKFParticle kfp2( *(paramN), spdg[p2] *TMath::Sign(1,p2) );
-  AliKFParticle *V0KF = new AliKFParticle;
-  *(V0KF)+=kfp1;
-  *(V0KF)+=kfp2;
-  if (type==0) return V0KF->GetMass();
-  if (type==1) return V0KF->GetErrMass();
-  if (type==2) return V0KF->GetChi2();
+  AliKFParticle *v0KF = new AliKFParticle;
+  *(v0KF)+=kfp1;
+  *(v0KF)+=kfp2;
+  if (type==0) return v0KF->GetMass();
+  if (type==1) return v0KF->GetErrMass();
+  if (type==2) return v0KF->GetChi2();
   return 0;
 }
 
@@ -822,11 +822,11 @@ Double_t AliESDv0::GetKFInfoScale(UInt_t p1, UInt_t p2, Int_t type, Double_t d1p
   //
   AliKFParticle kfp1( *paramP, spdg[p1] *TMath::Sign(1,p1) );
   AliKFParticle kfp2( *paramN, spdg[p2] *TMath::Sign(1,p2) );
-  AliKFParticle *V0KF = new AliKFParticle;
-  *(V0KF)+=kfp1;
-  *(V0KF)+=kfp2;
-  if (type==0) return V0KF->GetMass();
-  if (type==1) return V0KF->GetErrMass();
-  if (type==2) return V0KF->GetChi2();
+  AliKFParticle *v0KF = new AliKFParticle;
+  *(v0KF)+=kfp1;
+  *(v0KF)+=kfp2;
+  if (type==0) return v0KF->GetMass();
+  if (type==1) return v0KF->GetErrMass();
+  if (type==2) return v0KF->GetChi2();
   return 0;
 }
index 7f6d6cdaa2e0aaff2e3fe427946f183aadb991b3..84458743dac38f17550d870827621091fc15c6f7 100644 (file)
@@ -232,7 +232,7 @@ AliRunInfo* AliGRPManager::GetRunInfo()
 }
 
 //_____________________________________________________________________________
-void AliGRPManager::SetGRPEntry(AliGRPObject* source)
+void AliGRPManager::SetGRPEntry(const AliGRPObject* source)
 {
   // Create a GRP entry from the extrnaly provide GRP object
   // To be used by HLT to create an online GRP instance
index 0f1e7584a6d56163586a1d8f23f67e4c4f140cab..634ad6ad1a063de5064c5c20917c3c78bd5ab17a 100644 (file)
@@ -26,7 +26,7 @@ public:
 
   const AliGRPObject* GetGRPData() const { return fGRPData; }
 
-  void        SetGRPEntry(AliGRPObject* source);
+  void        SetGRPEntry(const AliGRPObject* source);
   Bool_t      ReadGRPEntry();
   Bool_t      SetMagField();
 
index b2a3e93732117fa4185666d04ff767cd06b5904a..30c82f5d0db1b184a32f6b5868af8eb020b2b8cb 100644 (file)
@@ -37,20 +37,8 @@ class AliGRPRecoParam : public AliDetectorRecoParam
     { SetVertexerTracksCuts(1,ncuts,cuts); return; }
   void  SetVertexerV0Cuts(Int_t ncuts,Double_t cuts[7]);
   void  SetVertexerCascadeCuts(Int_t ncuts,Double_t cuts[8]);
-  void  SetVertexerTracksTPCClusterization(Bool_t use, Double_t dzcut, Double_t nsigmazcut){
-    if(use) fVertexerTracksTPCclusterize=1.;
-    else fVertexerTracksTPCclusterize=0.;
-    fVertexerTracksTPCclusterdz=dzcut;
-    fVertexerTracksTPCclusternsigmaz=nsigmazcut;
-  }
-  void  SetVertexerTracksITSClusterization(Bool_t use, Double_t dzcut, Double_t nsigmazcut){
-    if(use) fVertexerTracksITSclusterize=1.;
-    else fVertexerTracksITSclusterize=0.;
-    fVertexerTracksITSclusterdz=dzcut;
-    fVertexerTracksITSclusternsigmaz=nsigmazcut;
-  }
-
-
+  void  SetVertexerTracksTPCClusterization(Bool_t use, Double_t dzcut, Double_t nsigmazcut);
+  void  SetVertexerTracksITSClusterization(Bool_t use, Double_t dzcut, Double_t nsigmazcut);
   Bool_t GetVertexerTracksConstraintITS() const { return fVertexerTracksConstraintITS; }
   Bool_t GetVertexerTracksConstraintTPC() const { return fVertexerTracksConstraintTPC; }
   Int_t GetVertexerTracksNCuts() const { return fVertexerTracksNCuts; }
@@ -157,4 +145,23 @@ class AliGRPRecoParam : public AliDetectorRecoParam
   ClassDef(AliGRPRecoParam,7) // global reco parameters
 };
 
+inline void  AliGRPRecoParam::SetVertexerTracksTPCClusterization(Bool_t use, Double_t dzcut, Double_t nsigmazcut)
+{
+  // set TPC tracks clustering settings
+  if(use) fVertexerTracksTPCclusterize=1.;
+  else fVertexerTracksTPCclusterize=0.;
+  fVertexerTracksTPCclusterdz=dzcut;
+  fVertexerTracksTPCclusternsigmaz=nsigmazcut;
+}
+
+inline  void  AliGRPRecoParam::SetVertexerTracksITSClusterization(Bool_t use, Double_t dzcut, Double_t nsigmazcut)
+{
+  // set ITS tracks clustering settings
+  if(use) fVertexerTracksITSclusterize=1.;
+  else fVertexerTracksITSclusterize=0.;
+  fVertexerTracksITSclusterdz=dzcut;
+  fVertexerTracksITSclusternsigmaz=nsigmazcut;
+}
+
+
 #endif
index db304c9c1cc73d9bb1b01fe64751da4ab2f56405..8c5e79f1ed5617034c5d73d5cf049bb9a077491f 100755 (executable)
@@ -96,14 +96,14 @@ const Char_t* AliLHCData::fgkDCSColJaws[] = {
 \r
 //___________________________________________________________________\r
 AliLHCData::AliLHCData(const TMap* dcsMap, double tmin, double tmax)\r
-  : fTMin(0),fTMax(0),fFillNumber(0),fData(0),fFile2Process(0),fMap2Process(0)\r
+  : fTMin(0),fTMax(0),fFillNumber(0),fData(0),fkFile2Process(0),fkMap2Process(0)\r
 {\r
   FillData(dcsMap,tmin,tmax);\r
 }\r
 \r
 //___________________________________________________________________\r
 AliLHCData::AliLHCData(const Char_t* dcsFile, double tmin, double tmax)\r
-  : fTMin(0),fTMax(0),fFillNumber(0),fData(0),fFile2Process(dcsFile),fMap2Process(0)\r
+  : fTMin(0),fTMax(0),fFillNumber(0),fData(0),fkFile2Process(dcsFile),fkMap2Process(0)\r
 {\r
   FillData(dcsFile,tmin,tmax);\r
 }\r
@@ -113,7 +113,7 @@ Bool_t AliLHCData::FillData(const TMap*   dcsMap,double tmin, double tmax)
 {\r
   // process DCS map and fill all fields. \r
   Clear();\r
-  fMap2Process = dcsMap;\r
+  fkMap2Process = dcsMap;\r
   FillData(tmin,tmax);\r
   return kTRUE;\r
 }\r
@@ -123,7 +123,7 @@ Bool_t AliLHCData::FillData(const Char_t* dcsFile,double tmin, double tmax)
 {\r
   // process DCS file and fill all fields. \r
   Clear();\r
-  fFile2Process = dcsFile;\r
+  fkFile2Process = dcsFile;\r
   FillData(tmin,tmax);\r
   return kTRUE;\r
 }\r
@@ -143,7 +143,7 @@ Bool_t AliLHCData::FillData(double tmin, double tmax)
   int iFirst=0,iLast=0;\r
   TObjArray* arr = GetDCSEntry(fgkDCSNames[kFillNum],iFirst,iLast,fTMin,fTMax);\r
   if (arr) SetFillNumber( ExtractInt( (AliDCSArray*)arr->At(iFirst), 0) );\r
-  if (fFile2Process) delete arr; // array was created on demand\r
+  if (fkFile2Process) delete arr; // array was created on demand\r
   //\r
   for (int ibm=0;ibm<2;ibm++) {\r
     //\r
@@ -228,10 +228,10 @@ TObjArray* AliLHCData::GetDCSEntry(const char* key,int &entry,int &last,double t
   entry = -1;\r
   last = -2;\r
   TObjArray* arr;\r
-  if (fMap2Process) arr = (TObjArray*)fMap2Process->GetValue(key);\r
-  else if (fFile2Process) {\r
+  if (fkMap2Process) arr = (TObjArray*)fkMap2Process->GetValue(key);\r
+  else if (fkFile2Process) {\r
     AliLHCReader rd;\r
-    arr = rd.ReadSingleLHCDP(fFile2Process,key);\r
+    arr = rd.ReadSingleLHCDP(fkFile2Process,key);\r
   }\r
   else {\r
     AliError("Neither DCS map nor DCS filename are set");\r
@@ -240,7 +240,7 @@ TObjArray* AliLHCData::GetDCSEntry(const char* key,int &entry,int &last,double t
   //\r
   if (!arr || !arr->GetEntriesFast()) { \r
     AliWarning(Form("No data for %s",key)); \r
-    if (fMap2Process) delete arr; // created on demand\r
+    if (fkMap2Process) delete arr; // created on demand\r
     return 0;\r
   }\r
   int ntot = arr->GetEntriesFast();\r
@@ -262,7 +262,7 @@ TObjArray* AliLHCData::GetDCSEntry(const char* key,int &entry,int &last,double t
     str += " : ";\r
     str += AliLHCDipValD::TimeAsString(tmax);\r
     AliWarning(Form("All entries for %s are outside the requested range:\n%s",key,str.Data()));\r
-    if (fMap2Process) delete arr; // created on demand\r
+    if (fkMap2Process) delete arr; // created on demand\r
     return 0;\r
   }\r
   if (entry>0) entry--;\r
@@ -381,7 +381,7 @@ Int_t AliLHCData::FillScalarRecord(int refs[2], const char* rec, const char* rec
     // if (last) break;\r
   }\r
   //\r
-  if (fFile2Process) {\r
+  if (fkFile2Process) {\r
     delete arr;\r
     delete arrE;\r
   }\r
@@ -424,7 +424,7 @@ Int_t AliLHCData::FillBunchConfig(int refs[2],const char* rec)
     prevRecI = curValI;\r
   }\r
   //\r
-  if (fFile2Process) delete arr;\r
+  if (fkFile2Process) delete arr;\r
   return refs[kNStor];\r
 }\r
  \r
@@ -458,7 +458,7 @@ Int_t AliLHCData::FillAcqMode(int refs[2],const char* rec)
     prevRecI = curValI;\r
   }\r
   //\r
-  if (fFile2Process) delete arr;\r
+  if (fkFile2Process) delete arr;\r
   return refs[kNStor];\r
 }\r
  \r
@@ -491,7 +491,7 @@ Int_t AliLHCData::FillStringRecord(int refs[2],const char* rec)
     fData.Add(curValS);\r
     refs[kNStor]++;\r
   }\r
-  if (fFile2Process) delete arr;\r
+  if (fkFile2Process) delete arr;\r
   return refs[kNStor];\r
 }\r
 \r
@@ -543,7 +543,7 @@ Int_t AliLHCData::FillBunchInfo(int refs[2],const char* rec, int ibm, Bool_t inR
     fData.Add(curValF);\r
     refs[kNStor]++;\r
   }\r
-  if (fFile2Process) delete arr;\r
+  if (fkFile2Process) delete arr;\r
   return refs[kNStor];\r
   //\r
 }\r
@@ -633,7 +633,7 @@ Int_t AliLHCData::FillBCLuminosities(int refs[2],const char* rec, const char* re
     fData.Add(curValF);\r
     refs[kNStor]++;\r
   }\r
-  if (fFile2Process) {\r
+  if (fkFile2Process) {\r
     delete arr;\r
     delete arrE;\r
   }\r
@@ -841,8 +841,8 @@ void AliLHCData::Clear(const Option_t *)
   fFillNumber = 0;\r
   fTMin = 0;\r
   fTMax = 1e10;\r
-  fFile2Process = 0;\r
-  fMap2Process  = 0;\r
+  fkFile2Process = 0;\r
+  fkMap2Process  = 0;\r
   //\r
   for (int i=2;i--;) {\r
     fRCInjScheme[i] = 0;\r
index 6059bb5c942a7186c5197d62730cad2fdc9c222e..e10fdf3d560ab35f7c511d037ea2ec288269c673 100755 (executable)
@@ -63,7 +63,7 @@ class AliLHCData : public TObject
   //le\r
  public:\r
   //\r
- AliLHCData() : fTMin(0),fTMax(1e10),fFillNumber(0),fData(0),fFile2Process(0),fMap2Process(0) {Clear();}\r
+ AliLHCData() : fTMin(0),fTMax(1e10),fFillNumber(0),fData(0),fkFile2Process(0),fkMap2Process(0) {Clear();}\r
   AliLHCData(const TMap*   dcsMap,  double tmin=0, double tmax=1.e10);\r
   AliLHCData(const Char_t* dcsFile, double tmin=0, double tmax=1.e10);\r
   virtual ~AliLHCData() {}\r
@@ -176,7 +176,7 @@ class AliLHCData : public TObject
   Int_t                 ExtractInt(AliDCSArray* dcsArray,Int_t el)    const;\r
   Double_t              ExtractDouble(AliDCSArray* dcsArray,Int_t el) const;\r
   TString&              ExtractString(AliDCSArray* dcsArray)          const;\r
- AliLHCData(const AliLHCData& src) : TObject(src),fTMin(0),fTMax(0),fFillNumber(0),fData(0),fFile2Process(0),fMap2Process(0) { /*dummy*/ }\r
+ AliLHCData(const AliLHCData& src) : TObject(src),fTMin(0),fTMax(0),fFillNumber(0),fData(0),fkFile2Process(0),fkMap2Process(0) { /*dummy*/ }\r
   AliLHCData& operator=(const AliLHCData& ) { /*dummy*/ return *this;}\r
   Int_t                 TimeDifference(double v1,double v2,double tol=0.9) const;\r
   Bool_t                IzZero(double val, double tol=1e-16)         const {return TMath::Abs(val)<tol;}\r
@@ -224,8 +224,8 @@ class AliLHCData : public TObject
   //\r
  private:\r
   // non-persistent objects used at the filling time\r
-  const Char_t*   fFile2Process;                      //! name of DCS file\r
-  const TMap*     fMap2Process;                       //! DCS map to process \r
+  const Char_t*   fkFile2Process;                      //! name of DCS file\r
+  const TMap*     fkMap2Process;                       //! DCS map to process \r
 \r
   ClassDef(AliLHCData,1)\r
 };\r
index a9be619876136278ef9393ef8bf6511543cd9bb9..1898b80d9b6270ae07f282448f04afb3152308cd 100644 (file)
@@ -6,6 +6,8 @@
 /*                                                                                            */ 
 /* Author: ruben.shahoyan@cern.ch                                                             */
 /*                                                                                            */ 
+/*                                                                                            */ 
+/*                                                                                            */ 
 /**********************************************************************************************/
 
 //___________________________________________________________
@@ -15,6 +17,7 @@ ClassImp(AliMatrixSparse)
 AliMatrixSparse::AliMatrixSparse(Int_t sz)
 : AliMatrixSq(),fVecs(0)
 {
+  // constructor
   fNcols=fNrows=sz;
   //
   fVecs = new AliVectorSparse*[sz];
@@ -25,6 +28,7 @@ AliMatrixSparse::AliMatrixSparse(Int_t sz)
 AliMatrixSparse::AliMatrixSparse(const AliMatrixSparse& src)
   : AliMatrixSq(src),fVecs(0)
 {
+  // copy c-tor
   fVecs = new AliVectorSparse*[src.GetSize()];
   for (int i=GetSize();i--;) fVecs[i] = new AliVectorSparse( *src.GetRow(i));
 }
@@ -32,6 +36,7 @@ AliMatrixSparse::AliMatrixSparse(const AliMatrixSparse& src)
 //___________________________________________________________
 AliVectorSparse* AliMatrixSparse::GetRowAdd(Int_t ir)
 {
+  // get row, add if needed
   if (ir>=fNrows) {
     AliVectorSparse** arrv = new AliVectorSparse*[ir+1];
     for (int i=GetSize();i--;) arrv[i] = fVecs[i];
@@ -47,6 +52,7 @@ AliVectorSparse* AliMatrixSparse::GetRowAdd(Int_t ir)
 //___________________________________________________________
 AliMatrixSparse& AliMatrixSparse::operator=(const AliMatrixSparse& src)
 {
+  // assignment op-r
   if (this == &src) return *this;
   AliMatrixSq::operator=(src);
 
@@ -62,6 +68,7 @@ AliMatrixSparse& AliMatrixSparse::operator=(const AliMatrixSparse& src)
 //___________________________________________________________
 void AliMatrixSparse::Clear(Option_t*) 
 {
+  // clear
   for (int i=fNrows;i--;) delete GetRow(i);
   delete [] fVecs;
   fNcols = fNrows = 0;
@@ -70,6 +77,7 @@ void AliMatrixSparse::Clear(Option_t*)
 //___________________________________________________________
 void AliMatrixSparse::Print(Option_t* opt)  const
 {
+  // print itself
   printf("Sparse Matrix of size %d x %d %s\n",fNrows,fNcols,IsSymmetric() ? " (Symmetric)":"");
   for (int i=0;i<fNrows;i++) {
     AliVectorSparse* row = GetRow(i);
@@ -116,10 +124,10 @@ void AliMatrixSparse::MultiplyByVec(const Double_t* vecIn, Double_t* vecOut) con
 //___________________________________________________________
 void AliMatrixSparse::SortIndices(Bool_t valuesToo)
 {
+  // sort columns in increasing order. Used to fix the matrix after ILUk decompostion
   TStopwatch sw; 
   sw.Start();
   printf("AliMatrixSparse:sort>>\n");
-  // sort columns in increasing order. Used to fix the matrix after ILUk decompostion
   for (int i=GetSize();i--;) GetRow(i)->SortIndices(valuesToo);
   sw.Stop();
   sw.Print();
index 12898b4a4e4951fa2682627356c390a6501d2678..d82161fac619776db6daec49042fa89252485341 100644 (file)
@@ -57,6 +57,7 @@ class AliMatrixSparse : public AliMatrixSq
 //___________________________________________________
 inline void AliMatrixSparse::MultiplyByVec(const TVectorD &vecIn, TVectorD &vecOut) const 
 {
+  // multiplication
   MultiplyByVec((Double_t*)vecIn.GetMatrixArray(),(Double_t*)vecOut.GetMatrixArray());
 }
 
@@ -92,6 +93,7 @@ inline Double_t& AliMatrixSparse::operator()(Int_t row,Int_t col)
 //___________________________________________________
 inline Double_t AliMatrixSparse::DiagElem(Int_t row) const
 {
+  // get diag elem
   AliVectorSparse* rowv = GetRow(row);
   if (!rowv) return 0;
   if (IsSymmetric()) return (rowv->GetNElems()>0 && rowv->GetLastIndex()==row) ? rowv->GetLastElem() : 0.;
@@ -102,6 +104,7 @@ inline Double_t AliMatrixSparse::DiagElem(Int_t row) const
 //___________________________________________________
 inline Double_t &AliMatrixSparse::DiagElem(Int_t row)
 {
+  // get diag elem
   AliVectorSparse* rowv = GetRowAdd(row);
   if (row>=fNcols) fNcols = row+1;
   if (IsSymmetric()) {
index f0be2acb05130a623ce6f8ff883330cd3a22d681..4d2d83eeaaf24093c0b742c1a368d2c7eb4db3c9 100644 (file)
@@ -1,7 +1,12 @@
 /**********************************************************************************************/
-/* Abstract class for matrix used for millepede2 operation.                                   */
+/*                                                                                            */ 
+/* Abstract class for matrix used for                                                         */
+/* millepede2 operation.                                                                      */
+/* Works for expandable square matrices                                                       */ 
+/* of arbitrary dimension                                                                     */
 /* Author: ruben.shahoyan@cern.ch                                                             */
 /*                                                                                            */ 
+/*                                                                                            */ 
 /**********************************************************************************************/
 
 #include <stdlib.h>
index b4b5ae86d30b8937fd5a3f676ccac37e6273797a..b183a355573cee5f117da7a8f7c7d66403d7f9a7 100644 (file)
@@ -1,7 +1,10 @@
 #ifndef ALIMATRIXSQ_H
 #define ALIMATRIXSQ_H
+
 /**********************************************************************************************/
-/* Abstract class for matrix used for millepede2 operation.                                   */
+/*                                                                                            */ 
+/* Abstract class for matrix used for                                                         */
+/* millepede2 operation.                                                                      */
 /* Author: ruben.shahoyan@cern.ch                                                             */
 /*                                                                                            */ 
 /**********************************************************************************************/
index 553c3968db78ac15b819dc1232162589fd2c7d71..f8bedf219a10ee6b56d795e14c6628ad0f3b7b53 100644 (file)
@@ -1,6 +1,8 @@
 /**********************************************************************************************/
 /* General class for alignment with large number of degrees of freedom                        */
 /* Based on the original milliped2 by Volker Blobel                                           */
+/* and AliMillepede class by Javier                                                           */ 
+/* Allows operations with large sparse matrices                                               */ 
 /* http://www.desy.de/~blobel/mptalks.html                                                    */
 /*                                                                                            */ 
 /* Author: ruben.shahoyan@cern.ch                                                             */
@@ -57,7 +59,7 @@ AliMillePede2::AliMillePede2()
   fNLocFits(0),
   fNLocFitsRejected(0),
   fNGloFix(0),
-  fGloSolveStatus(gkFailed),
+  fGloSolveStatus(kFailed),
 //
   fChi2CutFactor(1.),
   fChi2CutRef(1.),
@@ -126,6 +128,7 @@ AliMillePede2::AliMillePede2(const AliMillePede2& src) :
 //_____________________________________________________________________________________________
 AliMillePede2::~AliMillePede2() 
 {
+  // destructor
   CloseDataRecStorage();
   CloseConsRecStorage();
   //
@@ -155,7 +158,7 @@ AliMillePede2::~AliMillePede2()
 //_____________________________________________________________________________________________
 Int_t AliMillePede2::InitMille(int nGlo, int nLoc, int lNStdDev,double lResCut, double lResCutInit)
 {
-  //
+  // init all
   if (nLoc>0)        fNLocPar = nLoc;
   if (nGlo>0)        fNGloPar = nGlo;
   if (lResCutInit>0) fResCutInit = lResCutInit; 
@@ -212,6 +215,7 @@ Int_t AliMillePede2::InitMille(int nGlo, int nLoc, int lNStdDev,double lResCut,
 //_____________________________________________________________________________________________
 Bool_t AliMillePede2::ImposeDataRecFile(const char* fname)
 {
+  // set filename for records
   CloseDataRecStorage();
   SetDataRecFName(fname);
   return InitDataRecStorage(kTRUE); // open in read mode
@@ -220,6 +224,7 @@ Bool_t AliMillePede2::ImposeDataRecFile(const char* fname)
 //_____________________________________________________________________________________________
 Bool_t AliMillePede2::ImposeConsRecFile(const char* fname)
 {
+  // set filename for constraints
   CloseConsRecStorage();
   SetConsRecFName(fname);
   return InitConsRecStorage(kTRUE); // open in read mode
@@ -311,6 +316,7 @@ Bool_t AliMillePede2::InitConsRecStorage(Bool_t read)
 //_____________________________________________________________________________________________
 void AliMillePede2::CloseDataRecStorage()
 {
+  // close records file
   if (fTreeData) {
     if (fDataRecFile && fDataRecFile->IsWritable()) {
       fDataRecFile->cd();
@@ -331,6 +337,7 @@ void AliMillePede2::CloseDataRecStorage()
 //_____________________________________________________________________________________________
 void AliMillePede2::CloseConsRecStorage()
 {
+  // close constraints file
   if (fTreeConstr) {
     if (fConsRecFile->IsWritable()) {
       fConsRecFile->cd();
@@ -366,6 +373,7 @@ Bool_t AliMillePede2::ReadNextRecordConstraint()
 //_____________________________________________________________________________________________
 void AliMillePede2::SetRecordWeight(double wgh)
 {
+  // assign weight
   if (fRecFileStatus<2) InitDataRecStorage(); // create a buffer to store the data
   fRecord->SetWeight(wgh);
 }
@@ -373,6 +381,7 @@ void AliMillePede2::SetRecordWeight(double wgh)
 //_____________________________________________________________________________________________
 void AliMillePede2::SetRecordRun(Int_t run)
 {
+  // assign run
   if (fRecFileStatus<2) InitDataRecStorage(); // create a buffer to store the data
   fRecord->SetRunID(run);
 }
@@ -380,6 +389,7 @@ void AliMillePede2::SetRecordRun(Int_t run)
 //_____________________________________________________________________________________________
 void AliMillePede2::SetLocalEquation(double *dergb, double *derlc, double lMeas, double lSigma)
 {
+  // assing derivs of loc.eq.
   if (fRecFileStatus<2) InitDataRecStorage(); // create a buffer to store the data
   //
   // write data of single measurement
@@ -431,7 +441,7 @@ void AliMillePede2::SetLocalEquation(int *indgb, double *dergb, int ngb, int *in
 
 
 //_____________________________________________________________________________________________
-void AliMillePede2::SetGlobalConstraint(double *dergb, double val, double sigma)
+void AliMillePede2::SetGlobalConstraint(const double *dergb, double val, double sigma)
 {      
   // Define a constraint equation.
   if (!fConsRecFile || !fConsRecFile->IsWritable()) InitConsRecStorage(); // create a buffer to store the data
@@ -448,7 +458,7 @@ void AliMillePede2::SetGlobalConstraint(double *dergb, double val, double sigma)
 }
 
 //_____________________________________________________________________________________________
-void AliMillePede2::SetGlobalConstraint(const int *indgb, double *dergb, int ngb, double val,double sigma)
+void AliMillePede2::SetGlobalConstraint(const int *indgb, const double *dergb, int ngb, double val,double sigma)
 {      
   // Define a constraint equation.
   if (!fConsRecFile || !fConsRecFile->IsWritable()) InitConsRecStorage(); // create a buffer to store the data
@@ -762,7 +772,7 @@ Int_t AliMillePede2::GlobalFit(Double_t *par, Double_t *error, Double_t *pull)
   //
   if (par) for (int i=fNGloPar;i--;) par[i] = fInitPar[i]+fDeltaPar[i]; 
   //
-  if (fGloSolveStatus==gkInvert) { // errors on params are available
+  if (fGloSolveStatus==kInvert) { // errors on params are available
     if (error) for (int i=fNGloPar;i--;) error[i] = fProcPnt[i]>0 ? TMath::Sqrt(TMath::Abs(fMatCGlo->QueryDiag(i))) : 0.;
     if (pull)  for (int i=fNGloPar;i--;) pull[i]  = fProcPnt[i]>0 && (fSigmaPar[i]*fSigmaPar[i]-fMatCGlo->QueryDiag(i))>0. && fSigmaPar[i]>0 
                                           ? fDeltaPar[i]/TMath::Sqrt(fSigmaPar[i]*fSigmaPar[i]-fMatCGlo->QueryDiag(i)) : 0;
@@ -779,7 +789,7 @@ Int_t AliMillePede2::GlobalFitIteration()
   AliInfo(Form("Global Fit Iteration#%2d (Local Fit Chi^2 cut factor: %.2f)",fIter,fChi2CutFactor));
   //
   if (!fNGloPar || !fTreeData) {
-    AliInfo("No data was stored, aborting iteration");
+    AliInfo("No data was stored, stopping iteration");
     return 0;
   }
   TStopwatch sw,sws; 
@@ -1012,8 +1022,8 @@ Int_t AliMillePede2::GlobalFitIteration()
   printf("Solve %d |",fIter); sws.Print();
   //
   sw.Stop();
-  AliInfo(Form("Iteration#%2d %s. CPU time: %.1f",fIter,fGloSolveStatus==gkFailed ? "Failed":"Converged",sw.CpuTime()));
-  if (fGloSolveStatus==gkFailed) return 0;
+  AliInfo(Form("Iteration#%2d %s. CPU time: %.1f",fIter,fGloSolveStatus==kFailed ? "Failed":"Converged",sw.CpuTime()));
+  if (fGloSolveStatus==kFailed) return 0;
   //
   for (int i=fNGloPar;i--;) fDeltaPar[i] += fVecBGlo[i];    // Update global parameters values (for iterations)
   //
@@ -1037,18 +1047,18 @@ Int_t AliMillePede2::SolveGlobalMatEq()
   if (!fgIsMatGloSparse) {
     //
     if (fNLagrangeConstraints==0) { // pos-def systems are faster to solve by Cholesky
-      if ( ((AliSymMatrix*)fMatCGlo)->SolveChol(fVecBGlo, fgInvChol) ) return fgInvChol ? gkInvert:gkNoInversion;
+      if ( ((AliSymMatrix*)fMatCGlo)->SolveChol(fVecBGlo, fgInvChol) ) return fgInvChol ? kInvert:kNoInversion;
       else AliInfo("Solution of Global Dense System by Cholesky failed, trying Gaussian Elimiation");
     }
     //
-    if (((AliSymMatrix*)fMatCGlo)->SolveSpmInv(fVecBGlo, kTRUE)) return gkInvert;
+    if (((AliSymMatrix*)fMatCGlo)->SolveSpmInv(fVecBGlo, kTRUE)) return kInvert;
     else AliInfo("Solution of Global Dense System by Gaussian Elimination failed, trying iterative methods");
   }
   // try to solve by minres
   TVectorD sol(fNGloSize);
   //
   AliMinResSolve *slv = new AliMinResSolve(fMatCGlo,fVecBGlo);
-  if (!slv) return gkFailed;
+  if (!slv) return kFailed;
   //
   Bool_t res = kFALSE;
   if      (fgIterSol == AliMinResSolve::kSolMinRes) 
@@ -1063,7 +1073,7 @@ Int_t AliMillePede2::SolveGlobalMatEq()
     int defout = dup(1);
     if (defout<0) {
       AliInfo("Failed on dup");
-      return gkFailed;
+      return kFailed;
     }
     int slvDump = open(faildump, O_RDWR|O_CREAT, 0666);
     if (slvDump>=0) {
@@ -1082,10 +1092,10 @@ Int_t AliMillePede2::SolveGlobalMatEq()
     }
     else AliInfo("Failed on file open for matrix dumping");
     close(defout);
-    return gkFailed;
+    return kFailed;
   }
   for (int i=fNGloSize;i--;) fVecBGlo[i] = sol[i];
-  return gkNoInversion;
+  return kNoInversion;
   //
 }
 
@@ -1140,7 +1150,7 @@ Int_t AliMillePede2::SetIterations(double lChi2CutFac)
 Double_t AliMillePede2::GetParError(int iPar) const
 {
   // return error for parameter iPar
-  if (fGloSolveStatus==gkInvert) {
+  if (fGloSolveStatus==kInvert) {
     double res = fMatCGlo->QueryDiag(iPar);
     if (res>=0) return TMath::Sqrt(res);
   } 
@@ -1166,7 +1176,7 @@ Int_t AliMillePede2::PrintGlobalParameters() const
     lGlobalCor = 0.0;
     //         
     double dg;
-    if (fGloSolveStatus==gkInvert && TMath::Abs( (dg=fMatCGlo->QueryDiag(i)) *fDiagCGlo[i]) > 0) {    
+    if (fGloSolveStatus==kInvert && TMath::Abs( (dg=fMatCGlo->QueryDiag(i)) *fDiagCGlo[i]) > 0) {    
       lGlobalCor = TMath::Sqrt(TMath::Abs(1.0-1.0/(dg*fDiagCGlo[i])));
       AliInfo(Form("%d\t %.6f\t %.6f\t %.6f\t %.6f\t %.6f\t %.6f\t %6d",
                   i,fInitPar[i],fInitPar[i]+fDeltaPar[i],fDeltaPar[i],fVecBGlo[i],lError,lGlobalCor,fProcPnt[i]));
index 7540957b07873097c19009ae6a7469fc3c08d000..7c3d650bbc781277f199c5a0afff0278f55ff109 100644 (file)
@@ -29,7 +29,7 @@ class AliMillePede2: public TObject
 {
  public:
   //
-  enum {gkFailed,gkInvert,gkNoInversion};    // used global matrix solution methods
+  enum {kFailed,kInvert,kNoInversion};    // used global matrix solution methods
   //
   AliMillePede2();
   AliMillePede2(const AliMillePede2& src);
@@ -122,8 +122,8 @@ class AliMillePede2: public TObject
 
   //
   // constraints
-  void                 SetGlobalConstraint(double *dergb, double val, double sigma=0);
-  void                 SetGlobalConstraint(const int *indgb,double *dergb, int ngb, double val, double sigma=0);
+  void                 SetGlobalConstraint(const double *dergb, double val, double sigma=0);
+  void                 SetGlobalConstraint(const int *indgb, const double *dergb, int ngb, double val, double sigma=0);
   //
   // processing of the local measurement
   void                 SetRecordRun(Int_t run);
index 7a8d586c6e70cb594941a714e97f4ec6e9b7d0df..c79e02271c633b112ceff1f4233e5045b16f41d6 100644 (file)
@@ -30,6 +30,7 @@ fSize(0),fNGroups(0),fRunID(0),fGroupID(0),fIndex(0),fValue(0),fWeight(1) {SetUn
 AliMillePedeRecord::AliMillePedeRecord(const AliMillePedeRecord& src) : 
   TObject(src),fSize(src.fSize),fNGroups(src.fNGroups),fRunID(src.fRunID),fGroupID(0),fIndex(0),fValue(0),fWeight(src.fWeight)
 {
+  // copy ct-r
   fIndex = new Int_t[GetDtBufferSize()];
   memcpy(fIndex,src.fIndex,fSize*sizeof(Int_t));
   fValue = new Double_t[GetDtBufferSize()];
@@ -40,7 +41,8 @@ AliMillePedeRecord::AliMillePedeRecord(const AliMillePedeRecord& src) :
 
 //_____________________________________________________________________________________________
 AliMillePedeRecord& AliMillePedeRecord::operator=(const AliMillePedeRecord& rhs)
-{
+{ 
+  // assignment op-r
   if (this!=&rhs) {
     Reset();
     for (int i=0;i<rhs.GetSize();i++) {
@@ -62,6 +64,7 @@ AliMillePedeRecord::~AliMillePedeRecord() {delete[] fIndex; delete[] fValue; del
 //_____________________________________________________________________________________________
 void AliMillePedeRecord::Reset()
 {
+  // reset all
   fSize = 0;
   for (int i=fNGroups;i--;) fGroupID[i] = 0;
   fNGroups = 0;
@@ -72,6 +75,7 @@ void AliMillePedeRecord::Reset()
 //_____________________________________________________________________________________________
 void AliMillePedeRecord::Print(const Option_t *) const
 {
+  // print itself
   if (!fSize) {AliInfo("No data"); return;}
   int cnt=0,point=0;
   //  
index 561a1b89e60b87cc4fd86147dcf59d9e17d35ff6..6b82d7dfbf16f0c14af1efbc8976b72e47ce7e6c 100644 (file)
@@ -1,3 +1,15 @@
+/* ----------------------------------------------------------------------------------------
+   Class to solve a set of N linearized parametric equations of the type
+   Eq(k): sum_i=0^n { g_i G_ik }  + t_k T_k = res_k
+   whith n "global" parameters gi and one "local" parameter (per equation) t_k.
+   Each measured points provides 3 measured coordinates, with proper covariance matrix.
+
+   Used for Newton-Raphson iteration step in solution of non-linear parametric equations
+   F(g,t_k) - res_k = 0, with G_ik = dF(g,t_k)/dg_i and T_k = dF(g,t_k)/dt_k
+   Solution is obtained by elimination of local parameters via large (n+N) matrix partitioning 
+
+   Author: ruben.shahoyan@cern.ch
+-------------------------------------------------------------------------------------------*/ 
 #include "AliParamSolver.h"
 #include "AliSymMatrix.h"
 #include "AliLog.h"
@@ -23,7 +35,7 @@ AliParamSolver::AliParamSolver(Int_t maxglo,Int_t locbuff)
 }
 
 //______________________________________________________________________________________
-AliParamSolver::AliParamSolver(AliParamSolver& src)
+AliParamSolver::AliParamSolver(const AliParamSolver& src)
   : TObject(src),fMatrix(0),fSolGlo(0),fSolLoc(0),fMaxGlobal(src.fMaxGlobal),fNGlobal(src.fNGlobal),
     fNPoints(0),fMaxPoints(0),fRHSGlo(0),fRHSLoc(0),fMatGamma(0),fMatG(0),fCovDGl(0)
 { 
@@ -83,6 +95,7 @@ AliParamSolver::~AliParamSolver()
 //______________________________________________________________________________________
 Bool_t AliParamSolver::SolveGlobals(Bool_t obtainCov)
 {
+  // solve against global vars.
   if (fNPoints<fNGlobal/3) {
     AliError(Form("Number of points: %d is not enough for %d globals",fNPoints,fNGlobal));
     return kFALSE;
@@ -102,6 +115,7 @@ Bool_t AliParamSolver::SolveGlobals(Bool_t obtainCov)
 //______________________________________________________________________________________
 Bool_t AliParamSolver::SolveLocals()
 {
+  // solve for locals
   const double kTiny = 1e-16;
   if (TestBit(kBitLocSol)) return kTRUE;
   if (!TestBit(kBitGloSol)) {
@@ -122,6 +136,7 @@ Bool_t AliParamSolver::SolveLocals()
 //______________________________________________________________________________________
 AliSymMatrix* AliParamSolver::GetCovMatrix()
 {
+  // obtain cov.mat
   if (!TestBit(kBitGloSol)) {
     AliError("Cannot obtain Cov.Matrix before SolveGlobals is called");
     return 0;
@@ -138,6 +153,7 @@ AliSymMatrix* AliParamSolver::GetCovMatrix()
 //______________________________________________________________________________________
 Bool_t AliParamSolver::Solve(Bool_t obtainCov)
 {
+  // solve all
   return (SolveGlobals(obtainCov) && SolveLocals()) ? kTRUE : kFALSE; 
 }
 
@@ -277,6 +293,7 @@ void AliParamSolver::ExpandStorage(Int_t newSize)
 //______________________________________________________________________________________
 void AliParamSolver::Clear(Option_t*)
 {
+  // reset all
   fNPoints = 0;
   fMatrix->Reset();
   for (int i=fNGlobal;i--;) fRHSGlo[i] = 0;
@@ -286,12 +303,14 @@ void AliParamSolver::Clear(Option_t*)
 //______________________________________________________________________________________
 void AliParamSolver::Print(Option_t*) const
 {
+  // print itself
   AliInfo(Form("Solver with %d globals for %d points",fNGlobal,fNPoints));
 }
 
 //______________________________________________________________________________________
 void AliParamSolver::SetNGlobal(Int_t n) 
 {
+  // set N global params
   if (n>fMaxGlobal) {
     AliError(Form("Maximum number of globals was set to %d",fMaxGlobal));
     return;
@@ -303,6 +322,7 @@ void AliParamSolver::SetNGlobal(Int_t n)
 //______________________________________________________________________________________
 void AliParamSolver::SetMaxGlobal(Int_t n) 
 {
+  // set limit on N glob.
   if (n>0 && n==fMaxGlobal) return;
   fMaxGlobal = n;
   fNGlobal = n;
index 6462e5fe68dc10638b95b894a1e8d324d3f81174..2dabe6dd761190abdff6c49488b5a2dfaecc992d 100644 (file)
@@ -26,7 +26,7 @@ class AliParamSolver: public TObject
 
   AliParamSolver();
   AliParamSolver(Int_t maxglo,Int_t locsize=16);
-  AliParamSolver(AliParamSolver& src);
+  AliParamSolver(const AliParamSolver& src);
   AliParamSolver& operator=(const AliParamSolver& src);
   ~AliParamSolver();
   //
index 6bb61d4dfb5a6aa2c9225203c261690e1536c3fa..a63835b60f6caecf5934bae0310a9900cb33f539 100644 (file)
@@ -1,5 +1,5 @@
-#ifndef ALIQAChecker_H
-#define ALIQAChecker_H
+#ifndef ALIQACHECKER_H
+#define ALIQACHECKER_H
 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
  * See cxx source for full Copyright notice                               */
 
index b00aa77dfb8987827a461c891884ed49b5e89bdb..d69c694d2a0c75d04670695c0cf201908165a126 100644 (file)
@@ -1,3 +1,13 @@
+/*********************************************************************************/
+/*                                                                               */ 
+/* Class for rectangular matrix used for                                         */
+/* millepede2 operation.                                                         */
+/* May be sparse or dense.                                                       */ 
+/* -----------------------                                                       */ 
+/* Author: ruben.shahoyan@cern.ch                                                */
+/*                                                                               */ 
+/*********************************************************************************/
+
 #include "AliRectMatrix.h"
 #include <TString.h>
 //
@@ -14,7 +24,7 @@ AliRectMatrix::AliRectMatrix()
 AliRectMatrix::AliRectMatrix(Int_t nrow,Int_t ncol)
   : fNRows(nrow),fNCols(ncol),fRows(0)
 {
-  //
+  // c-tor
   fRows = new Double_t*[fNRows];
   for (int i=fNRows;i--;) {
     fRows[i] = new Double_t[fNCols];
@@ -27,6 +37,7 @@ AliRectMatrix::AliRectMatrix(Int_t nrow,Int_t ncol)
 AliRectMatrix::AliRectMatrix(const AliRectMatrix &src)
   : TObject(src),fNRows(src.fNRows), fNCols(src.fNCols), fRows(0)
 {
+  // copy c-tor
   fRows = new Double_t*[fNRows];
   for (int i=fNRows;i--;) {
     fRows[i] = new Double_t[fNCols];
@@ -37,6 +48,7 @@ AliRectMatrix::AliRectMatrix(const AliRectMatrix &src)
 //___________________________________________________________
 AliRectMatrix::~AliRectMatrix()
 {
+  // dest-tor
   if (fNRows) for (int i=fNRows;i--;) delete[] fRows[i];
   delete[] fRows;
 }
@@ -44,7 +56,7 @@ AliRectMatrix::~AliRectMatrix()
 //___________________________________________________________
 AliRectMatrix& AliRectMatrix::operator=(const AliRectMatrix& src)
 {
-  //
+  // assignment op-r
   if (&src == this) return *this;
   if (fNRows) for (int i=fNRows;i--;) delete[] fRows[i];
   delete[] fRows;
@@ -62,6 +74,7 @@ AliRectMatrix& AliRectMatrix::operator=(const AliRectMatrix& src)
 //___________________________________________________________
 void AliRectMatrix::Print(Option_t* option) const
 {
+  // print itself
   printf("Rectangular Matrix:  %d rows %d columns\n",fNRows,fNCols);
   TString opt = option; opt.ToLower();
   if (opt.IsNull()) return;
@@ -73,8 +86,9 @@ void AliRectMatrix::Print(Option_t* option) const
 
 
 //___________________________________________________________
-void AliRectMatrix::Reset()
+void AliRectMatrix::Reset() const
 {
+  // reset all
   for (int i=fNRows;i--;) {
     double *row = GetRow(i); 
     for (int j=fNCols;j--;)  row[j] = 0.;
index 0885b014552b949f10be153fc0a062ea99762bc2..ecdaeeff62ec87e7d6a435f4c1a5390ca8ad1089 100644 (file)
@@ -1,6 +1,14 @@
 #ifndef ALIRECTMATRIX_H
 #define ALIRECTMATRIX_H
 
+/*********************************************************************************/
+/*                                                                               */ 
+/* Class for rectangular matrix used for                                         */
+/* millepede2 operation.                                                         */
+/* Author: ruben.shahoyan@cern.ch                                                */
+/*                                                                               */ 
+/*********************************************************************************/
+
 #include "TObject.h"
 class TString;
 
@@ -23,7 +31,7 @@ class AliRectMatrix : public TObject {
   Double_t*     operator()(Int_t row)                 const {return GetRow(row);}
   Double_t*     GetRow(Int_t row)                     const {return fRows[row];}
   //
-  void          Reset();
+  void          Reset() const;
   //
   virtual void  Print(Option_t* option="")           const;
   //
index 2c000cce0830047b6fdd7bd1f3244953ea231d37..326aade1c4ac1b9227b1dc84603a9138ebe9e8b0 100644 (file)
@@ -349,7 +349,7 @@ Bool_t AliSymMatrix::SolveChol(Double_t *brhs, Double_t *bsol,Bool_t invert)
 }
 
 //___________________________________________________________
-Bool_t AliSymMatrix::SolveChol(TVectorD &brhs, TVectorD &bsol,Bool_t invert) 
+Bool_t AliSymMatrix::SolveChol(const TVectorD &brhs, TVectorD &bsol,Bool_t invert) 
 {
   bsol = brhs;
   return SolveChol(bsol,invert);
index 7247898e67fe5fd6a6bf55bdfb0d39b7159a13ed..ccf7619abf8a42fef1f12994671b22d1556ba42f 100644 (file)
@@ -74,7 +74,7 @@ class AliSymMatrix : public AliMatrixSq {
   Bool_t              SolveChol(Double_t *brhs, Bool_t invert=kFALSE);
   Bool_t              SolveChol(Double_t *brhs, Double_t *bsol,Bool_t invert=kFALSE);
   Bool_t              SolveChol(TVectorD &brhs, Bool_t invert=kFALSE);
-  Bool_t              SolveChol(TVectorD &brhs, TVectorD& bsol,Bool_t invert=kFALSE);
+  Bool_t              SolveChol(const TVectorD &brhs, TVectorD& bsol,Bool_t invert=kFALSE);
   //
   int                 SolveSpmInv(double *vecB, Bool_t stabilize=kTRUE);
 
index a02d87747b9005ac7c6bea494279b708bbeba4cc..befa578351ad70931735a95387af112eed5b8425 100644 (file)
  * provided "as is" without express or implied warranty.                  *
  **************************************************************************/
 
-//-----------------------------------------------------------------
-//   Implementation of the base class for fast track fitters
-//
-//
-//-----------------------------------------------------------------
+/*************************************************************************
+ * AliTrackFitter: base class for the fast track fitters                 *
+ *                                                                       *
+ * Supposed to be used for alignment framework                           *
+ * More information is available in 
+ * http://agenda.cern.ch/askArchive.php?base=agenda&categ=a057717&id=a057717s1t6/transparencies  
+ * Author: C.Cheskov                                                     *
+ *                                                                       *
+ *                                                                       *
+ *************************************************************************/
 
 #include <TMatrixDSym.h>
 #include <TArrayI.h>
index 0f75ef6021cf33e39b42f789982d59d7a82e797e..4558305efb8947619ca955f7a1a383a275888e0c 100644 (file)
@@ -4,6 +4,10 @@
 /*************************************************************************
  * AliTrackFitter: base class for the fast track fitters                 *
  *                                                                       *
+ * Supposed to be used for alignment framework                           *
+ * More information is available in 
+ * http://agenda.cern.ch/askArchive.php?base=agenda&categ=a057717&id=a057717s1t6/transparencies  
+ * Author: C.Cheskov                                                     *
  *                                                                       *
  *                                                                       *
  *************************************************************************/
index a0e209a3dcb04f2ba00955c999d704d688dc677e..f96f60291fb05eb9f623d9a2ee98c30982194bab 100644 (file)
@@ -36,6 +36,7 @@ AliVectorSparse::AliVectorSparse()
 AliVectorSparse::AliVectorSparse(const AliVectorSparse& src)
   : TObject(src),fNElems(src.fNElems),fIndex(0),fElems(0)
 {
+  // copy c-tor
   fIndex = new UShort_t[fNElems];
   fElems = new Double_t[fNElems];
   memcpy(fIndex,src.fIndex,fNElems*sizeof(UShort_t));
@@ -45,6 +46,7 @@ AliVectorSparse::AliVectorSparse(const AliVectorSparse& src)
 //___________________________________________________________
 void AliVectorSparse::Clear(Option_t*)
 {
+  // clear all
   delete[] fIndex; fIndex = 0;
   delete[] fElems; fElems = 0;
   fNElems = 0;
@@ -53,6 +55,7 @@ void AliVectorSparse::Clear(Option_t*)
 //___________________________________________________________
 AliVectorSparse& AliVectorSparse::operator=(const AliVectorSparse& src)
 {
+  // assignment op-tor
   if (&src==this) return *this;
   Clear();
   TObject::operator=(src);
@@ -131,6 +134,7 @@ Double_t& AliVectorSparse::FindIndexAdd(Int_t ind)
 //__________________________________________________________
 void AliVectorSparse::ReSize(Int_t sz,Bool_t copy)
 {
+  // change the size
   if (sz<1) {Clear(); return;}
     // need to insert a new element
   UShort_t *arrI = new UShort_t[sz];
@@ -164,6 +168,7 @@ void AliVectorSparse::SortIndices(Bool_t valuesToo)
 //__________________________________________________________
 void AliVectorSparse::Print(Option_t* opt)  const
 {
+  // print itself
   TString sopt = opt; sopt.ToLower();
   int ndig = sopt.Atoi();
   if (ndig<=1) ndig = 2;
index edc6a745f188be25ceb86246112fd061c0c1f0c9..f7e2305f60b4d31ca6f08b303a3c698a6fbb2e6c 100644 (file)
@@ -43,7 +43,7 @@ class AliVectorSparse : public TObject {
   Double_t &GetLastElem()                                      {return fElems[fNElems-1];}
   //
  protected:
-  Int_t            fNElems;   // 
+  Int_t            fNElems;   // Number of elements
   UShort_t*        fIndex;    // Index of stored elems
   Double_t*        fElems;    // pointer on elements
   //
index 65dee8a203d2d8fe2089708881d623d7e7f10f0e..363841a47caac510b43c83de7e258c4a2b4ec7de 100644 (file)
@@ -544,6 +544,7 @@ AliMagF* AliMagF::CreateFieldMap(Float_t l3Cur, Float_t diCur, Int_t convention,
 //_____________________________________________________________________________
 const char*  AliMagF::GetBeamTypeText() const
 {
+  // beam type in text form
   const char *beamNA  = "No Beam";
   const char *beamPP  = "p-p";
   const char *beamPbPb= "A-A";
index 9a668425a997f17da8525a6f0966243d698d60e6..4fa8589ec8a637488f6d692134a3bee249a161f9 100644 (file)
@@ -18,6 +18,7 @@
 #include <TSystem.h>
 #include <TArrayF.h>
 #include <TArrayI.h>
+#include <AliCheb3D.h>
 
 ClassImp(AliMagWrapCheb)
 
@@ -715,6 +716,7 @@ void AliMagWrapCheb::LoadData(const char* inpfile)
 //__________________________________________________________________________________________
 void AliMagWrapCheb::BuildTableSol()
 {
+  // build lookup table
   BuildTable(fNParamsSol,fParamsSol,
             fNZSegSol,fNPSegSol,fNRSegSol,
             fMinZSol,fMaxZSol, 
@@ -727,6 +729,7 @@ void AliMagWrapCheb::BuildTableSol()
 //__________________________________________________________________________________________
 void AliMagWrapCheb::BuildTableDip()
 {
+  // build lookup table
   BuildTable(fNParamsDip,fParamsDip,
             fNZSegDip,fNYSegDip,fNXSegDip,
             fMinZDip,fMaxZDip, 
@@ -739,6 +742,7 @@ void AliMagWrapCheb::BuildTableDip()
 //__________________________________________________________________________________________
 void AliMagWrapCheb::BuildTableTPCInt()
 {
+  // build lookup table
   BuildTable(fNParamsTPC,fParamsTPC,
             fNZSegTPC,fNPSegTPC,fNRSegTPC,
             fMinZTPC,fMaxZTPC, 
@@ -751,6 +755,7 @@ void AliMagWrapCheb::BuildTableTPCInt()
 //__________________________________________________________________________________________
 void AliMagWrapCheb::BuildTableTPCRatInt()
 {
+  // build lookup table
   BuildTable(fNParamsTPCRat,fParamsTPCRat,
             fNZSegTPCRat,fNPSegTPCRat,fNRSegTPCRat,
             fMinZTPCRat,fMaxZTPCRat, 
index c1de663752dc2fed797cc529889c8a2c81e0c0d2..0285dcd136cb3cf36d4a14a4999c0db1615a37f8 100644 (file)
@@ -39,7 +39,8 @@
 
 #include <TMath.h>
 #include <TNamed.h>
-#include "AliCheb3D.h"
+#include <TObjArray.h>
+class AliCheb3D;
 
 class TSystem;
 class TArrayF;
index 88c46f7695387588241e9e8cda213fa00d33f9a7..2e6ac9dcc01e1cc40579c285626586b61d26e3be 100644 (file)
@@ -28,6 +28,7 @@ AliRefArray::AliRefArray() : fNElems(0),fRefSize(0),fElems(0),fRefInd(0),fRefBuf
 AliRefArray::AliRefArray(UInt_t nelem,UInt_t depth) : 
   TObject(),fNElems(nelem),fRefSize(depth),fElems(0),fRefInd(0),fRefBuff(0)
 {
+  // constructor
   fNElems = nelem;
   // create array with nelem initial referres
   if (fNElems<1) fNElems = 1;