]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
bugfix: correctly treat signed numbers
authorrichterm <richterm@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 29 Apr 2010 00:34:17 +0000 (00:34 +0000)
committerrichterm <richterm@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 29 Apr 2010 00:34:17 +0000 (00:34 +0000)
removing calls to AliGRPObject::SetLHCLuminosity and AliGRPObject::SetBeamIntensity according to new class interface

HLT/exa/makeGRPObject.C

index e6303196a142b3d2201c35e5fd1ad9492e53ec1d..6a98f1897a423b0ba764ad2f3669dc7ad331df72 100644 (file)
@@ -79,8 +79,6 @@ void makeGRPObject(float l3Current,
   float cmsEnergy=14000;
   grpObj->SetBeamEnergy(cmsEnergy/0.120); // LHC convention
   grpObj->SetBeamType("p-p");
-  grpObj->SetLHCLuminosity(0,(AliGRPObject::Stats)0);
-  grpObj->SetBeamIntensity(0,(AliGRPObject::Stats)0);
   grpObj->SetL3Current(l3Current,(AliGRPObject::Stats)0);
   grpObj->SetDipoleCurrent(dipoleCurrent,(AliGRPObject::Stats)0);  
   grpObj->SetL3Polarity(l3Polarity);  
@@ -133,9 +131,9 @@ void makeGRPObject(const char* arguments="",
        if (arg.CompareTo("off", TString::kIgnoreCase)==0) {
          l3Current=0;
          l3Polarity=0;
-       } else if (arg.IsDigit()) {
+       } else if (arg.IsFloat()) {
          l3Current=arg.Atof();
-         l3Polarity=l3Current<0 ? 0:1;
+         l3Polarity=l3Current<0 ? 1:0;
          l3Current=TMath::Abs(l3Current);
        } else {
          cerr << "Invalid parameter for key 'l3=', allowed is 'off' or current" << endl;
@@ -146,9 +144,9 @@ void makeGRPObject(const char* arguments="",
        if (arg.CompareTo("off", TString::kIgnoreCase)==0) {
          dipoleCurrent=0;
          dipolePolarity=0;
-       } else if (arg.IsDigit()) {
+       } else if (arg.IsFloat()) {
          dipoleCurrent=arg.Atof();
-         dipolePolarity=dipoleCurrent<0 ? 0:1;
+         dipolePolarity=dipoleCurrent<0 ? 1:0;
          dipoleCurrent=TMath::Abs(dipoleCurrent);
        } else {
          cerr << "Invalid parameter for key 'dipole=', allowed is 'off' or current" << endl;