|
ROL
|
#include <ROL_MonteCarloGenerator.hpp>
Inheritance diagram for ROL::MonteCarloGenerator< Real >:Public Member Functions | |
| MonteCarloGenerator (int nSamp, const std::vector< Ptr< Distribution< Real >>> &dist, const Ptr< BatchManager< Real >> &bman, bool use_SA=false, bool adaptive=false, int numNewSamps=0, int seed=123454321) | |
| MonteCarloGenerator (int nSamp, std::vector< std::vector< Real >> &bounds, const Ptr< BatchManager< Real >> &bman, bool use_SA=false, bool adaptive=false, int numNewSamps=0, int seed=123454321) | |
| MonteCarloGenerator (int nSamp, const std::vector< Real > &mean, const std::vector< Real > &std, const Ptr< BatchManager< Real >> &bman, bool use_SA=false, bool adaptive=false, int numNewSamps=0, int seed=123454321) | |
| void | update (const Vector< Real > &x) override |
| Real | computeError (std::vector< Real > &vals) override |
| Real | computeError (std::vector< Ptr< Vector< Real >>> &vals, const Vector< Real > &x) override |
| void | refine (void) override |
| int | numGlobalSamples (void) const override |
Public Member Functions inherited from ROL::SampleGenerator< Real > | |
| virtual | ~SampleGenerator () |
| SampleGenerator (const ROL::Ptr< BatchManager< Real > > &bman) | |
| SampleGenerator (const SampleGenerator< Real > &sampler) | |
| virtual int | start (void) |
| virtual Real | computeError (std::vector< ROL::Ptr< Vector< Real > > > &vals, const Vector< Real > &x) |
| virtual void | setSamples (bool inConstructor=false) |
| virtual int | numMySamples (void) const |
| virtual std::vector< Real > | getMyPoint (const int i) const |
| virtual Real | getMyWeight (const int i) const |
| int | batchID (void) const |
| int | numBatches (void) const |
| void | sumAll (Real *input, Real *output, int dim) const |
| void | sumAll (Vector< Real > &input, Vector< Real > &output) const |
| void | broadcast (Real *input, int cnt, int root) const |
| void | barrier (void) const |
| const ROL::Ptr< BatchManager < Real > > | getBatchManager (void) const |
| void | print (const std::string &filename="samples", const int prec=12) const |
Private Member Functions | |
| Real | ierf (Real input) const |
| Real | random (void) const |
| std::vector< std::vector< Real > > | sample (int nSamp, bool store=true, bool refine=false) |
Private Attributes | |
| std::vector< std::vector< Real > > | data_ |
| const std::vector< Ptr < Distribution< Real > > > | dist_ |
| int | nSamp_ |
| const bool | use_normal_ |
| const bool | use_SA_ |
| const bool | adaptive_ |
| const int | numNewSamps_ |
| const bool | useDist_ |
| const int | seed_ |
| Real | sum_val_ |
| Real | sum_val2_ |
| Real | sum_ng_ |
| Real | sum_ng2_ |
Additional Inherited Members | |
Protected Member Functions inherited from ROL::SampleGenerator< Real > | |
| void | setPoints (std::vector< std::vector< Real > > &p) |
| void | setWeights (std::vector< Real > &w) |
Definition at line 19 of file ROL_MonteCarloGenerator.hpp.
| ROL::MonteCarloGenerator< Real >::MonteCarloGenerator | ( | int | nSamp, |
| const std::vector< Ptr< Distribution< Real >>> & | dist, | ||
| const Ptr< BatchManager< Real >> & | bman, | ||
| bool | use_SA = false, |
||
| bool | adaptive = false, |
||
| int | numNewSamps = 0, |
||
| int | seed = 123454321 |
||
| ) |
Definition at line 93 of file ROL_MonteCarloGeneratorDef.hpp.
References ROL::MonteCarloGenerator< Real >::nSamp_, ROL::SampleGenerator< Real >::numBatches(), and ROL::MonteCarloGenerator< Real >::sample().
| ROL::MonteCarloGenerator< Real >::MonteCarloGenerator | ( | int | nSamp, |
| std::vector< std::vector< Real >> & | bounds, | ||
| const Ptr< BatchManager< Real >> & | bman, | ||
| bool | use_SA = false, |
||
| bool | adaptive = false, |
||
| int | numNewSamps = 0, |
||
| int | seed = 123454321 |
||
| ) |
Definition at line 117 of file ROL_MonteCarloGeneratorDef.hpp.
References ROL::MonteCarloGenerator< Real >::data_, dim, ROL::MonteCarloGenerator< Real >::nSamp_, ROL::SampleGenerator< Real >::numBatches(), and ROL::MonteCarloGenerator< Real >::sample().
| ROL::MonteCarloGenerator< Real >::MonteCarloGenerator | ( | int | nSamp, |
| const std::vector< Real > & | mean, | ||
| const std::vector< Real > & | std, | ||
| const Ptr< BatchManager< Real >> & | bman, | ||
| bool | use_SA = false, |
||
| bool | adaptive = false, |
||
| int | numNewSamps = 0, |
||
| int | seed = 123454321 |
||
| ) |
Definition at line 152 of file ROL_MonteCarloGeneratorDef.hpp.
References ROL::MonteCarloGenerator< Real >::data_, dim, ROL::MonteCarloGenerator< Real >::nSamp_, and ROL::SampleGenerator< Real >::numBatches().
|
private |
Definition at line 16 of file ROL_MonteCarloGeneratorDef.hpp.
References ROL::ScalarTraits< Real >::pi(), and zero.
|
private |
Definition at line 38 of file ROL_MonteCarloGeneratorDef.hpp.
|
private |
Definition at line 43 of file ROL_MonteCarloGeneratorDef.hpp.
References ROL::SampleGenerator< Real >::batchID(), ROL::SampleGenerator< Real >::broadcast(), dim, ROL::SampleGenerator< Real >::numBatches(), random(), ROL::SampleGenerator< Real >::setPoints(), ROL::SampleGenerator< Real >::setWeights(), and zero.
Referenced by ROL::MonteCarloGenerator< Real >::MonteCarloGenerator().
|
overridevirtual |
Reimplemented from ROL::SampleGenerator< Real >.
Definition at line 180 of file ROL_MonteCarloGeneratorDef.hpp.
References ROL::update().
|
overridevirtual |
Reimplemented from ROL::SampleGenerator< Real >.
Definition at line 190 of file ROL_MonteCarloGeneratorDef.hpp.
References zero.
|
override |
Definition at line 219 of file ROL_MonteCarloGeneratorDef.hpp.
References zero.
|
overridevirtual |
Reimplemented from ROL::SampleGenerator< Real >.
Definition at line 251 of file ROL_MonteCarloGeneratorDef.hpp.
|
overridevirtual |
Reimplemented from ROL::SampleGenerator< Real >.
Definition at line 267 of file ROL_MonteCarloGeneratorDef.hpp.
|
private |
Definition at line 21 of file ROL_MonteCarloGenerator.hpp.
Referenced by ROL::MonteCarloGenerator< Real >::MonteCarloGenerator().
|
private |
Definition at line 22 of file ROL_MonteCarloGenerator.hpp.
|
private |
Definition at line 24 of file ROL_MonteCarloGenerator.hpp.
Referenced by ROL::MonteCarloGenerator< Real >::MonteCarloGenerator().
|
private |
Definition at line 25 of file ROL_MonteCarloGenerator.hpp.
|
private |
Definition at line 26 of file ROL_MonteCarloGenerator.hpp.
|
private |
Definition at line 27 of file ROL_MonteCarloGenerator.hpp.
|
private |
Definition at line 28 of file ROL_MonteCarloGenerator.hpp.
|
private |
Definition at line 29 of file ROL_MonteCarloGenerator.hpp.
|
private |
Definition at line 30 of file ROL_MonteCarloGenerator.hpp.
|
private |
Definition at line 32 of file ROL_MonteCarloGenerator.hpp.
|
private |
Definition at line 33 of file ROL_MonteCarloGenerator.hpp.
|
private |
Definition at line 34 of file ROL_MonteCarloGenerator.hpp.
|
private |
Definition at line 35 of file ROL_MonteCarloGenerator.hpp.
1.8.5