Ignore:
Timestamp:
10/12/04 14:43:18 (20 years ago)
Author:
moralejo
Message:
*** empty log message ***
File:
1 edited

Legend:

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

    r5099 r5248  
    5656  Float_t  pedestal[CAMERA_PIXELS] ;  //  Pedestal of FADCs
    5757
    58   Float_t  sig[CAMERA_PIXELS][(Int_t) SLICES_MFADC] ; //  the analog signal for pixels, in bins of width
    59                                                       //  equal to the FADC slice: 50/15 ns, but with a
    60                                                       //  total of SLICES_MFADC (=48 now) bins.
    61   Float_t noise[((Int_t) SLICES_MFADC)*1001];
    62   Float_t noise_outer[((Int_t) SLICES_MFADC)*1001];
    63   Int_t digital_noise[((Int_t) SLICES_MFADC)*1001];
    64 
    65   Float_t  output[CAMERA_PIXELS][FADC_SLICES];  //  the analog signal for pixels that is read after a trigger
    66                                                 //  occurs (high gain). Only 15 (=FADC_SLICES) bins
    67 
    68   Float_t  output_lowgain[CAMERA_PIXELS][FADC_SLICES]; //  analog signal, low gain.
     58  Int_t    fSlices_mFadc;  // Number of simulated FADC slices. Larger than the actual number of slices
     59                           // that will be written, since we have to account for possible delays in the
     60                           // trigger
     61
     62  Int_t fResponseSlicesFadc;
     63
     64  //
     65  //  Float_t sig[CAMERA_PIXELS][] ;
     66  //  the analog signal for pixels, in bins of width
     67  //  equal to the FADC slice: (default 50/15 ns), but with a
     68  //  total of fSlices_mFadc bins (default 48).
     69  //
     70  Float_t *sig[CAMERA_PIXELS];
     71
     72  Float_t *noise;
     73  Float_t *noise_outer;
     74  Float_t *digital_noise;
     75
     76  Float_t  *output[CAMERA_PIXELS];  //  the analog signal for pixels that is read after a trigger
     77                                    //  occurs (high gain).
     78
     79  Float_t  *output_lowgain[CAMERA_PIXELS]; //  analog signal, low gain.
    6980
    7081  Float_t high2low_gain;
     82
    7183  //
    7284  //    first the data for the response function
    7385  //
    74   Int_t shape_resp ;                      // index shape of the phe_response function
    75                                           // = 0 --> Gaussian
    76                                           // = 1 --> Pulpo set-up
    77   Float_t fwhm_resp ;                      // fwhm of the phe_response function (in ns)
    78   Float_t integ_resp ;                      // area below curve of the phe_response function (in counts * ns)
    79   Float_t sing_resp[ RESPONSE_SLICES_MFADC ] ;   // the shape of the phe_response function
     86  Int_t shape_resp;      // index shape of the phe_response function
     87                         // = 0 --> Gaussian
     88                         // = 1 --> Pulpo set-up
     89  Float_t fwhm_resp;     // fwhm of the phe_response function (in ns)
     90  Float_t integ_resp;    // area below curve of the phe_response function (in counts * ns)
     91  Float_t *sing_resp;    // the shape of the phe_response function
     92
     93  Float_t fFadcSlicesPerNanosec; // Number of FADC slices per nanosecond, that is, the
     94                                 // sampling frequency of the FADC.
     95
     96  Int_t fFadcSlices;     // Number of FADC slices that will be written on the output
     97                         // file (same number for high and low gain)
    8098
    8199  //
    82100  //    We may end up with a different reponse for the outer pixels
    83101  //
    84   Int_t shape_resp_outer ;                      // index shape of the phe_response function
    85                                           // = 0 --> Gaussian
    86                                           // = 1 --> Pulpo set-up
    87   Float_t fwhm_resp_outer ;                      // fwhm of the phe_response function (in ns)
    88   Float_t integ_resp_outer ;                      // area below curve of the phe_response function (in counts * ns)
    89   Float_t sing_resp_outer[ RESPONSE_SLICES_MFADC ] ;   // the shape of the phe_response function
     102  Int_t shape_resp_outer ;  // index shape of the phe_response function
     103                            // = 0 --> Gaussian
     104                            // = 1 --> Pulpo set-up
     105  Float_t fwhm_resp_outer ; // fwhm of the phe_response function (in ns)
     106  Float_t integ_resp_outer; // area below curve of the phe_response function (in counts * ns)
     107  Float_t *sing_resp_outer; // the shape of the phe_response function
     108
     109
    90110  //
    91111  //   RandomGenerator for the Electonic Noise
     
    98118                            // in the trigger pixels.
    99119
    100 
    101120public:
    102121
    103   MFadc(Int_t pix=577,
    104         Int_t shape=0,
    105         Float_t ampl=MFADC_RESPONSE_INTEGRAL,
    106         Float_t fwhm=MFADC_RESPONSE_FWHM,
    107         Int_t shapeout=0,
    108         Float_t amplout=MFADC_RESPONSE_INTEGRAL,
    109         Float_t fwhmout=MFADC_RESPONSE_FWHM,
    110         Float_t trig_delay=0.) ;
     122  MFadc(Int_t pix = 577,
     123        Int_t shape = 0,
     124        Float_t ampl = MFADC_RESPONSE_INTEGRAL,
     125        Float_t fwhm = MFADC_RESPONSE_FWHM,
     126        Int_t shapeout = 0,
     127        Float_t amplout = MFADC_RESPONSE_INTEGRAL,
     128        Float_t fwhmout = MFADC_RESPONSE_FWHM,
     129        Float_t trig_delay = 0.,
     130        Float_t fadc_slices_per_ns = FADC_SLICES_PER_NSEC,
     131        Int_t   fadc_slices_written = FADC_SLICES);
    111132 
    112133  void SetSeed(UInt_t seed)  {GenElec->SetSeed(seed);}
     
    120141  void FillOuter( Int_t, Float_t, Float_t  ) ; 
    121142
    122   void Set( Int_t iPix, Float_t res[(Int_t) SLICES_MFADC]);
    123 
    124   void AddSignal( Int_t iPix, Float_t res[(Int_t) SLICES_MFADC]);
     143  void Set( Int_t iPix, Float_t *res);
     144  void AddSignal( Int_t iPix, Float_t *res);
    125145
    126146  void SetPedestals( Int_t ped);
     
    185205  void SetHigh2LowGain(Float_t h2l) {high2low_gain=h2l;}
    186206
    187   Float_t GetShape() {
     207  Int_t GetShape() {
    188208    return shape_resp;
    189209  }
     
    205225  }
    206226
     227  Float_t GetFadcSlicesPerNanosec() {
     228    return fFadcSlicesPerNanosec;
     229  }
     230
     231  Int_t GetResponseSlicesFadc() {
     232    return fResponseSlicesFadc;
     233  }
     234
    207235  Bool_t IsPixelUsed(UInt_t p){
    208236    return used[p];
Note: See TracChangeset for help on using the changeset viewer.