Re: [ROOT] problems in random number generation

From: Rene Brun (Rene.Brun@cern.ch)
Date: Fri Apr 12 2002 - 08:45:46 MEST


It seems that you call
   gROOT->Reset();
in a named macro. This will erase all previous definitions of global variables.

Note that ROOT includes random number generator classes. see TRandom, TRandom3.

Rene Brun

Subhendu Chakrabarti wrote:
> 
> Hi
> I wrote a root-macro for generating random numbers with a gaussian
> distribution in which i used RAND_MAX for normalization.
> The macro runs correctly for first time execution. Afterwards it shows
> an error like this,
> *******************************************************************
> Error: No symbol RAND_MAX in current scope FILE:ran1.C LINE:18
> *** Interpreter error recovered ***
> *******************************************************************
> and is stopping execution.Only working solution is to restart
> root again.
> Please inform me how can i run the macro as many times without quiting
> root again and again.
> 
> Subhendu Chakrabarti
>



This archive was generated by hypermail 2b29 : Sat Jan 04 2003 - 23:50:49 MET