GNU Octave  4.4.1
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
rand.cc File Reference
#include <ctime>
#include <unordered_map>
#include <string>
#include "f77-fcn.h"
#include "lo-mappers.h"
#include "oct-rand.h"
#include "quit.h"
#include "defun.h"
#include "error.h"
#include "errwarn.h"
#include "ovl.h"
#include "unwind-prot.h"
#include "utils.h"
#include "ov-re-mat.h"
Include dependency graph for rand.cc:

Go to the source code of this file.

Functions

static octave_value do_rand (const octave_value_list &args, int nargin, const char *fcn, const std::string &distribution, bool additional_arg=false)
 
OCTAVE_EXPORT octave_value_list Frand (const octave_value_list &args, int) you can restore the random number generator to the state ar
 
OCTAVE_EXPORT octave_value_list Frandn (const octave_value_list &args, int) ode
 

Variables

static std::string current_distribution = octave_rand::distribution ()
 
uses the ite {Ziggurat Method for Generating Random Variables}
 
uses the ospell {Marsaglia and Tsang} ``Ziggurat technique'' to transform from a uniform to a normal distribution. The class of the value returned can be controlled by a trailing code{"double"} or code{"single"} argument. These are the only valid classes. Reference: ospell{G. Marsaglia and W.W. Tsang}
 
uses the J Statistical Software
 
uses the J Statistical vol
 

Function Documentation

◆ do_rand()

◆ Frand()

OCTAVE_EXPORT octave_value_list Frand ( const octave_value_list args,
int   
)

Definition at line 448 of file rand.cc.

References do_rand().

◆ Frandn()

OCTAVE_EXPORT octave_value_list Frandn ( const octave_value_list args,
int   
)

Definition at line 574 of file rand.cc.

Variable Documentation

◆ current_distribution

std::string current_distribution = octave_rand::distribution ()
static

Definition at line 541 of file rand.cc.

◆ ite

uses the ite {Ziggurat Method for Generating Random Variables}

Definition at line 574 of file rand.cc.

◆ ospell

uses the ospell {Marsaglia and Tsang} ``Ziggurat technique'' to transform from a uniform to a normal distribution. The class of the value returned can be controlled by a trailing code{"double"} or code{"single"} argument. These are the only valid classes. Reference: ospell{G. Marsaglia and W.W. Tsang}

Definition at line 574 of file rand.cc.

◆ Software

uses the J Statistical Software

Definition at line 574 of file rand.cc.

◆ vol

uses the J Statistical vol

Definition at line 574 of file rand.cc.