]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Using Min and Max from TMath
authorhristov <hristov@f7af4fe6-9843-0410-8265-dc069ae4e863>
Fri, 2 Mar 2007 16:36:43 +0000 (16:36 +0000)
committerhristov <hristov@f7af4fe6-9843-0410-8265-dc069ae4e863>
Fri, 2 Mar 2007 16:36:43 +0000 (16:36 +0000)
MUON/AliMUONClusterFinderCOG.cxx
MUON/AliMillepede.cxx
MUON/mapping/AliMpPCB.cxx
MUON/mapping/AliMpPCBPadIterator.cxx
MUON/mapping/AliMpSlat.cxx
MUON/mapping/AliMpSlatPadIterator.cxx
MUON/mapping/AliMpTrigger.cxx
TPC/AliTPCtrackerMI.cxx

index 33f079c840e821e4773e47e710a2d97bbd8a98f0..f7087ce6b26e90cdce69ed80ff23d96aa76e27e7 100644 (file)
@@ -134,10 +134,10 @@ AliMUONClusterFinderCOG::ComputePosition(AliMUONCluster& cluster)
       AliMUONPad* pad = cluster.Pad(i);
       TVector2 padPosition = pad->Position();
       AliMpArea area(pad->Position(),pad->Dimensions());
-      xmin = std::min(area.LeftBorder(),xmin);
-      xmax = std::max(area.RightBorder(),xmax);
-      ymin = std::min(area.DownBorder(),ymin);
-      ymax = std::max(area.UpBorder(),ymax);
+      xmin = TMath::Min(area.LeftBorder(),xmin);
+      xmax = TMath::Max(area.RightBorder(),xmax);
+      ymin = TMath::Min(area.DownBorder(),ymin);
+      ymax = TMath::Max(area.UpBorder(),ymax);
       if ( cathode == pad->Cathode() )
       {
         x[cathode] += padPosition.X()*pad->Charge();
index 387105441115f8f9fa9f92bdbf513d31ace69ad3..ebc85b9aeefa6cc0306862c01f23a10b9e20b566 100644 (file)
@@ -1132,7 +1132,7 @@ int AliMillepede::SpmInv(double matV[][fgkMaxGloPC], double vecB[], int nGlo)
     iPivot = -1;
     
     for (Int_t j=0; j<nGlo; j++) { // First look for the pivot, ie max unused diagonal element       
-      if (bUnUsed[j] && (TMath::Abs(matV[j][j])>std::max(TMath::Abs(vPivot),eps*diagV[j]))) {    
+      if (bUnUsed[j] && (TMath::Abs(matV[j][j])>TMath::Max(TMath::Abs(vPivot),eps*diagV[j]))) {    
        vPivot = matV[j][j];
        iPivot = j;
       }
index 787c3f465234aacc1404628eb23f75a7b0c3d95d..a374d3ca908e04b38b736716c835dcce2f05fe40 100644 (file)
@@ -313,10 +313,10 @@ AliMpPCB::Add(AliMpMotifType* mt, Int_t ix, Int_t iy)
   fMotifPositions.push_back(mp);
 #endif
 
-  fIxmin = std::min(fIxmin,ixmin);
-  fIxmax = std::max(fIxmax,ixmax);
-  fIymin = std::min(fIymin,iymin);
-  fIymax = std::max(fIymax,iymax);
+  fIxmin = TMath::Min(fIxmin,ixmin);
+  fIxmax = TMath::Max(fIxmax,ixmax);
+  fIymin = TMath::Min(fIymin,iymin);
+  fIymax = TMath::Max(fIymax,iymax);
 
   fActiveXmin = fIxmin*PadSizeX();
   fActiveXmax = (fIxmax+1)*PadSizeX();
index 3044d895b67c500586950b033f568033afed05f6..20599b7531d231289a37f9e4a59eecf2734579bc 100644 (file)
@@ -108,10 +108,10 @@ AliMpPCBPadIterator::CropArea(const AliMpArea& area)
   
   AliDebug(3,Form("xleft,xright=%e,%e",xleft,xright));
   
-  Double_t xmin = std::max(area.LeftBorder(),xleft);
-  Double_t xmax = std::min(area.RightBorder(),xright);
-  Double_t ymin = std::max(area.DownBorder(),0.0);
-  Double_t ymax = std::min(area.UpBorder(),first->DY()*2.0-kEpsilon);
+  Double_t xmin = TMath::Max(area.LeftBorder(),xleft);
+  Double_t xmax = TMath::Min(area.RightBorder(),xright);
+  Double_t ymin = TMath::Max(area.DownBorder(),0.0);
+  Double_t ymax = TMath::Min(area.UpBorder(),first->DY()*2.0-kEpsilon);
   
   AliDebug(3,Form("Cropped area (%e,%e)->(%e,%e)",
                   xmin,ymin,xmax,ymax));
index e42793d1ff99547591e62e8b96b0d9725f2c666d..a23df5599b9cc395a6873d7dcbc1c0d9aba562da 100644 (file)
@@ -136,7 +136,7 @@ AliMpSlat::Add(const AliMpPCB& pcbType, const TArrayI& manuList)
   fDY = TMath::Max(pcb->DY(),fDY);
   fDX += pcb->DX();
   fNofPadsX += pcb->GetNofPadsX();
-  fMaxNofPadsY = std::max(fMaxNofPadsY,pcb->GetNofPadsY());
+  fMaxNofPadsY = TMath::Max(fMaxNofPadsY,pcb->GetNofPadsY());
   for ( AliMpPCB::Size_t i = 0; i < pcb->GetSize(); ++i )
        {
                AliMpMotifPosition* mp = pcb->GetMotifPosition(i);
index bebf5d9edac36767a0f355ffdbe13167bca410f4..787e490338d226a43e2b8bff4e60a4b48562eb0b 100644 (file)
@@ -98,10 +98,10 @@ AliMpSlatPadIterator::Intersect(const AliMpArea& a, const AliMpArea& b) const
                                                                        a.LeftBorder(),a.DownBorder(),a.RightBorder(),a.UpBorder(),
                                                                        b.LeftBorder(),b.DownBorder(),b.RightBorder(),b.UpBorder()));
        
-       Double_t xmin = std::max(a.LeftBorder(),b.LeftBorder());
-  Double_t xmax = std::min(a.RightBorder(),b.RightBorder());
-  Double_t ymin = std::max(a.DownBorder(),b.DownBorder());
-  Double_t ymax = std::min(a.UpBorder(),b.UpBorder());
+       Double_t xmin = TMath::Max(a.LeftBorder(),b.LeftBorder());
+  Double_t xmax = TMath::Min(a.RightBorder(),b.RightBorder());
+  Double_t ymin = TMath::Max(a.DownBorder(),b.DownBorder());
+  Double_t ymax = TMath::Min(a.UpBorder(),b.UpBorder());
   AliMpArea c( TVector2( (xmin+xmax)/2.0, (ymin+ymax)/2.0 ),
                                                         TVector2( (xmax-xmin)/2.0, (ymax-ymin)/2.0 ) );
        
index 40473a990d271c40ff424ab20d1162c8ac85bafc..f6ba6bdab0fbeb657d1ec04cb743ec043ade9182 100644 (file)
@@ -137,9 +137,9 @@ AliMpTrigger::AdoptLayer(AliMpSlat* slat)
   // the slat segmentation will be the owner of the slat, and will delete
   // it when it'll be deleted itself
   fSlatSegmentations.Add(new AliMpSlatSegmentation(slat,owner));
-  fMaxNofPadsY = std::max(slat->GetMaxNofPadsY(),fMaxNofPadsY);
-  fDX = std::max(fDX,slat->DX());
-  fDY = std::max(fDY,slat->DY());
+  fMaxNofPadsY = TMath::Max(slat->GetMaxNofPadsY(),fMaxNofPadsY);
+  fDX = TMath::Max(fDX,slat->DX());
+  fDY = TMath::Max(fDY,slat->DY());
   return kTRUE;
 }
 
index ebf8cf73c5353c72dd9324a266a6b3f594fcf0c1..609512100c1628f0c75968c1da06e3943b54c7eb 100644 (file)
@@ -4162,7 +4162,7 @@ void  AliTPCtrackerMI::FindKinks(TObjArray * array, AliESD *esd)
       if (TMath::Abs(1./track1->GetC())>200) continue;
       if (track1->Get1Pt()*track0->Get1Pt()>0)      continue;
       if (track1->GetTgl()*track0->GetTgl()>0)      continue;
-      if (max(TMath::Abs(1./track0->GetC()),TMath::Abs(1./track1->GetC()))>190) continue;
+      if (TMath::Max(TMath::Abs(1./track0->GetC()),TMath::Abs(1./track1->GetC()))>190) continue;
       if (track0->GetBConstrain()&&TMath::Abs(track1->Get1Pt())<TMath::Abs(track0->Get1Pt())) continue; //returning - lower momenta
       if (track1->GetBConstrain()&&TMath::Abs(track0->Get1Pt())<TMath::Abs(track1->Get1Pt())) continue; //returning - lower momenta
       //