...one of the most highly
regarded and expertly designed C++ library projects in the
world.
— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards
All math functions and distributions are in namespace
boost::math
.
So, for example, the Students-t distribution template in namespace
boost::math
is
template <class RealType> class students_t_distribution
and can be instantiated with the help of the reserved name students_t
(for
RealType double
)
typedef students_t_distribution<double> students_t; student_t mydist(10);
Warning | |
---|---|
Some distribution names are also used in std random library, so to avoid
the risk of ambiguity it is better to make explicit using declarations, for
example: |
Functions not intended for use by applications are in boost::math::detail
.
Functions that may have more general use, like digits
(significand), max_value
,
min_value
and epsilon
are in boost::math::tools
.
Policy and configuration information is in namespace
boost::math::policies
.
Tip | |
---|---|
Many code snippets assume implicit namespace(s), for example, |
Tip | |
---|---|
Start your work from a copy of the example source code; links usually provided. |