Changeset 2452


Ignore:
Timestamp:
11/03/03 12:49:42 (21 years ago)
Author:
blanch
Message:
Bug fixed in MFadc::Pedestal() and in print out.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Simulation/Detector/include-MFadc/MFadc.cxx

    r2433 r2452  
    4242  cout<< "[MFadc]       Response Are : "<<ampl<<" adc counts"<< endl ;
    4343  cout<< "[MFadc]       Response FWHM : "<<fwhm<<" ns"<< endl ;
    44   cout<< "[MFadc]    - Inner pixels :  "<< endl ;
     44  cout<< "[MFadc]    - Outer pixels :  "<< endl ;
    4545  cout<< "[MFadc]       Response Are : "<<amplout<<" adc counts"<< endl ;
    4646  cout<< "[MFadc]       Response FWHM : "<<fwhmout<<" ns"<< endl ;
     
    5555
    5656  sigma = fwhm_resp / 2.35 ;
    57   x0 = 3*sigma ;
     57  x0 = 3*sigma;
    5858 
    5959  Float_t   dX, dX2 ;
     
    6161  dX  = WIDTH_FADC_TIMESLICE / SUBBINS ;
    6262  dX2 = dX/2. ;
     63
     64
    6365 
    6466  for (i=0; i< RESPONSE_SLICES_MFADC ; i++ ) { 
     
    7476
    7577  }
     78
    7679
    7780  sigma = fwhm_resp_outer / 2.35 ;
     
    380383
    381384  for(i=0;i<numpix;i++)
    382     for(j=0;j<(Int_t)SLICES_MFADC;j++)
    383       sig[i][j]+=pedestal[i];
     385    for(j=0;j<(Int_t)SLICES_MFADC;j++){
     386      if(used[i])
     387        sig[i][j]+=pedestal[i];
     388      else
     389        sig[i][j]=pedestal[i];
     390    }
    384391
    385392}
     
    677684    sigma+=((Float_t)value-pedestal[pix])*((Float_t)value-pedestal[pix]);
    678685  }
     686
    679687
    680688  sigma=sqrt(sigma/(SLICES_MFADC-1));
     
    738746          }
    739747      }
    740 
    741748    }
    742749  } 
Note: See TracChangeset for help on using the changeset viewer.