diff --git a/.travis.yml b/.travis.yml index edd6515d1..d6fd0b665 100644 --- a/.travis.yml +++ b/.travis.yml @@ -255,6 +255,18 @@ matrix: sources: - ubuntu-toolchain-r-test + - os: linux + env: TOOLSET=gcc COMPILER=g++-6 CXXSTD=c++03 TEST_SUITE=../tools + addons: + apt: + packages: + - g++-6 + - libgmp-dev + - libmpfr-dev + - libfftw3-dev + sources: + - ubuntu-toolchain-r-test + - os: linux env: TOOLSET=gcc COMPILER=g++-6 CXXSTD=c++11 TEST_SUITE=../example//examples addons: @@ -267,6 +279,18 @@ matrix: sources: - ubuntu-toolchain-r-test + - os: linux + env: TOOLSET=gcc COMPILER=g++-6 CXXSTD=c++11 TEST_SUITE=../tools + addons: + apt: + packages: + - g++-6 + - libgmp-dev + - libmpfr-dev + - libfftw3-dev + sources: + - ubuntu-toolchain-r-test + - os: linux env: TOOLSET=gcc COMPILER=g++-6 CXXSTD=c++14 TEST_SUITE=../example//examples addons: @@ -279,6 +303,18 @@ matrix: sources: - ubuntu-toolchain-r-test + - os: linux + env: TOOLSET=gcc COMPILER=g++-6 CXXSTD=c++14 TEST_SUITE=../tools + addons: + apt: + packages: + - g++-6 + - libgmp-dev + - libmpfr-dev + - libfftw3-dev + sources: + - ubuntu-toolchain-r-test + - os: linux env: TOOLSET=gcc COMPILER=g++-6 CXXSTD=gnu++14 TEST_SUITE=../example//examples addons: @@ -291,6 +327,18 @@ matrix: sources: - ubuntu-toolchain-r-test + - os: linux + env: TOOLSET=gcc COMPILER=g++-6 CXXSTD=gnu++14 TEST_SUITE=../tools + addons: + apt: + packages: + - g++-6 + - libgmp-dev + - libmpfr-dev + - libfftw3-dev + sources: + - ubuntu-toolchain-r-test + - os: linux env: TOOLSET=gcc COMPILER=g++-6 CXXSTD=c++1z TEST_SUITE=../example//examples addons: @@ -303,6 +351,18 @@ matrix: sources: - ubuntu-toolchain-r-test + - os: linux + env: TOOLSET=gcc COMPILER=g++-6 CXXSTD=c++1z TEST_SUITE=../tools + addons: + apt: + packages: + - g++-6 + - libgmp-dev + - libmpfr-dev + - libfftw3-dev + sources: + - ubuntu-toolchain-r-test + - os: linux env: TOOLSET=gcc COMPILER=g++-5 CXXSTD=c++14 TEST_SUITE=special_fun addons: @@ -375,6 +435,18 @@ matrix: sources: - ubuntu-toolchain-r-test + - os: linux + env: TOOLSET=gcc COMPILER=g++-5 CXXSTD=c++14 TEST_SUITE=../tools + addons: + apt: + packages: + - g++-5 + - libgmp-dev + - libmpfr-dev + - libfftw3-dev + sources: + - ubuntu-toolchain-r-test + - os: linux dist: trusty compiler: g++-8 @@ -441,6 +513,17 @@ matrix: sources: - ubuntu-toolchain-r-test + - os: linux + dist: trusty + compiler: g++-8 + env: TOOLSET=gcc COMPILER=g++-8 CXXSTD=c++14 TEST_SUITE=../tools + addons: + apt: + packages: + - g++-8 + sources: + - ubuntu-toolchain-r-test + - os: linux dist: trusty compiler: g++-8 @@ -507,6 +590,17 @@ matrix: sources: - ubuntu-toolchain-r-test + - os: linux + dist: trusty + compiler: g++-8 + env: TOOLSET=gcc COMPILER=g++-8 CXXSTD=gnu++03 TEST_SUITE=../tools + addons: + apt: + packages: + - g++-8 + sources: + - ubuntu-toolchain-r-test + - os: linux dist: trusty compiler: g++-8 @@ -562,6 +656,17 @@ matrix: sources: - ubuntu-toolchain-r-test + - os: linux + dist: trusty + compiler: g++-8 + env: TOOLSET=gcc COMPILER=g++-8 CXXSTD=gnu++17 TEST_SUITE=../tools + addons: + apt: + packages: + - g++-8 + sources: + - ubuntu-toolchain-r-test + - os: linux compiler: clang++-6.0 env: TOOLSET=clang COMPILER=clang++-6.0 CXXSTD=c++11 TEST_SUITE=special_fun @@ -617,6 +722,17 @@ matrix: - ubuntu-toolchain-r-test - llvm-toolchain-xenial-6.0 + - os: linux + compiler: clang++-6.0 + env: TOOLSET=clang COMPILER=clang++-6.0 CXXSTD=c++11 TEST_SUITE=../tools + addons: + apt: + packages: + - clang-6.0 + sources: + - ubuntu-toolchain-r-test + - llvm-toolchain-xenial-6.0 + - os: osx env: TOOLSET=clang COMPILER=clang++ CXXSTD=c++14 TEST_SUITE=special_fun osx_image: xcode11 @@ -641,6 +757,10 @@ matrix: env: TOOLSET=clang COMPILER=clang++ CXXSTD=c++14 TEST_SUITE=../example//examples osx_image: xcode11 + - os: osx + env: TOOLSET=clang COMPILER=clang++ CXXSTD=c++14 TEST_SUITE=../tools + osx_image: xcode11 + install: - cd .. diff --git a/tools/Jamfile.v2 b/tools/Jamfile.v2 index 5b8a4e83b..c80d5642c 100644 --- a/tools/Jamfile.v2 +++ b/tools/Jamfile.v2 @@ -9,6 +9,7 @@ # bring in the rules for testing import modules ; import path ; +import ../../config/checks/config : requires ; project : requirements @@ -34,12 +35,184 @@ project ../include_private ; +lib gmp ; +lib mpfr ; +lib mpfi ; +lib quadmath ; -for local source in [ glob *_data.cpp ] generate_test_values.cpp igamma_temme_large_coef.cpp lanczos_generator.cpp factorial_tables.cpp generate_rational_test.cpp -{ - exe $(source:B) : $(source) ; - install $(source:B)_bin : $(source:B) : bin ; -} +exe bessel_data : bessel_data.cpp ; +install bessel_data_install : bessel_data : bin ; + +exe ellint_f_data : ellint_f_data.cpp ; +install ellint_f_data_install : ellint_f_data : bin ; + +exe heuman_lambda_data : heuman_lambda_data.cpp ; +install heuman_lambda_data_install : heuman_lambda_data : bin ; + +exe hyp_2f2_data : hyp_2f2_data.cpp ; +install hyp_2f2_data_install : hyp_2f2_data : bin ; + +exe laguerre_data : laguerre_data.cpp ; +install laguerre_data_install : laguerre_data : bin ; + +exe bessel_derivative_data : bessel_derivative_data.cpp : +[ check-target-builds ../../multiprecision/config//has_gmp : gmp : no ] +[ check-target-builds ../../multiprecision/config//has_mpfr : mpfr : no ] ; +install bessel_derivative_data_install : bessel_derivative_data : bin ; + +exe ellint_k_data : ellint_k_data.cpp ; +install ellint_k_data_install : ellint_k_data : bin ; + +exe hyp_0f2_data : hyp_0f2_data.cpp ; +install hyp_0f2_data_install : hyp_0f2_data : bin ; + +exe hypergeometric_dist_data : hypergeometric_dist_data.cpp : [ requires cxx11_hdr_random ] ; +install hypergeometric_dist_data_install : hypergeometric_dist_data : bin ; + +exe legendre_data : legendre_data.cpp ; +install legendre_data_install : legendre_data : bin ; + +exe beta_data : beta_data.cpp ; +install beta_data_install : beta_data : bin ; + +exe ellint_pi2_data : ellint_pi2_data.cpp ; +install ellint_pi2_data_install : ellint_pi2_data : bin ; + +exe hyp_1f1_big_data : hyp_1f1_big_data.cpp : +[ check-target-builds ../../multiprecision/config//has_gmp : gmp : no ] +[ check-target-builds ../../multiprecision/config//has_mpfr : mpfr : no ] +[ check-target-builds ../../multiprecision/config//has_mpfi : gmp mpfr mpfi : no ] +[ requires cxx11_decltype ] ; +install hyp_1f1_big_data_install : hyp_1f1_big_data : bin ; + +exe ibeta_data : ibeta_data.cpp ; +install ibeta_data_install : ibeta_data : bin ; + +exe log1p_expm1_data : log1p_expm1_data.cpp ; +install log1p_expm1_data_install : log1p_expm1_data : bin ; + +exe carlson_ellint_data : carlson_ellint_data.cpp ; +install carlson_ellint_data_install : carlson_ellint_data : bin ; + +exe ellint_pi3_data : ellint_pi3_data.cpp ; +install ellint_pi3_data_install : ellint_pi3_data : bin ; + +exe hyp_1f1_data : hyp_1f1_data.cpp : +[ check-target-builds ../../multiprecision/config//has_gmp : gmp : no ] +[ check-target-builds ../../multiprecision/config//has_mpfr : mpfr : no ] +[ check-target-builds ../../multiprecision/config//has_mpfi : gmp mpfr mpfi : no ] +[ requires cxx11_decltype ] ; +install hyp_1f1_data_install : hyp_1f1_data : bin ; + +exe ibeta_derivative_data : ibeta_derivative_data.cpp ; +install ibeta_derivative_data_install : ibeta_derivative_data : bin ; + +exe sinc_data : sinc_data.cpp ; +install sinc_data_install : sinc_data : bin ; + +exe cbrt_data : cbrt_data.cpp ; +install cbrt_data_install : cbrt_data : bin ; + +exe erf_data : erf_data.cpp : [ check-target-builds ../../multiprecision/config//has_float128 : quadmath : no ] ; +install erf_data_install : erf_data : bin ; + +exe hyp_1f1_log_big_data : hyp_1f1_log_big_data.cpp : +[ check-target-builds ../../multiprecision/config//has_gmp : gmp : no ] +[ check-target-builds ../../multiprecision/config//has_mpfr : mpfr : no ] +[ check-target-builds ../../multiprecision/config//has_mpfi : gmp mpfr mpfi : no ] +[ requires cxx11_decltype ] ; +install hyp_1f1_log_big_data_install : hyp_1f1_log_big_data : bin ; + +exe ibeta_inv_data : ibeta_inv_data.cpp : [ check-target-builds ../../multiprecision/config//has_float128 : quadmath : no ] ; +install ibeta_inv_data_install : ibeta_inv_data : bin ; + +exe spherical_harmonic_data : spherical_harmonic_data.cpp ; +install spherical_harmonic_data_install : spherical_harmonic_data : bin ; + +exe digamma_data : digamma_data.cpp : [ check-target-builds ../../multiprecision/config//has_float128 : quadmath : no ] ; +install digamma_data_install : digamma_data : bin ; + +exe expint_data : expint_data.cpp ; +install expint_data_install : expint_data : bin ; + +exe hyp_1f1_reg_big_data : hyp_1f1_reg_big_data.cpp : +[ check-target-builds ../../multiprecision/config//has_gmp : gmp : no ] +[ check-target-builds ../../multiprecision/config//has_mpfr : mpfr : no ] +[ check-target-builds ../../multiprecision/config//has_mpfi : gmp mpfr mpfi : no ] +[ requires cxx11_decltype ] ; +install hyp_1f1_reg_big_data_install : hyp_1f1_reg_big_data : bin ; + +exe ibeta_invab_data : ibeta_invab_data.cpp : [ check-target-builds ../../multiprecision/config//has_float128 : quadmath : no ] ; +install ibeta_invab_data_install : ibeta_invab_data : bin ; + +exe tgamma_large_data : tgamma_large_data.cpp : [ check-target-builds ../../multiprecision/config//mpfr : mpfr : no ] [ check-target-builds ../../multiprecision/config//gmp : gmp : no ] ; +install tgamma_large_data_install : tgamma_large_data : bin ; + +exe ellint_d_data : ellint_d_data.cpp ; +install ellint_d_data_install : ellint_d_data : bin ; + +exe expint_i_data : expint_i_data.cpp ; +install expint_i_data_install : expint_i_data : bin ; + +exe hyp_1f2_data : hyp_1f2_data.cpp ; +install hyp_1f2_data_install : hyp_1f2_data : bin ; + +exe igamma_data : igamma_data.cpp : [ check-target-builds ../../multiprecision/config//has_float128 : quadmath : no ] ; +install igamma_data_install : igamma_data : bin ; + +exe tgamma_ratio_data : tgamma_ratio_data.cpp ; +install tgamma_ratio_data_install : tgamma_ratio_data : bin ; + +exe ellint_d2_data : ellint_d2_data.cpp ; +install ellint_d2_data_install : ellint_d2_data : bin ; + +exe gamma_P_inva_data : gamma_P_inva_data.cpp : [ check-target-builds ../../multiprecision/config//has_float128 : quadmath : no ] ; +install gamma_P_inva_data_install : gamma_P_inva_data : bin ; + +exe hyp_2f0_data : hyp_2f0_data.cpp ; +install hyp_2f0_data_install : hyp_2f0_data : bin ; + +exe inv_hyp_data : inv_hyp_data.cpp ; +install inv_hyp_data_install : inv_hyp_data : bin ; + +exe trig_data : trig_data.cpp ; +install trig_data_install : trig_data : bin ; + +exe ellint_e_data : ellint_e_data.cpp ; +install ellint_e_data_install : ellint_e_data : bin ; + +exe hermite_data : hermite_data.cpp ; +install hermite_data_install : hermite_data : bin ; + +exe hyp_2f1_data : hyp_2f1_data.cpp ; +install hyp_2f1_data_install : hyp_2f1_data : bin ; + +exe jacobi_zeta_data : jacobi_zeta_data.cpp ; +install jacobi_zeta_data_install : jacobi_zeta_data : bin ; + +exe zeta_data : zeta_data.cpp ; +install zeta_data_install : zeta_data : bin ; + +exe generate_test_values : generate_test_values.cpp ; +install generate_test_values_install : generate_test_values : bin ; + +exe igamma_temme_large_coef : igamma_temme_large_coef.cpp ; +install igamma_temme_large_coef_install : igamma_temme_large_coef : bin ; + +exe lanczos_generator : lanczos_generator.cpp ../../chrono/build//boost_chrono ../../system/build//boost_system : [ check-target-builds ../../multiprecision/config//has_float128 : quadmath : no ] ; +install lanczos_generator_install : lanczos_generator : bin ; + +exe factorial_tables : factorial_tables.cpp ; +install factorial_tables_install : factorial_tables : bin ; + +exe generate_rational_test : generate_rational_test.cpp ; +install generate_rational_test_install : generate_rational_test : bin ; + +#for local source in [ glob *_data.cpp ] generate_test_values.cpp igamma_temme_large_coef.cpp lanczos_generator.cpp factorial_tables.cpp generate_rational_test.cpp +#{ +# exe $(source:B) : $(source) : [ check-target-builds ../../multiprecision/config//has_gmp : HAS_GMP gmp : no ] [ check-target-builds ../../multiprecision/config//has_mpfr : HAS_MPFR mpfr : no ] [ check-target-builds ../../multiprecision/config//has_mpfi : HAS_MPFI gmp mpfr mpfi ] ; +# install $(source:B)_bin : $(source:B) : bin ; +#} exe generate_rational_code : generate_rational_code.cpp ; exe process_perf_results : process_perf_results.cpp ../../regex/build//boost_regex ; diff --git a/tools/bessel_data.cpp b/tools/bessel_data.cpp index 6c9503587..7ed5f0eb7 100644 --- a/tools/bessel_data.cpp +++ b/tools/bessel_data.cpp @@ -12,9 +12,9 @@ // #include +#include "mp_t.hpp" #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; diff --git a/tools/beta_data.cpp b/tools/beta_data.cpp index 2ab3336df..d22cf8e30 100644 --- a/tools/beta_data.cpp +++ b/tools/beta_data.cpp @@ -3,11 +3,11 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; diff --git a/tools/carlson_ellint_data.cpp b/tools/carlson_ellint_data.cpp index 5bd980733..66dc6d005 100644 --- a/tools/carlson_ellint_data.cpp +++ b/tools/carlson_ellint_data.cpp @@ -4,6 +4,7 @@ // (See accompanying file LICENSE_1_0.txt // or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include @@ -11,7 +12,6 @@ #include #include #include -#include "mp_t.hpp" float extern_val; // confuse the compilers optimiser, and force a truncation to float precision: diff --git a/tools/cbrt_data.cpp b/tools/cbrt_data.cpp index 95c0a46f7..9ee2b5994 100644 --- a/tools/cbrt_data.cpp +++ b/tools/cbrt_data.cpp @@ -4,8 +4,8 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include -#include #include "mp_t.hpp" +#include using namespace boost::math::tools; using namespace std; diff --git a/tools/digamma_data.cpp b/tools/digamma_data.cpp index d2f7c315b..38ace7d97 100644 --- a/tools/digamma_data.cpp +++ b/tools/digamma_data.cpp @@ -3,11 +3,11 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace std; diff --git a/tools/ellint_d2_data.cpp b/tools/ellint_d2_data.cpp index 79263711b..d9223d146 100644 --- a/tools/ellint_d2_data.cpp +++ b/tools/ellint_d2_data.cpp @@ -3,13 +3,13 @@ // Boost Software License, Version 1.0. // (See accompanying file LICENSE_1_0.txt // or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; diff --git a/tools/ellint_d_data.cpp b/tools/ellint_d_data.cpp index f2c30f37c..9a56fd4af 100644 --- a/tools/ellint_d_data.cpp +++ b/tools/ellint_d_data.cpp @@ -3,13 +3,13 @@ // Boost Software License, Version 1.0. // (See accompanying file LICENSE_1_0.txt // or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; diff --git a/tools/ellint_e_data.cpp b/tools/ellint_e_data.cpp index d68d3f200..e761b541f 100644 --- a/tools/ellint_e_data.cpp +++ b/tools/ellint_e_data.cpp @@ -3,12 +3,12 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; diff --git a/tools/ellint_f_data.cpp b/tools/ellint_f_data.cpp index 4ecc4f010..0e816f714 100644 --- a/tools/ellint_f_data.cpp +++ b/tools/ellint_f_data.cpp @@ -3,12 +3,12 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; diff --git a/tools/ellint_k_data.cpp b/tools/ellint_k_data.cpp index 8f58cb0dc..11e6f5d82 100644 --- a/tools/ellint_k_data.cpp +++ b/tools/ellint_k_data.cpp @@ -3,12 +3,12 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; diff --git a/tools/ellint_pi2_data.cpp b/tools/ellint_pi2_data.cpp index e7b63ec4d..d9ad7fd76 100644 --- a/tools/ellint_pi2_data.cpp +++ b/tools/ellint_pi2_data.cpp @@ -3,13 +3,13 @@ // Boost Software License, Version 1.0. // (See accompanying file LICENSE_1_0.txt // or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; diff --git a/tools/ellint_pi3_data.cpp b/tools/ellint_pi3_data.cpp index bc09d9cfd..2c0aee38a 100644 --- a/tools/ellint_pi3_data.cpp +++ b/tools/ellint_pi3_data.cpp @@ -6,13 +6,13 @@ // or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include #include #include -#include "mp_t.hpp" float extern_val; // confuse the compilers optimiser, and force a truncation to float precision: diff --git a/tools/erf_data.cpp b/tools/erf_data.cpp index b2e76b803..4e8ebcadc 100644 --- a/tools/erf_data.cpp +++ b/tools/erf_data.cpp @@ -3,12 +3,12 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include // for inverses #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace std; diff --git a/tools/expint_data.cpp b/tools/expint_data.cpp index e34e3b549..b99c64923 100644 --- a/tools/expint_data.cpp +++ b/tools/expint_data.cpp @@ -3,11 +3,11 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; diff --git a/tools/expint_i_data.cpp b/tools/expint_i_data.cpp index f8b6166ae..c5d3c4a68 100644 --- a/tools/expint_i_data.cpp +++ b/tools/expint_i_data.cpp @@ -3,11 +3,11 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; diff --git a/tools/gamma_P_inva_data.cpp b/tools/gamma_P_inva_data.cpp index 6f12bc5e9..38de47139 100644 --- a/tools/gamma_P_inva_data.cpp +++ b/tools/gamma_P_inva_data.cpp @@ -3,12 +3,12 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; diff --git a/tools/generate_rational_test.cpp b/tools/generate_rational_test.cpp index 7093906df..7fa82c40c 100644 --- a/tools/generate_rational_test.cpp +++ b/tools/generate_rational_test.cpp @@ -6,11 +6,11 @@ #define BOOST_MATH_POLY_METHOD 0 #define BOOST_MATH_RATIONAL_METHOD 0 +#include "mp_t.hpp" #include #include #include #include -#include "mp_t.hpp" int main() { diff --git a/tools/hermite_data.cpp b/tools/hermite_data.cpp index 156a72543..e96a45b64 100644 --- a/tools/hermite_data.cpp +++ b/tools/hermite_data.cpp @@ -3,10 +3,10 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; diff --git a/tools/heuman_lambda_data.cpp b/tools/heuman_lambda_data.cpp index 44aa3803b..af27e4d89 100644 --- a/tools/heuman_lambda_data.cpp +++ b/tools/heuman_lambda_data.cpp @@ -3,13 +3,13 @@ // Boost Software License, Version 1.0. // (See accompanying file LICENSE_1_0.txt // or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; diff --git a/tools/hyp_0f2_data.cpp b/tools/hyp_0f2_data.cpp index 6bdaedb25..a95426539 100644 --- a/tools/hyp_0f2_data.cpp +++ b/tools/hyp_0f2_data.cpp @@ -5,13 +5,13 @@ #define BOOST_MATH_MAX_SERIES_ITERATION_POLICY 10000000 +#include "mp_t.hpp" #include #include #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; diff --git a/tools/hyp_1f1_big_data.cpp b/tools/hyp_1f1_big_data.cpp index 4bef9d2ff..e767e242c 100644 --- a/tools/hyp_1f1_big_data.cpp +++ b/tools/hyp_1f1_big_data.cpp @@ -5,6 +5,8 @@ #define BOOST_MATH_MAX_SERIES_ITERATION_POLICY 10000000 +#define BOOST_MATH_USE_MPFR +#include "mp_t.hpp" #include #include #include @@ -12,8 +14,6 @@ #include #include #include -#define BOOST_MATH_USE_MPFR -#include "mp_t.hpp" #include diff --git a/tools/hyp_1f1_data.cpp b/tools/hyp_1f1_data.cpp index 0205b42b3..bdcb3b47d 100644 --- a/tools/hyp_1f1_data.cpp +++ b/tools/hyp_1f1_data.cpp @@ -5,6 +5,7 @@ #define BOOST_MATH_MAX_SERIES_ITERATION_POLICY 10000000 +#include "mp_t.hpp" #include #include #include @@ -12,7 +13,6 @@ #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; @@ -22,10 +22,11 @@ struct hypergeometric_1f1_gen { mp_t operator()(mp_t a1, mp_t a2, mp_t z) { + int scaling = 0; std::cout << a1 << " " << a2 << " " << z << std::endl; - mp_t result = boost::math::detail::hypergeometric_1f1_generic_series(a1, a2, z, boost::math::policies::policy<>()); + mp_t result = boost::math::detail::hypergeometric_1F1_generic_series(a1, a2, z, boost::math::policies::policy<>(), scaling, ""); std::cout << a1 << " " << a2 << " " << z << " " << result << std::endl; - return result; + return ldexp(result, scaling); } }; @@ -33,7 +34,9 @@ struct hypergeometric_1f1_gen_2 { mp_t operator()(mp_t a1, mp_t a2, mp_t z) { - mp_t result = boost::math::detail::hypergeometric_1f1_generic_series(a1, a2, z, boost::math::policies::policy<>()); + int scaling = 0; + mp_t result = boost::math::detail::hypergeometric_1F1_generic_series(a1, a2, z, boost::math::policies::policy<>(), scaling, ""); + result = ldexp(result, scaling); std::cout << a1 << " " << a2 << " " << z << " " << result << std::endl; if (fabs(result) > (std::numeric_limits::max)()) { diff --git a/tools/hyp_1f1_log_big_data.cpp b/tools/hyp_1f1_log_big_data.cpp index ab8b09e48..3ec8594e2 100644 --- a/tools/hyp_1f1_log_big_data.cpp +++ b/tools/hyp_1f1_log_big_data.cpp @@ -5,6 +5,8 @@ #define BOOST_MATH_MAX_SERIES_ITERATION_POLICY 10000000 +#define BOOST_MATH_USE_MPFR +#include "mp_t.hpp" #include #include #include @@ -13,8 +15,6 @@ #include #include #include -#define BOOST_MATH_USE_MPFR -#include "mp_t.hpp" #include diff --git a/tools/hyp_1f1_reg_big_data.cpp b/tools/hyp_1f1_reg_big_data.cpp index 6989547e7..1a702b912 100644 --- a/tools/hyp_1f1_reg_big_data.cpp +++ b/tools/hyp_1f1_reg_big_data.cpp @@ -4,7 +4,8 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #define BOOST_MATH_MAX_SERIES_ITERATION_POLICY 10000000 - +#define BOOST_MATH_USE_MPFR +#include "mp_t.hpp" #include #include #include @@ -13,8 +14,6 @@ #include #include #include -#define BOOST_MATH_USE_MPFR -#include "mp_t.hpp" #include diff --git a/tools/hyp_1f2_data.cpp b/tools/hyp_1f2_data.cpp index c3ebee3dc..75fadfc22 100644 --- a/tools/hyp_1f2_data.cpp +++ b/tools/hyp_1f2_data.cpp @@ -5,13 +5,13 @@ #define BOOST_MATH_MAX_SERIES_ITERATION_POLICY 10000000 +#include "mp_t.hpp" #include #include #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; diff --git a/tools/hyp_2f0_data.cpp b/tools/hyp_2f0_data.cpp index a750dff51..6417427da 100644 --- a/tools/hyp_2f0_data.cpp +++ b/tools/hyp_2f0_data.cpp @@ -3,6 +3,7 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include @@ -10,7 +11,6 @@ #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; @@ -21,7 +21,7 @@ struct hypergeometric_2f0_gen mp_t operator()(mp_t a1, mp_t a2, mp_t z) { std::cout << a1 << " " << a2 << " " << z << std::endl; - mp_t result = boost::math::detail::hypergeometric_2f0_generic_series(a1, a2, z, boost::math::policies::policy<>()); + mp_t result = boost::math::detail::hypergeometric_2F0_generic_series(a1, a2, z, boost::math::policies::policy<>()); std::cout << a1 << " " << a2 << " " << z << " " << result << std::endl; return result; } @@ -31,7 +31,7 @@ struct hypergeometric_2f0_gen_spec1 { boost::math::tuple operator()(mp_t a1, mp_t z) { - mp_t result = boost::math::detail::hypergeometric_2f0_generic_series(a1, a1 + 0.5, z, boost::math::policies::policy<>()); + mp_t result = boost::math::detail::hypergeometric_2F0_generic_series(a1, a1 + 0.5, z, boost::math::policies::policy<>()); std::cout << a1 << " " << a1 + 0.5 << " " << z << " " << result << std::endl; return boost::math::make_tuple(a1, a1 + 0.5, z, result); } diff --git a/tools/hyp_2f1_data.cpp b/tools/hyp_2f1_data.cpp index c742e7437..7978e2bdc 100644 --- a/tools/hyp_2f1_data.cpp +++ b/tools/hyp_2f1_data.cpp @@ -5,13 +5,13 @@ #define BOOST_MATH_MAX_SERIES_ITERATION_POLICY 10000000 +#include "mp_t.hpp" #include #include #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; diff --git a/tools/hyp_2f2_data.cpp b/tools/hyp_2f2_data.cpp index 378db1cd3..e86f9ba39 100644 --- a/tools/hyp_2f2_data.cpp +++ b/tools/hyp_2f2_data.cpp @@ -5,13 +5,13 @@ #define BOOST_MATH_MAX_SERIES_ITERATION_POLICY 10000000 +#include "mp_t.hpp" #include #include #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; diff --git a/tools/hypergeometric_dist_data.cpp b/tools/hypergeometric_dist_data.cpp index 55352f03a..52386192a 100644 --- a/tools/hypergeometric_dist_data.cpp +++ b/tools/hypergeometric_dist_data.cpp @@ -5,6 +5,7 @@ //#define BOOST_MATH_INSTRUMENT +#include "mp_t.hpp" #include #include #include @@ -12,7 +13,6 @@ #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; diff --git a/tools/ibeta_data.cpp b/tools/ibeta_data.cpp index 5d906b719..357422b4a 100644 --- a/tools/ibeta_data.cpp +++ b/tools/ibeta_data.cpp @@ -3,6 +3,7 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include @@ -11,7 +12,6 @@ #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; diff --git a/tools/ibeta_derivative_data.cpp b/tools/ibeta_derivative_data.cpp index 80e019076..69716d2b5 100644 --- a/tools/ibeta_derivative_data.cpp +++ b/tools/ibeta_derivative_data.cpp @@ -3,6 +3,7 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include @@ -11,7 +12,6 @@ #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; diff --git a/tools/ibeta_inv_data.cpp b/tools/ibeta_inv_data.cpp index f41d2a1e0..1fa9d0e45 100644 --- a/tools/ibeta_inv_data.cpp +++ b/tools/ibeta_inv_data.cpp @@ -3,13 +3,13 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; diff --git a/tools/ibeta_invab_data.cpp b/tools/ibeta_invab_data.cpp index 8830bd41c..fb00a2e4d 100644 --- a/tools/ibeta_invab_data.cpp +++ b/tools/ibeta_invab_data.cpp @@ -3,13 +3,13 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; diff --git a/tools/igamma_data.cpp b/tools/igamma_data.cpp index ad4b2179e..20d513fed 100644 --- a/tools/igamma_data.cpp +++ b/tools/igamma_data.cpp @@ -3,12 +3,12 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; diff --git a/tools/igamma_temme_large_coef.cpp b/tools/igamma_temme_large_coef.cpp index 1f5e0c330..229c8137c 100644 --- a/tools/igamma_temme_large_coef.cpp +++ b/tools/igamma_temme_large_coef.cpp @@ -3,13 +3,13 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include #include #include -#include "mp_t.hpp" using namespace std; using namespace boost::math; diff --git a/tools/inv_hyp_data.cpp b/tools/inv_hyp_data.cpp index cff496bf3..b24b3578d 100644 --- a/tools/inv_hyp_data.cpp +++ b/tools/inv_hyp_data.cpp @@ -3,10 +3,10 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace std; diff --git a/tools/jacobi_zeta_data.cpp b/tools/jacobi_zeta_data.cpp index ded652301..07a8feb29 100644 --- a/tools/jacobi_zeta_data.cpp +++ b/tools/jacobi_zeta_data.cpp @@ -3,13 +3,13 @@ // Boost Software License, Version 1.0. // (See accompanying file LICENSE_1_0.txt // or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; diff --git a/tools/laguerre_data.cpp b/tools/laguerre_data.cpp index b1777b153..aacb7d023 100644 --- a/tools/laguerre_data.cpp +++ b/tools/laguerre_data.cpp @@ -3,12 +3,12 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; diff --git a/tools/lanczos_generator.cpp b/tools/lanczos_generator.cpp index 10a8390f9..dc752eab1 100644 --- a/tools/lanczos_generator.cpp +++ b/tools/lanczos_generator.cpp @@ -3,6 +3,7 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include @@ -17,7 +18,6 @@ #include #include #include -#include "mp_t.hpp" // // Define MP_TYPE diff --git a/tools/legendre_data.cpp b/tools/legendre_data.cpp index b011c77ea..c5ef30ad6 100644 --- a/tools/legendre_data.cpp +++ b/tools/legendre_data.cpp @@ -3,12 +3,12 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; diff --git a/tools/log1p_expm1_data.cpp b/tools/log1p_expm1_data.cpp index 3ccdd01aa..687dd64c2 100644 --- a/tools/log1p_expm1_data.cpp +++ b/tools/log1p_expm1_data.cpp @@ -4,10 +4,10 @@ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include +#include "mp_t.hpp" #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace std; diff --git a/tools/rational_tests.cpp b/tools/rational_tests.cpp index 67f1ca0c1..929ad4795 100644 --- a/tools/rational_tests.cpp +++ b/tools/rational_tests.cpp @@ -3,11 +3,11 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include -#include "mp_t.hpp" int main() { diff --git a/tools/sinc_data.cpp b/tools/sinc_data.cpp index 02cc61c97..cef666bfa 100644 --- a/tools/sinc_data.cpp +++ b/tools/sinc_data.cpp @@ -3,11 +3,11 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace std; diff --git a/tools/spherical_harmonic_data.cpp b/tools/spherical_harmonic_data.cpp index 2c04823e4..d13674e46 100644 --- a/tools/spherical_harmonic_data.cpp +++ b/tools/spherical_harmonic_data.cpp @@ -3,11 +3,11 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace boost::math; diff --git a/tools/tgamma_large_data.cpp b/tools/tgamma_large_data.cpp index dbf6ef343..e97a217e3 100644 --- a/tools/tgamma_large_data.cpp +++ b/tools/tgamma_large_data.cpp @@ -48,7 +48,11 @@ int cpp_main(int argc, char*argv []) return 1; arg1.type |= dummy_param; - data.insert(&generate, arg1); + typedef boost::math::tuple(&proc_type)(mp_type); + + proc_type p = &generate; + + data.insert(p, arg1); std::cout << "Any more data [y/n]?"; std::getline(std::cin, line); diff --git a/tools/tgamma_ratio_data.cpp b/tools/tgamma_ratio_data.cpp index 3f4e67223..119aa43a7 100644 --- a/tools/tgamma_ratio_data.cpp +++ b/tools/tgamma_ratio_data.cpp @@ -3,10 +3,10 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace std; diff --git a/tools/trig_data.cpp b/tools/trig_data.cpp index 41233578f..6c8f20964 100644 --- a/tools/trig_data.cpp +++ b/tools/trig_data.cpp @@ -3,10 +3,10 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace std; diff --git a/tools/zeta_data.cpp b/tools/zeta_data.cpp index 55c87c979..26ac7ca64 100644 --- a/tools/zeta_data.cpp +++ b/tools/zeta_data.cpp @@ -3,11 +3,11 @@ // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +#include "mp_t.hpp" #include #include #include #include -#include "mp_t.hpp" using namespace boost::math::tools; using namespace std;