Another fix of the magnets current check
authorshahoian <shahoian@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 15 Dec 2009 23:46:26 +0000 (23:46 +0000)
committershahoian <shahoian@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 15 Dec 2009 23:46:26 +0000 (23:46 +0000)
STEER/AliMagF.cxx

index a0fa318..f7960fe 100644 (file)
@@ -466,7 +466,7 @@ AliMagF* AliMagF::CreateFieldMap(Float_t l3Cur, Float_t diCur, Int_t convention,
   else {
     if      (TMath::Abs((sclL3=l3Cur/l3NominalCurrent1)-1.) < tolerance) map  = k5kG;
     else if (TMath::Abs((sclL3=l3Cur/l3NominalCurrent2)-1.) < tolerance) map  = k2kG;
-    else if (l3Cur <= zero)                                { sclL3 = 0;  map  = k5kGUniform;}
+    else if (l3Cur <= zero && diCur<=zero)   { sclL3=0; sclDip=0; map  = k5kGUniform;}
     else {
       AliErrorGeneral("AliMagF",Form("Wrong L3 current (%f A)!",l3Cur));
       return 0;