Changeset 4853 for trunk/MagicSoft/Mars


Ignore:
Timestamp:
09/03/04 21:52:44 (20 years ago)
Author:
gaug
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars/mcalib
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/mcalib/MCalibrationChargeCalc.cc

    r4851 r4853  
    12731273      MBadPixelsPix         &bad = (*fBadPixels)[i];
    12741274
    1275       if (!pix.IsFFactorMethodValid())
     1275      if (bad.IsUnsuitable(MBadPixelsPix::kUnsuitableRun))
    12761276        continue;
    12771277     
    1278       const Int_t   aidx   = (*fGeom)[i].GetAidx();
    1279 
    12801278      if (bad.IsUncalibrated(MBadPixelsPix::kChargeSigmaNotValid))
    12811279        {
     1280          const Int_t            aidx = (*fGeom)[i].GetAidx();
    12821281          MCalibrationChargePix &apix = (MCalibrationChargePix&)fCam->GetAverageArea(aidx);
    12831282          pix.SetPheFFactorMethod   ( apix.GetPheFFactorMethod()    );
  • trunk/MagicSoft/Mars/mcalib/MCalibrationChargePix.cc

    r4787 r4853  
    878878
    879879  const Float_t ffactorsquareRelVar = 4.* GetFFactorRelVar();
    880   const Float_t rsigmaSquareRelVar  =     fRSigmaSquareVar / fRSigmaSquare / fRSigmaSquare;
     880  const Float_t rsigmaSquareRelVar  = fRSigmaSquareVar / fRSigmaSquare / fRSigmaSquare;
    881881  //
    882882  // In the calculation of the number of phe's one mean square has already been used.
     
    884884  // the errors, but have to take account of this cancellation:
    885885  //
    886   const Float_t convrelvar = ffactorsquareRelVar + GetMeanRelVar() + rsigmaSquareRelVar;
     886  Float_t convrelvar = ffactorsquareRelVar + GetMeanRelVar() + rsigmaSquareRelVar;
    887887  const Float_t limit      = IsHiGainSaturation() ? fConvFFactorRelVarLimit * 4. : fConvFFactorRelVarLimit;
     888
     889  //
     890  // Also have to take into account the pixels labelled MBadPixelsPix::kChargeSigmaNotValid which do not
     891  // have a fRSigmaSquareVar, calculate their error directly!
     892  //
     893  if (fRSigmaSquareVar < 0.)
     894    convrelvar = GetMeanRelVar() + GetPheFFactorMethodRelVar();
    888895
    889896  if (IsDebug())
Note: See TracChangeset for help on using the changeset viewer.