Changeset 4216 for trunk/MagicSoft/Mars


Ignore:
Timestamp:
05/27/04 15:50:22 (20 years ago)
Author:
gaug
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/Changelog

    r4215 r4216  
    1818
    1919                                                 -*-*- END OF LINE -*-*-
     20
     21 2004/05/27: Markus Gaug
     22
     23   * mcalib/MHCalibrationChargeBlindPix.[h,cc]
     24     - put some protection against zero-division in fitFuncMichele
    2025
    2126 2004/05/27: Thomas Bretz
  • trunk/MagicSoft/Mars/mcalib/MHCalibrationChargeBlindPix.cc

    r4200 r4216  
    622622  const Double_t lambda_1cat_guess = 0.005;
    623623  const Double_t lambda_1dyn_guess = 0.002;
    624   //  const Double_t mu_1cat_guess = mu_0_guess + 4500.;
    625   //  const Double_t mu_1dyn_guess = mu_0_guess + 2500.;
    626   const Double_t mu_1cat_guess = mu_0_guess + 1000.;
    627   const Double_t mu_1dyn_guess = mu_0_guess + 2500.;
    628   const Double_t si_1cat_guess = 500.;
    629   const Double_t si_1dyn_guess = 1000.;
     624  const Double_t mu_1cat_guess = 1000.;
     625  const Double_t mu_1dyn_guess = 2500.;
     626  const Double_t si_1cat_guess = si_0_guess+ 500.;
     627  const Double_t si_1dyn_guess = si_0_guess+ 1000.;
    630628  const Double_t offset_guess  = 0.5;
    631629  // Polya
     
    696694    case kEMichele:
    697695      fSinglePheFit->SetParameters(lambda_1cat_guess, lambda_1dyn_guess,
    698                                    mu_0_guess, mu_1cat_guess,mu_1dyn_guess,
     696                                   20., mu_1cat_guess,mu_1dyn_guess,
    699697                                   si_0_guess, si_1cat_guess,si_1dyn_guess,
    700698                                   norm, offset_guess);
     
    706704      fSinglePheFit->SetParLimits(1,0.,0.05);
    707705      fSinglePheFit->SetParLimits(2,0.,fSinglePheCut);   
    708       //      fSinglePheFit->SetParLimits(3,4000.,5500.);   
    709       //      fSinglePheFit->SetParLimits(4,2500.,5000.);   
    710706      fSinglePheFit->SetParLimits(3,fSinglePheCut,3000.);   
    711707      fSinglePheFit->SetParLimits(4,fSinglePheCut,3500.);   
     
    713709      fSinglePheFit->SetParLimits(6,500.,1000.);   
    714710      fSinglePheFit->SetParLimits(7,300.,1500.);   
    715       //      fSinglePheFit->SetParLimits(6,300.,2000.);   
    716       //      fSinglePheFit->SetParLimits(7,100.,2500.);   
    717711      fSinglePheFit->SetParLimits(8,norm/1.1,norm*1.1);
    718712      fSinglePheFit->SetParLimits(9,0.,1.);
     
    880874  const Stat_t   entries = fHGausHist.Integral("width");
    881875  const Double_t pedarea = fFGausFit->Integral(0.,fSinglePheCut);
    882    
     876
    883877  fLambdaCheck     = TMath::Log(entries/pedarea);
    884878  // estimate the error by the error of the obtained area from the Gauss-function:
  • trunk/MagicSoft/Mars/mcalib/MHCalibrationChargeBlindPix.h

    r4198 r4216  
    179179      Double_t sumcat = 0.;
    180180      Double_t sumdyn = 0.;
    181       Double_t arg = 0.;
    182      
     181      Double_t arg    = 0.;
     182     
     183      if (lambda1cat < lambda1dyn)
     184        return FLT_MAX;
     185
    183186      if (mu1cat    < mu0)
    184187        return FLT_MAX;
    185188
     189      if (mu1dyn    < mu0)
     190        return FLT_MAX;
     191
     192      if (mu1cat < mu1dyn)
     193        return FLT_MAX;
     194
     195      if (sigma0 < 0.0001)
     196        return FLT_MAX;
     197     
    186198      if (sigma1cat < sigma0)
    187199        return FLT_MAX;
    188200
    189       // if (sigma1cat < sigma1dyn)
    190       // return NoWay;
    191 
    192       //if (mu1cat < mu1dyn)
    193       // return NoWay;
    194 
    195       //      if (lambda1cat < lambda1dyn)
    196       // return NoWay;
     201      if (sigma1dyn < sigma0)
     202        return FLT_MAX;
     203
     204      if (sigma1cat < sigma1dyn)
     205        return FLT_MAX;
    197206
    198207      Double_t mu2cat = (2.*mu1cat)-mu0; 
Note: See TracChangeset for help on using the changeset viewer.