RandGamma.icc

Go to the documentation of this file.
00001 // $Id:$
00002 // -*- C++ -*-
00003 // 
00004 // -----------------------------------------------------------------------
00005 //                            HEP Random
00006 //                         --- RandGamma ---
00007 //                 inlined functions implementation file
00008 // -----------------------------------------------------------------------
00009  
00010 // =======================================================================
00011 // Gabriele Cosmo - Created: 19th August 1998
00012 // =======================================================================
00013 
00014 namespace CLHEP {
00015 
00016 inline RandGamma::RandGamma(HepRandomEngine & anEngine, double k,
00017                                                         double lambda )
00018 : HepRandom(), localEngine(&anEngine, do_nothing_deleter()),
00019   defaultK(k), defaultLambda(lambda) {}
00020 
00021 inline RandGamma::RandGamma(HepRandomEngine * anEngine, double k,
00022                                                         double lambda )
00023 : HepRandom(), localEngine(anEngine),
00024   defaultK(k), defaultLambda(lambda) {}
00025 
00026 inline double RandGamma::shoot() {
00027   return shoot( 1.0, 1.0 );
00028 }
00029 
00030 inline double RandGamma::shoot( HepRandomEngine* anEngine ) {
00031   return shoot( anEngine, 1.0, 1.0 );
00032 }
00033 
00034 inline double RandGamma::operator()() {
00035   return fire( defaultK, defaultLambda );
00036 }
00037 
00038 inline double RandGamma::operator()( double k, double lambda ) {
00039   return fire( k, lambda );
00040 }
00041 
00042 inline double RandGamma::fire() {
00043   return fire( defaultK, defaultLambda );
00044 }
00045 
00046 }  // namespace CLHEP

Generated on Mon May 27 17:50:33 2013 for Geant4 by  doxygen 1.4.7