Instantiations of class template uniform_on_sphere model a . More...
#include <uniform_on_sphere.hpp>
Classes | |
class | param_type |
Public Types | |
typedef RealType | input_type |
typedef Cont | result_type |
Public Member Functions | |
uniform_on_sphere (int dim_arg=2) | |
Constructs a uniform_on_sphere distribution. More... | |
uniform_on_sphere (const param_type &parm) | |
Constructs a uniform_on_sphere distribution from its parameters. More... | |
int | dim () const |
Returns the dimension of the sphere. More... | |
param_type | param () const |
Returns the parameters of the distribution. More... | |
void | param (const param_type &parm) |
Sets the parameters of the distribution. More... | |
result_type min | BOOST_PREVENT_MACRO_SUBSTITUTION () const |
Returns the smallest value that the distribution can produce. More... | |
result_type max | BOOST_PREVENT_MACRO_SUBSTITUTION () const |
Returns the largest value that the distribution can produce. More... | |
void | reset () |
Effects: Subsequent uses of the distribution do not depend on values produced by any engine prior to invoking reset. More... | |
template<class Engine > | |
const result_type & | operator() (Engine &eng) |
Returns a point uniformly distributed over the surface of a sphere of dimension dim(). More... | |
template<class Engine > | |
result_type | operator() (Engine &eng, const param_type &parm) const |
Returns a point uniformly distributed over the surface of a sphere of dimension param.dim(). More... | |
BOOST_RANDOM_DETAIL_OSTREAM_OPERATOR (os, uniform_on_sphere, sd) | |
Writes the distribution to a std::ostream . More... | |
BOOST_RANDOM_DETAIL_ISTREAM_OPERATOR (is, uniform_on_sphere, sd) | |
Reads the distribution from a std::istream . More... | |
BOOST_RANDOM_DETAIL_EQUALITY_OPERATOR (uniform_on_sphere, lhs, rhs) | |
Returns true if the two distributions will produce identical sequences of values, given equal generators. More... | |
Instantiations of class template uniform_on_sphere model a .
Such a distribution produces random numbers uniformly distributed on the unit sphere of arbitrary dimension dim
. The Cont
template parameter must be a STL-like container type with begin and end operations returning non-const ForwardIterators of type Cont::iterator
.
typedef RealType boost::random::uniform_on_sphere< RealType, Cont >::input_type |
typedef Cont boost::random::uniform_on_sphere< RealType, Cont >::result_type |
|
inlineexplicit |
Constructs a uniform_on_sphere
distribution.
dim
is the dimension of the sphere.
Requires: dim >= 0
Referenced by boost::random::uniform_on_sphere< RealType, Cont >::operator()().
|
inlineexplicit |
Constructs a uniform_on_sphere
distribution from its parameters.
|
inline |
Returns the smallest value that the distribution can produce.
Note that this is required to approximate the standard library's requirements. The behavior is defined according to lexicographical comparison so that for a container type of std::vector, dist.min() <= x <= dist.max() where x is any value produced by the distribution.
|
inline |
Returns the largest value that the distribution can produce.
Note that this is required to approximate the standard library's requirements. The behavior is defined according to lexicographical comparison so that for a container type of std::vector, dist.min() <= x <= dist.max() where x is any value produced by the distribution.
|
inline |
Returns true if the two distributions will produce identical sequences of values, given equal generators.
|
inline |
Reads the distribution from a std::istream
.
|
inline |
Writes the distribution to a std::ostream
.
|
inline |
Returns the dimension of the sphere.
|
inline |
Returns a point uniformly distributed over the surface of a sphere of dimension dim().
References boost::bind2nd(), boost::it, boost::geometry::math::sqrt(), boost::fusion::transform(), boost::phoenix::val(), boost::flyweights::x, and boost::polygon::y().
|
inline |
Returns a point uniformly distributed over the surface of a sphere of dimension param.dim().
References boost::random::uniform_on_sphere< RealType, Cont >::uniform_on_sphere().
|
inline |
Returns the parameters of the distribution.
References boost::random::uniform_on_sphere< RealType, Cont >::param_type::param_type().
|
inline |
Sets the parameters of the distribution.
References boost::random::uniform_on_sphere< RealType, Cont >::param_type::dim().
|
inline |
Effects: Subsequent uses of the distribution do not depend on values produced by any engine prior to invoking reset.