Bayeux  3.4.1
Core Foundation library for SuperNEMO
Public Member Functions | Static Public Attributes | List of all members
mygsl::von_neumann_method Class Reference

Von Neumann's rejection method for one dimensional PDF. More...

#include <bayeux/mygsl/von_neumann_method.h>

Public Member Functions

bool is_initialized () const
 
double get_xmin () const
 
double get_xmax () const
 
double get_fmax () const
 
size_t get_max_counts () const
 
 von_neumann_method ()
 
 von_neumann_method (double xmin_, double xmax_, const i_unary_function &func_, double fmax_=0.0, size_t nsamples_=DEFAULT_NSAMPLES, size_t max_counts_=DEFAULT_MAX_COUNTS)
 
void initialize (double xmin_, double xmax_, const i_unary_function &func_, double fmax_, size_t nsamples_, size_t max_counts_)
 
void init (double xmin_, double xmax_, const i_unary_function &func_, double fmax_, size_t nsamples_=DEFAULT_NSAMPLES, size_t max_counts_=DEFAULT_MAX_COUNTS)
 
void reset ()
 
double shoot (rng &)
 
void dump (std::ostream &out_=std::clog) const
 

Static Public Attributes

static const double AUTO_FMAX
 
static const size_t MIN_NSAMPLES = 2
 
static const size_t DEFAULT_NSAMPLES = 1000
 
static const size_t DEFAULT_MAX_COUNTS = 10000
 
static const size_t NO_MAX_COUNTS = 0
 

Detailed Description

Von Neumann's rejection method for one dimensional PDF.

Constructor & Destructor Documentation

◆ von_neumann_method() [1/2]

mygsl::von_neumann_method::von_neumann_method ( )

◆ von_neumann_method() [2/2]

mygsl::von_neumann_method::von_neumann_method ( double  xmin_,
double  xmax_,
const i_unary_function func_,
double  fmax_ = 0.0,
size_t  nsamples_ = DEFAULT_NSAMPLES,
size_t  max_counts_ = DEFAULT_MAX_COUNTS 
)

Member Function Documentation

◆ dump()

void mygsl::von_neumann_method::dump ( std::ostream &  out_ = std::clog) const

◆ get_fmax()

double mygsl::von_neumann_method::get_fmax ( ) const

◆ get_max_counts()

size_t mygsl::von_neumann_method::get_max_counts ( ) const

◆ get_xmax()

double mygsl::von_neumann_method::get_xmax ( ) const

◆ get_xmin()

double mygsl::von_neumann_method::get_xmin ( ) const

◆ init()

void mygsl::von_neumann_method::init ( double  xmin_,
double  xmax_,
const i_unary_function func_,
double  fmax_,
size_t  nsamples_ = DEFAULT_NSAMPLES,
size_t  max_counts_ = DEFAULT_MAX_COUNTS 
)

◆ initialize()

void mygsl::von_neumann_method::initialize ( double  xmin_,
double  xmax_,
const i_unary_function func_,
double  fmax_,
size_t  nsamples_,
size_t  max_counts_ 
)

◆ is_initialized()

bool mygsl::von_neumann_method::is_initialized ( ) const

◆ reset()

void mygsl::von_neumann_method::reset ( )

◆ shoot()

double mygsl::von_neumann_method::shoot ( rng )

Member Data Documentation

◆ AUTO_FMAX

const double mygsl::von_neumann_method::AUTO_FMAX
static

◆ DEFAULT_MAX_COUNTS

const size_t mygsl::von_neumann_method::DEFAULT_MAX_COUNTS = 10000
static

◆ DEFAULT_NSAMPLES

const size_t mygsl::von_neumann_method::DEFAULT_NSAMPLES = 1000
static

◆ MIN_NSAMPLES

const size_t mygsl::von_neumann_method::MIN_NSAMPLES = 2
static

◆ NO_MAX_COUNTS

const size_t mygsl::von_neumann_method::NO_MAX_COUNTS = 0
static

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