#include <pdf1d_gaussian_sampler.h>
Inheritance diagram for pdf1d_gaussian_sampler:

Definition at line 18 of file pdf1d_gaussian_sampler.h.
Public Member Functions | |
| pdf1d_gaussian_sampler () | |
| Dflt ctor. | |
| virtual | ~pdf1d_gaussian_sampler () |
| Destructor. | |
| virtual void | set_model (const pdf1d_pdf &) |
| Set model for which this is an instance. | |
| virtual double | sample () |
| Draw random sample from Gaussian distribution. | |
| virtual void | regular_samples (vnl_vector< double > &x) |
| Fill x with samples possibly chosen so as to represent the distribution. | |
| virtual void | reseed (unsigned long) |
| Reseeds the internal random number generator. | |
| const pdf1d_gaussian & | gaussian () const |
| Return a reference to the pdf model. | |
| virtual vcl_string | is_a () const |
| Name of the class. | |
| virtual bool | is_class (vcl_string const &s) const |
| Does the name of the class match the argument?. | |
| virtual pdf1d_sampler * | clone () const |
| Create a copy on the heap and return base class pointer. | |
| const pdf1d_pdf & | model () const |
| PDF of which this is an instance. | |
| virtual void | get_samples (vnl_vector< double > &x) |
| Fill x with samples drawn from distribution. | |
| virtual void | regular_samples_and_prob (vnl_vector< double > &x, vnl_vector< double > &p) |
| Fill x with samples possibly chosen so as to represent the distribution. | |
| virtual void | print_summary (vcl_ostream &os) const |
| Print class to os. | |
Protected Attributes | |
| vnl_random | rng_ |
| The random number generator. | |
| const pdf1d_pdf * | pdf_model_ |
|
|
Dflt ctor.
Definition at line 17 of file pdf1d_gaussian_sampler.cxx. |
|
|
Destructor.
Definition at line 26 of file pdf1d_gaussian_sampler.cxx. |
|
|
Create a copy on the heap and return base class pointer.
Implements pdf1d_sampler. Definition at line 53 of file pdf1d_gaussian_sampler.cxx. |
|
|
Return a reference to the pdf model. This is properly cast. Definition at line 110 of file pdf1d_gaussian_sampler.cxx. |
|
|
Fill x with samples drawn from distribution.
Definition at line 45 of file pdf1d_sampler.cxx. |
|
|
Name of the class.
Reimplemented from pdf1d_sampler. Definition at line 35 of file pdf1d_gaussian_sampler.cxx. |
|
|
Does the name of the class match the argument?.
Reimplemented from pdf1d_sampler. Definition at line 44 of file pdf1d_gaussian_sampler.cxx. |
|
|
PDF of which this is an instance.
Definition at line 38 of file pdf1d_sampler.cxx. |
|
|
Print class to os.
Definition at line 101 of file pdf1d_sampler.cxx. |
|
|
Fill x with samples possibly chosen so as to represent the distribution. 5 or fewer samples requested, they are spaced out equally. Reimplemented from pdf1d_sampler. Definition at line 85 of file pdf1d_gaussian_sampler.cxx. |
|
||||||||||||
|
Fill x with samples possibly chosen so as to represent the distribution. As regular_samples(x), but p[i] is set to p(x[i]) Definition at line 65 of file pdf1d_sampler.cxx. |
|
|
Reseeds the internal random number generator. To achieve quasi-random initialisation use; #include <vcl_ctime.h>
..
sampler.reseed(vcl_time(0));
Implements pdf1d_sampler. Definition at line 59 of file pdf1d_gaussian_sampler.cxx. |
|
|
Draw random sample from Gaussian distribution.
Implements pdf1d_sampler. Definition at line 77 of file pdf1d_gaussian_sampler.cxx. |
|
|
Set model for which this is an instance. Error check that it is an axis gaussian. Reimplemented from pdf1d_sampler. Definition at line 67 of file pdf1d_gaussian_sampler.cxx. |
|
|
Definition at line 26 of file pdf1d_sampler.h. |
|
|
The random number generator.
Definition at line 22 of file pdf1d_gaussian_sampler.h. |
1.4.4