From bb1931edecf55a935c756ff72dbc87cef3f32dbc Mon Sep 17 00:00:00 2001 From: John Maddock Date: Mon, 20 Aug 2007 12:43:32 +0000 Subject: [PATCH] Changed "policy" directory to "policies" to match the namespace name. [SVN r38780] --- example/error_policies_example.cpp | 2 +- example/policy_eg_8.cpp | 2 +- include/boost/math/concepts/real_concept.hpp | 2 +- .../boost/math/concepts/std_real_concept.hpp | 2 +- .../detail/common_error_handling.hpp | 2 +- .../math/distributions/negative_binomial.hpp | 30 +++++++++---------- .../{policy => policies}/error_handling.hpp | 2 +- .../math/{policy => policies}/policy.hpp | 0 .../boost/math/special_functions/acosh.hpp | 2 +- .../boost/math/special_functions/atanh.hpp | 2 +- .../boost/math/special_functions/binomial.hpp | 2 +- .../special_functions/detail/bessel_ik.hpp | 2 +- .../special_functions/detail/bessel_jy.hpp | 2 +- .../special_functions/detail/bessel_k0.hpp | 2 +- .../special_functions/detail/bessel_k1.hpp | 2 +- .../special_functions/detail/bessel_kn.hpp | 2 +- .../special_functions/detail/bessel_y0.hpp | 2 +- .../special_functions/detail/bessel_y1.hpp | 2 +- .../special_functions/detail/bessel_yn.hpp | 2 +- .../detail/igamma_inverse.hpp | 2 +- .../boost/math/special_functions/digamma.hpp | 2 +- .../boost/math/special_functions/ellint_1.hpp | 2 +- .../boost/math/special_functions/ellint_2.hpp | 2 +- .../boost/math/special_functions/ellint_3.hpp | 2 +- .../math/special_functions/ellint_rc.hpp | 2 +- .../math/special_functions/ellint_rd.hpp | 2 +- .../math/special_functions/ellint_rf.hpp | 2 +- .../math/special_functions/ellint_rj.hpp | 2 +- include/boost/math/special_functions/erf.hpp | 2 +- .../boost/math/special_functions/expm1.hpp | 2 +- .../boost/math/special_functions/gamma.hpp | 2 +- .../boost/math/special_functions/hermite.hpp | 2 +- .../boost/math/special_functions/hypot.hpp | 2 +- .../boost/math/special_functions/laguerre.hpp | 2 +- .../boost/math/special_functions/lanczos.hpp | 2 +- .../boost/math/special_functions/log1p.hpp | 2 +- .../boost/math/special_functions/math_fwd.hpp | 2 +- include/boost/math/special_functions/sinc.hpp | 2 +- include/boost/math/tools/minima.hpp | 2 +- include/boost/math/tools/ntl.hpp | 2 +- include/boost/math/tools/precision.hpp | 2 +- include/boost/math/tools/remez.hpp | 2 +- include/boost/math/tools/roots.hpp | 2 +- include/boost/math/tools/toms748_solve.hpp | 2 +- performance/main.cpp | 2 +- test/test_error_handling.cpp | 4 +-- test/test_policy.cpp | 2 +- 47 files changed, 61 insertions(+), 61 deletions(-) rename include/boost/math/{policy => policies}/error_handling.hpp (99%) rename include/boost/math/{policy => policies}/policy.hpp (100%) diff --git a/example/error_policies_example.cpp b/example/error_policies_example.cpp index 4095be96f..bb08a2833 100644 --- a/example/error_policies_example.cpp +++ b/example/error_policies_example.cpp @@ -17,7 +17,7 @@ // using namespace boost::math; //.\error_policy_normal.cpp(30) : error C2872: 'policy' : ambiguous symbol -// could be 'I:\Boost-sandbox\math_toolkit\boost/math/policy/policy.hpp(392) : boost::math::policies::policy' +// could be 'I:\Boost-sandbox\math_toolkit\boost/math/policies/policy.hpp(392) : boost::math::policies::policy' // or 'boost::math::policies' // So can't use this using namespace command. diff --git a/example/policy_eg_8.cpp b/example/policy_eg_8.cpp index e99702a7a..469f3a778 100644 --- a/example/policy_eg_8.cpp +++ b/example/policy_eg_8.cpp @@ -17,7 +17,7 @@ any of the default ones supplied by the library to be used. If we set the policy for a specific type of error to `user_error` then the library will call a user-supplied error handler. These are forward declared, but not defined in -boost/math/policy/error_handling.hpp like this: +boost/math/policies/error_handling.hpp like this: namespace boost{ namespace math{ namespace policy{ diff --git a/include/boost/math/concepts/real_concept.hpp b/include/boost/math/concepts/real_concept.hpp index 867d320c0..8c8595c7b 100644 --- a/include/boost/math/concepts/real_concept.hpp +++ b/include/boost/math/concepts/real_concept.hpp @@ -24,7 +24,7 @@ #include #include #include -#include +#include #include #include diff --git a/include/boost/math/concepts/std_real_concept.hpp b/include/boost/math/concepts/std_real_concept.hpp index 2637b8cbb..c215066eb 100644 --- a/include/boost/math/concepts/std_real_concept.hpp +++ b/include/boost/math/concepts/std_real_concept.hpp @@ -20,7 +20,7 @@ #include #include #include -#include +#include #include #include diff --git a/include/boost/math/distributions/detail/common_error_handling.hpp b/include/boost/math/distributions/detail/common_error_handling.hpp index ad87a21de..7a6f8dabf 100644 --- a/include/boost/math/distributions/detail/common_error_handling.hpp +++ b/include/boost/math/distributions/detail/common_error_handling.hpp @@ -9,7 +9,7 @@ #ifndef BOOST_MATH_DISTRIBUTIONS_COMMON_ERROR_HANDLING_HPP #define BOOST_MATH_DISTRIBUTIONS_COMMON_ERROR_HANDLING_HPP -#include +#include #include #ifdef BOOST_MSVC diff --git a/include/boost/math/distributions/negative_binomial.hpp b/include/boost/math/distributions/negative_binomial.hpp index 8fdb658cc..852def73a 100644 --- a/include/boost/math/distributions/negative_binomial.hpp +++ b/include/boost/math/distributions/negative_binomial.hpp @@ -232,22 +232,22 @@ namespace boost return result + k; } // RealType find_number_of_failures - //static RealType find_maximum_number_of_trials( - // RealType k, // number of failures (k >= 0). - // RealType p, // success fraction 0 <= p <= 1. - // RealType alpha) // risk level threshold 0 <= alpha <= 1. - //{ - // static const char* function = "boost::math::negative_binomial<%1%>::estimate_maximum_number_of_trials"; - // // Error checks: - // RealType result; - // if(false == negative_binomial_detail::check_dist_and_k( - // function, RealType(1), p, k, &result, Policy()) - // && detail::check_probability(function, alpha, &result, Policy())) - // { return result; } + static RealType find_maximum_number_of_trials( + RealType k, // number of failures (k >= 0). + RealType p, // success fraction 0 <= p <= 1. + RealType alpha) // risk level threshold 0 <= alpha <= 1. + { + static const char* function = "boost::math::negative_binomial<%1%>::estimate_maximum_number_of_trials"; + // Error checks: + RealType result; + if(false == negative_binomial_detail::check_dist_and_k( + function, RealType(1), p, k, &result, Policy()) + && detail::check_probability(function, alpha, &result, Policy())) + { return result; } - // result = ibetac_inva(k + 1, p, alpha, Policy()); // returns n - k - // return result + k; - //} // RealType find_number_of_trials complemented + result = ibetac_inva(k + 1, p, alpha, Policy()); // returns n - k + return result + k; + } // RealType find_number_of_trials complemented private: RealType m_r; // successes. diff --git a/include/boost/math/policy/error_handling.hpp b/include/boost/math/policies/error_handling.hpp similarity index 99% rename from include/boost/math/policy/error_handling.hpp rename to include/boost/math/policies/error_handling.hpp index 17cc9c7d8..21941cb9a 100644 --- a/include/boost/math/policy/error_handling.hpp +++ b/include/boost/math/policies/error_handling.hpp @@ -15,7 +15,7 @@ #include #include #include -#include +#include #include #include #ifdef BOOST_MSVC diff --git a/include/boost/math/policy/policy.hpp b/include/boost/math/policies/policy.hpp similarity index 100% rename from include/boost/math/policy/policy.hpp rename to include/boost/math/policies/policy.hpp diff --git a/include/boost/math/special_functions/acosh.hpp b/include/boost/math/special_functions/acosh.hpp index 60f051f51..5fa16a807 100644 --- a/include/boost/math/special_functions/acosh.hpp +++ b/include/boost/math/special_functions/acosh.hpp @@ -14,7 +14,7 @@ #include #include #include -#include +#include #include // This is the inverse of the hyperbolic cosine function. diff --git a/include/boost/math/special_functions/atanh.hpp b/include/boost/math/special_functions/atanh.hpp index 11150ab98..35325a3d7 100644 --- a/include/boost/math/special_functions/atanh.hpp +++ b/include/boost/math/special_functions/atanh.hpp @@ -14,7 +14,7 @@ #include #include #include -#include +#include #include // This is the inverse of the hyperbolic tangent function. diff --git a/include/boost/math/special_functions/binomial.hpp b/include/boost/math/special_functions/binomial.hpp index b5dcdab59..21c69c27d 100644 --- a/include/boost/math/special_functions/binomial.hpp +++ b/include/boost/math/special_functions/binomial.hpp @@ -8,7 +8,7 @@ #include #include -#include +#include namespace boost{ namespace math{ diff --git a/include/boost/math/special_functions/detail/bessel_ik.hpp b/include/boost/math/special_functions/detail/bessel_ik.hpp index 5bb6cbc69..4ef42ed85 100644 --- a/include/boost/math/special_functions/detail/bessel_ik.hpp +++ b/include/boost/math/special_functions/detail/bessel_ik.hpp @@ -9,7 +9,7 @@ #include #include #include -#include +#include #include // Modified Bessel functions of the first and second kind of fractional order diff --git a/include/boost/math/special_functions/detail/bessel_jy.hpp b/include/boost/math/special_functions/detail/bessel_jy.hpp index f05392e3a..16063aa23 100644 --- a/include/boost/math/special_functions/detail/bessel_jy.hpp +++ b/include/boost/math/special_functions/detail/bessel_jy.hpp @@ -15,7 +15,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/include/boost/math/special_functions/detail/bessel_k0.hpp b/include/boost/math/special_functions/detail/bessel_k0.hpp index dc73feeb5..811c34eef 100644 --- a/include/boost/math/special_functions/detail/bessel_k0.hpp +++ b/include/boost/math/special_functions/detail/bessel_k0.hpp @@ -7,7 +7,7 @@ #define BOOST_MATH_BESSEL_K0_HPP #include -#include +#include #include // Modified Bessel function of the second kind of order zero diff --git a/include/boost/math/special_functions/detail/bessel_k1.hpp b/include/boost/math/special_functions/detail/bessel_k1.hpp index 805268b1e..c7e85145e 100644 --- a/include/boost/math/special_functions/detail/bessel_k1.hpp +++ b/include/boost/math/special_functions/detail/bessel_k1.hpp @@ -7,7 +7,7 @@ #define BOOST_MATH_BESSEL_K1_HPP #include -#include +#include #include // Modified Bessel function of the second kind of order one diff --git a/include/boost/math/special_functions/detail/bessel_kn.hpp b/include/boost/math/special_functions/detail/bessel_kn.hpp index 1fd3578e9..8d30462e8 100644 --- a/include/boost/math/special_functions/detail/bessel_kn.hpp +++ b/include/boost/math/special_functions/detail/bessel_kn.hpp @@ -8,7 +8,7 @@ #include #include -#include +#include // Modified Bessel function of the second kind of integer order // K_n(z) is the dominant solution, forward recurrence always OK (though unstable) diff --git a/include/boost/math/special_functions/detail/bessel_y0.hpp b/include/boost/math/special_functions/detail/bessel_y0.hpp index 71dc56252..92a34ca88 100644 --- a/include/boost/math/special_functions/detail/bessel_y0.hpp +++ b/include/boost/math/special_functions/detail/bessel_y0.hpp @@ -9,7 +9,7 @@ #include #include #include -#include +#include #include // Bessel function of the second kind of order zero diff --git a/include/boost/math/special_functions/detail/bessel_y1.hpp b/include/boost/math/special_functions/detail/bessel_y1.hpp index 6e70806c3..5e4fd19aa 100644 --- a/include/boost/math/special_functions/detail/bessel_y1.hpp +++ b/include/boost/math/special_functions/detail/bessel_y1.hpp @@ -9,7 +9,7 @@ #include #include #include -#include +#include #include // Bessel function of the second kind of order one diff --git a/include/boost/math/special_functions/detail/bessel_yn.hpp b/include/boost/math/special_functions/detail/bessel_yn.hpp index 57b8c226b..3ae9d12c5 100644 --- a/include/boost/math/special_functions/detail/bessel_yn.hpp +++ b/include/boost/math/special_functions/detail/bessel_yn.hpp @@ -8,7 +8,7 @@ #include #include -#include +#include // Bessel function of the second kind of integer order // Y_n(z) is the dominant solution, forward recurrence always OK (though unstable) diff --git a/include/boost/math/special_functions/detail/igamma_inverse.hpp b/include/boost/math/special_functions/detail/igamma_inverse.hpp index 5638b33c1..7778a7170 100644 --- a/include/boost/math/special_functions/detail/igamma_inverse.hpp +++ b/include/boost/math/special_functions/detail/igamma_inverse.hpp @@ -9,7 +9,7 @@ #include #include #include -#include +#include #include namespace boost{ namespace math{ diff --git a/include/boost/math/special_functions/digamma.hpp b/include/boost/math/special_functions/digamma.hpp index e10784cf8..56268c400 100644 --- a/include/boost/math/special_functions/digamma.hpp +++ b/include/boost/math/special_functions/digamma.hpp @@ -8,7 +8,7 @@ #include #include -#include +#include #include #include diff --git a/include/boost/math/special_functions/ellint_1.hpp b/include/boost/math/special_functions/ellint_1.hpp index cba76643a..1a49530ac 100644 --- a/include/boost/math/special_functions/ellint_1.hpp +++ b/include/boost/math/special_functions/ellint_1.hpp @@ -16,7 +16,7 @@ #include #include -#include +#include // Elliptic integrals (complete and incomplete) of the first kind // Carlson, Numerische Mathematik, vol 33, 1 (1979) diff --git a/include/boost/math/special_functions/ellint_2.hpp b/include/boost/math/special_functions/ellint_2.hpp index fc42ccad7..651602d2b 100644 --- a/include/boost/math/special_functions/ellint_2.hpp +++ b/include/boost/math/special_functions/ellint_2.hpp @@ -17,7 +17,7 @@ #include #include #include -#include +#include // Elliptic integrals (complete and incomplete) of the second kind // Carlson, Numerische Mathematik, vol 33, 1 (1979) diff --git a/include/boost/math/special_functions/ellint_3.hpp b/include/boost/math/special_functions/ellint_3.hpp index 3b619318f..c018b4b19 100644 --- a/include/boost/math/special_functions/ellint_3.hpp +++ b/include/boost/math/special_functions/ellint_3.hpp @@ -20,7 +20,7 @@ #include #include #include -#include +#include // Elliptic integrals (complete and incomplete) of the third kind // Carlson, Numerische Mathematik, vol 33, 1 (1979) diff --git a/include/boost/math/special_functions/ellint_rc.hpp b/include/boost/math/special_functions/ellint_rc.hpp index f0a2ef826..ee3a5fc48 100644 --- a/include/boost/math/special_functions/ellint_rc.hpp +++ b/include/boost/math/special_functions/ellint_rc.hpp @@ -13,7 +13,7 @@ #ifndef BOOST_MATH_ELLINT_RC_HPP #define BOOST_MATH_ELLINT_RC_HPP -#include +#include #include #include diff --git a/include/boost/math/special_functions/ellint_rd.hpp b/include/boost/math/special_functions/ellint_rd.hpp index c7fa3b590..8ffc336e5 100644 --- a/include/boost/math/special_functions/ellint_rd.hpp +++ b/include/boost/math/special_functions/ellint_rd.hpp @@ -13,7 +13,7 @@ #include #include -#include +#include // Carlson's elliptic integral of the second kind // R_D(x, y, z) = R_J(x, y, z, z) = 1.5 * \int_{0}^{\infty} [(t+x)(t+y)]^{-1/2} (t+z)^{-3/2} dt diff --git a/include/boost/math/special_functions/ellint_rf.hpp b/include/boost/math/special_functions/ellint_rf.hpp index 57562a6cc..a413f5dc0 100644 --- a/include/boost/math/special_functions/ellint_rf.hpp +++ b/include/boost/math/special_functions/ellint_rf.hpp @@ -15,7 +15,7 @@ #include #include -#include +#include // Carlson's elliptic integral of the first kind // R_F(x, y, z) = 0.5 * \int_{0}^{\infty} [(t+x)(t+y)(t+z)]^{-1/2} dt diff --git a/include/boost/math/special_functions/ellint_rj.hpp b/include/boost/math/special_functions/ellint_rj.hpp index 17dee4385..b240b0425 100644 --- a/include/boost/math/special_functions/ellint_rj.hpp +++ b/include/boost/math/special_functions/ellint_rj.hpp @@ -15,7 +15,7 @@ #include #include -#include +#include #include // Carlson's elliptic integral of the third kind diff --git a/include/boost/math/special_functions/erf.hpp b/include/boost/math/special_functions/erf.hpp index 69455d0a1..ba8491c41 100644 --- a/include/boost/math/special_functions/erf.hpp +++ b/include/boost/math/special_functions/erf.hpp @@ -10,7 +10,7 @@ #include #include #include -#include +#include namespace boost{ namespace math{ diff --git a/include/boost/math/special_functions/expm1.hpp b/include/boost/math/special_functions/expm1.hpp index 48cc6520c..a4bbf73d7 100644 --- a/include/boost/math/special_functions/expm1.hpp +++ b/include/boost/math/special_functions/expm1.hpp @@ -12,7 +12,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/include/boost/math/special_functions/gamma.hpp b/include/boost/math/special_functions/gamma.hpp index 571bdc1e2..0050bb58b 100644 --- a/include/boost/math/special_functions/gamma.hpp +++ b/include/boost/math/special_functions/gamma.hpp @@ -25,7 +25,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/include/boost/math/special_functions/hermite.hpp b/include/boost/math/special_functions/hermite.hpp index e6d71c4fe..39c297a5b 100644 --- a/include/boost/math/special_functions/hermite.hpp +++ b/include/boost/math/special_functions/hermite.hpp @@ -9,7 +9,7 @@ #include #include -#include +#include namespace boost{ namespace math{ diff --git a/include/boost/math/special_functions/hypot.hpp b/include/boost/math/special_functions/hypot.hpp index db6df6f13..ba97b9937 100644 --- a/include/boost/math/special_functions/hypot.hpp +++ b/include/boost/math/special_functions/hypot.hpp @@ -8,7 +8,7 @@ #include #include -#include +#include #include #include #include // for swap diff --git a/include/boost/math/special_functions/laguerre.hpp b/include/boost/math/special_functions/laguerre.hpp index 6121ac754..d41eafaad 100644 --- a/include/boost/math/special_functions/laguerre.hpp +++ b/include/boost/math/special_functions/laguerre.hpp @@ -9,7 +9,7 @@ #include #include -#include +#include namespace boost{ namespace math{ diff --git a/include/boost/math/special_functions/lanczos.hpp b/include/boost/math/special_functions/lanczos.hpp index f4e6734cc..2f984f615 100644 --- a/include/boost/math/special_functions/lanczos.hpp +++ b/include/boost/math/special_functions/lanczos.hpp @@ -11,7 +11,7 @@ #include #include #include -#include +#include #include #include diff --git a/include/boost/math/special_functions/log1p.hpp b/include/boost/math/special_functions/log1p.hpp index 43c9e80a6..9c9b629b7 100644 --- a/include/boost/math/special_functions/log1p.hpp +++ b/include/boost/math/special_functions/log1p.hpp @@ -11,7 +11,7 @@ #include #include #include -#include +#include #include #ifndef BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS diff --git a/include/boost/math/special_functions/math_fwd.hpp b/include/boost/math/special_functions/math_fwd.hpp index e75d5b125..bf62da794 100644 --- a/include/boost/math/special_functions/math_fwd.hpp +++ b/include/boost/math/special_functions/math_fwd.hpp @@ -20,7 +20,7 @@ #define BOOST_MATH_SPECIAL_MATH_FWD_HPP #include // for argument promotion. -#include +#include #include #include diff --git a/include/boost/math/special_functions/sinc.hpp b/include/boost/math/special_functions/sinc.hpp index 13a409209..19b843d61 100644 --- a/include/boost/math/special_functions/sinc.hpp +++ b/include/boost/math/special_functions/sinc.hpp @@ -13,7 +13,7 @@ #include #include -#include +#include #include #include #include diff --git a/include/boost/math/tools/minima.hpp b/include/boost/math/tools/minima.hpp index ed3a92ed5..694219558 100644 --- a/include/boost/math/tools/minima.hpp +++ b/include/boost/math/tools/minima.hpp @@ -10,7 +10,7 @@ #include #include #include -#include +#include #include namespace boost{ namespace math{ namespace tools{ diff --git a/include/boost/math/tools/ntl.hpp b/include/boost/math/tools/ntl.hpp index 610d8658d..9c17ac055 100644 --- a/include/boost/math/tools/ntl.hpp +++ b/include/boost/math/tools/ntl.hpp @@ -11,7 +11,7 @@ #include #include #include -#include +#include namespace NTL { diff --git a/include/boost/math/tools/precision.hpp b/include/boost/math/tools/precision.hpp index fdeb95637..7424d36c7 100644 --- a/include/boost/math/tools/precision.hpp +++ b/include/boost/math/tools/precision.hpp @@ -12,7 +12,7 @@ #include #include #include -#include +#include #include #include diff --git a/include/boost/math/tools/remez.hpp b/include/boost/math/tools/remez.hpp index f668b317d..ca3d40bf2 100644 --- a/include/boost/math/tools/remez.hpp +++ b/include/boost/math/tools/remez.hpp @@ -13,7 +13,7 @@ #include #include #include -#include +#include namespace boost{ namespace math{ namespace tools{ diff --git a/include/boost/math/tools/roots.hpp b/include/boost/math/tools/roots.hpp index 20ebae469..2ee2008be 100644 --- a/include/boost/math/tools/roots.hpp +++ b/include/boost/math/tools/roots.hpp @@ -26,7 +26,7 @@ #include #include -#include +#include namespace boost{ namespace math{ namespace tools{ diff --git a/include/boost/math/tools/toms748_solve.hpp b/include/boost/math/tools/toms748_solve.hpp index dfca86548..fd7621dc8 100644 --- a/include/boost/math/tools/toms748_solve.hpp +++ b/include/boost/math/tools/toms748_solve.hpp @@ -7,7 +7,7 @@ #define BOOST_MATH_TOOLS_SOLVE_ROOT_HPP #include -#include +#include #include #include #include diff --git a/performance/main.cpp b/performance/main.cpp index c381e8e39..3b5a41c23 100644 --- a/performance/main.cpp +++ b/performance/main.cpp @@ -8,7 +8,7 @@ #include #include #include "performance_measure.hpp" -#include +#include extern void reference_evaluate(); diff --git a/test/test_error_handling.cpp b/test/test_error_handling.cpp index bde15be60..b939cf5b7 100644 --- a/test/test_error_handling.cpp +++ b/test/test_error_handling.cpp @@ -55,8 +55,8 @@ T user_evaluation_error(const char* , const char* , const T& ) }}} // namespaces -#include -#include +#include +#include #include #include // for test_main // diff --git a/test/test_policy.cpp b/test/test_policy.cpp index 8c0b15cd0..241fe26d6 100644 --- a/test/test_policy.cpp +++ b/test/test_policy.cpp @@ -6,7 +6,7 @@ // (See accompanying file LICENSE_1_0.txt // or copy at http://www.boost.org/LICENSE_1_0.txt) -#include +#include #include #include // for test_main