// This code implementation is the intellectual property of // the GEANT4 collaboration. // // By copying, distributing or modifying the Program (or any work // based on the Program) you indicate your acceptance of this statement, // and all its terms. // // $Id: G4ShootBitTest.cc,v 1.4 1999/12/15 14:50:29 gunter Exp $ // GEANT4 tag $Name: geant4-01-01 $ // // // Tests RandFlat::fireBit() member function // Peter Urban, 5th Sep 1996 #include "G4ios.hh" #include "g4std/iomanip" #include "Randomize.hh" #include "G4Timer.hh" int main() { HepRandomEngine* e= HepRandom::getTheEngine(); RandFlat r(*e); const long NumTest= 10000; G4cout << "Printed value: (relative frequency - probability)" << G4endl; G4cout << NumTest << " random numbers" << G4endl << G4endl; long sum= 0; long i, j; for (i=0; i