npstat is hosted by Hepforge, IPPP Durham
NPStat  5.10.0
npstat::WrappedRandomGen Class Reference

#include <AbsRandomGenerator.hh>

Inheritance diagram for npstat::WrappedRandomGen:
npstat::AbsRandomGenerator

Public Member Functions

 WrappedRandomGen (double(*fcn)())
 
unsigned dim () const
 
double operator() ()
 
- Public Member Functions inherited from npstat::AbsRandomGenerator
virtual unsigned long long maxPoints () const
 
virtual void run (double *buf, const unsigned bufLen, const unsigned nPt)
 

Detailed Description

Wrapper for functions which look like "double generate()", for example, "drand48" from cstdlib on Linux.

Member Function Documentation

◆ dim()

unsigned npstat::WrappedRandomGen::dim ( ) const
inlinevirtual

Dimensionality of the generated vectors (or points). It is expected that "dim()" will always be 1 for pseudo-random (as opposed to quasi-random) generators.

Implements npstat::AbsRandomGenerator.

◆ operator()()

double npstat::WrappedRandomGen::operator() ( )
inlinevirtual

Standard 1-d generator function. It should generate a run-time error for essentially multivariate generators whose dimensionality is larger than 1.

Implements npstat::AbsRandomGenerator.


The documentation for this class was generated from the following file: