mirror of
https://github.com/boostorg/math.git
synced 2026-01-19 04:22:09 +00:00
Fixes for inspect failures in doc/ and example/
This commit is contained in:
@@ -120,3 +120,10 @@ When 2*x*x*n > [pi]: -__jacobi_theta4m1tau(0, 2*x*x*n/[pi])]]
|
|||||||
]
|
]
|
||||||
|
|
||||||
[endsect] [/section:kolmogorov_smirnov_dist Kolmogorov-Smirnov]
|
[endsect] [/section:kolmogorov_smirnov_dist Kolmogorov-Smirnov]
|
||||||
|
|
||||||
|
[/
|
||||||
|
Copyright Evan Miller 2020.
|
||||||
|
Distributed under the Boost Software License, Version 1.0.
|
||||||
|
(See accompanying file LICENSE_1_0.txt or copy at
|
||||||
|
http://www.boost.org/LICENSE_1_0.txt).
|
||||||
|
]
|
||||||
|
|||||||
1
doc/graphs/hypergeometric_1f1/boost-no-inspect
Normal file
1
doc/graphs/hypergeometric_1f1/boost-no-inspect
Normal file
@@ -0,0 +1 @@
|
|||||||
|
|
||||||
@@ -23,6 +23,8 @@ one in libs/math/doc and one in libs/math/doc/html
|
|||||||
|
|
||||||
ONLY EVER EDIT THE FIRST OF THESE !!!!
|
ONLY EVER EDIT THE FIRST OF THESE !!!!
|
||||||
|
|
||||||
|
boost-no-inspect
|
||||||
|
|
||||||
=============================================================================*/
|
=============================================================================*/
|
||||||
|
|
||||||
/*=============================================================================
|
/*=============================================================================
|
||||||
|
|||||||
@@ -1,3 +1,7 @@
|
|||||||
|
# Copyright 2021 Matt Borland
|
||||||
|
# Distributed under the Boost Software License, Version 1.0.
|
||||||
|
# https://www.boost.org/LICENSE_1_0.txt
|
||||||
|
|
||||||
file(GLOB SOURCES "*.cpp")
|
file(GLOB SOURCES "*.cpp")
|
||||||
add_library(examples ${SOURCES})
|
add_library(examples ${SOURCES})
|
||||||
target_compile_features(examples PRIVATE cxx_std_17)
|
target_compile_features(examples PRIVATE cxx_std_17)
|
||||||
|
|||||||
@@ -2,6 +2,11 @@
|
|||||||
// Use, modification and distribution are subject to the
|
// Use, modification and distribution are subject to the
|
||||||
// Boost Software License, Version 1.0. (See accompanying file
|
// Boost Software License, Version 1.0. (See accompanying file
|
||||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||||
|
//
|
||||||
|
// Deliberately contains some unicode characters:
|
||||||
|
//
|
||||||
|
// boost-no-inspect
|
||||||
|
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <boost/math/tools/ulps_plot.hpp>
|
#include <boost/math/tools/ulps_plot.hpp>
|
||||||
#include <boost/core/demangle.hpp>
|
#include <boost/core/demangle.hpp>
|
||||||
|
|||||||
@@ -2,6 +2,11 @@
|
|||||||
// Use, modification and distribution are subject to the
|
// Use, modification and distribution are subject to the
|
||||||
// Boost Software License, Version 1.0. (See accompanying file
|
// Boost Software License, Version 1.0. (See accompanying file
|
||||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||||
|
//
|
||||||
|
// Deliberately contains some unicode characters:
|
||||||
|
//
|
||||||
|
// boost-no-inspect
|
||||||
|
//
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <boost/math/constants/constants.hpp>
|
#include <boost/math/constants/constants.hpp>
|
||||||
#include <boost/math/tools/centered_continued_fraction.hpp>
|
#include <boost/math/tools/centered_continued_fraction.hpp>
|
||||||
|
|||||||
@@ -1,3 +1,8 @@
|
|||||||
|
// (C) Copyright Nick Thompson 2020.
|
||||||
|
// Use, modification and distribution are subject to the
|
||||||
|
// 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 <iostream>
|
#include <iostream>
|
||||||
#include <boost/math/special_functions/daubechies_scaling.hpp>
|
#include <boost/math/special_functions/daubechies_scaling.hpp>
|
||||||
#include <boost/math/special_functions/chebyshev_transform.hpp>
|
#include <boost/math/special_functions/chebyshev_transform.hpp>
|
||||||
@@ -15,4 +20,4 @@ void bootstrap()
|
|||||||
int main()
|
int main()
|
||||||
{
|
{
|
||||||
bootstrap<long double, 9>();
|
bootstrap<long double, 9>();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,6 +3,10 @@
|
|||||||
* Use, modification and distribution are subject to the
|
* Use, modification and distribution are subject to the
|
||||||
* Boost Software License, Version 1.0. (See accompanying file
|
* Boost Software License, Version 1.0. (See accompanying file
|
||||||
* LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
* LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||||
|
*
|
||||||
|
* We want to use c-style asserts in examples:
|
||||||
|
*
|
||||||
|
* boost-no-inspect
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define BOOST_MATH_GENERATE_DAUBECHIES_GRID
|
#define BOOST_MATH_GENERATE_DAUBECHIES_GRID
|
||||||
|
|||||||
@@ -1,3 +1,8 @@
|
|||||||
|
// (C) Copyright Nick Thompson 2020.
|
||||||
|
// Use, modification and distribution are subject to the
|
||||||
|
// 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 <iostream>
|
#include <iostream>
|
||||||
#include <boost/math/special_functions/daubechies_scaling.hpp>
|
#include <boost/math/special_functions/daubechies_scaling.hpp>
|
||||||
#include <boost/core/demangle.hpp>
|
#include <boost/core/demangle.hpp>
|
||||||
|
|||||||
@@ -1,3 +1,10 @@
|
|||||||
|
// (C) Copyright Nick Thompson 2020.
|
||||||
|
// Use, modification and distribution are subject to the
|
||||||
|
// 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 <iostream>
|
#include <iostream>
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <fstream>
|
#include <fstream>
|
||||||
@@ -7,6 +14,7 @@
|
|||||||
#include <iomanip>
|
#include <iomanip>
|
||||||
#include <boost/algorithm/string.hpp>
|
#include <boost/algorithm/string.hpp>
|
||||||
#include <boost/math/statistics/linear_regression.hpp>
|
#include <boost/math/statistics/linear_regression.hpp>
|
||||||
|
#include <boost/assert.hpp>
|
||||||
|
|
||||||
|
|
||||||
int main(int argc, char** argv)
|
int main(int argc, char** argv)
|
||||||
@@ -84,49 +92,49 @@ int main(int argc, char** argv)
|
|||||||
|
|
||||||
std::cout << std::fixed << std::setprecision(16);
|
std::cout << std::fixed << std::setprecision(16);
|
||||||
auto q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, matched_holder);
|
auto q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, matched_holder);
|
||||||
assert(std::get<1>(q) < 0);
|
BOOST_ASSERT(std::get<1>(q) < 0);
|
||||||
std::cout << "Matched Holder : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
std::cout << "Matched Holder : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
||||||
|
|
||||||
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, linear);
|
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, linear);
|
||||||
assert(std::get<1>(q) < 0);
|
BOOST_ASSERT(std::get<1>(q) < 0);
|
||||||
std::cout << "Linear : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
std::cout << "Linear : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
||||||
|
|
||||||
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, quadratic_b_spline);
|
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, quadratic_b_spline);
|
||||||
assert(std::get<1>(q) < 0);
|
BOOST_ASSERT(std::get<1>(q) < 0);
|
||||||
std::cout << "Quadratic B-spline: " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
std::cout << "Quadratic B-spline: " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
||||||
|
|
||||||
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, cubic_b_spline);
|
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, cubic_b_spline);
|
||||||
assert(std::get<1>(q) < 0);
|
BOOST_ASSERT(std::get<1>(q) < 0);
|
||||||
std::cout << "Cubic B-spline : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
std::cout << "Cubic B-spline : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
||||||
|
|
||||||
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, quintic_b_spline);
|
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, quintic_b_spline);
|
||||||
assert(std::get<1>(q) < 0);
|
BOOST_ASSERT(std::get<1>(q) < 0);
|
||||||
std::cout << "Quintic B-spline : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
std::cout << "Quintic B-spline : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
||||||
|
|
||||||
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, cubic_hermite);
|
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, cubic_hermite);
|
||||||
assert(std::get<1>(q) < 0);
|
BOOST_ASSERT(std::get<1>(q) < 0);
|
||||||
std::cout << "Cubic Hermite : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
std::cout << "Cubic Hermite : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
||||||
|
|
||||||
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, pchip);
|
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, pchip);
|
||||||
assert(std::get<1>(q) < 0);
|
BOOST_ASSERT(std::get<1>(q) < 0);
|
||||||
std::cout << "PCHIP : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
std::cout << "PCHIP : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
||||||
|
|
||||||
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, makima);
|
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, makima);
|
||||||
assert(std::get<1>(q) < 0);
|
BOOST_ASSERT(std::get<1>(q) < 0);
|
||||||
std::cout << "Makima : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
std::cout << "Makima : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
||||||
|
|
||||||
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, fotaylor);
|
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, fotaylor);
|
||||||
assert(std::get<1>(q) < 0);
|
BOOST_ASSERT(std::get<1>(q) < 0);
|
||||||
std::cout << "First-order Taylor: " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
std::cout << "First-order Taylor: " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
||||||
|
|
||||||
if (sotaylor.size() > 0)
|
if (sotaylor.size() > 0)
|
||||||
{
|
{
|
||||||
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, quintic_hermite);
|
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, quintic_hermite);
|
||||||
assert(std::get<1>(q) < 0);
|
BOOST_ASSERT(std::get<1>(q) < 0);
|
||||||
std::cout << "Quintic Hermite : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
std::cout << "Quintic Hermite : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
||||||
|
|
||||||
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, sotaylor);
|
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, sotaylor);
|
||||||
assert(std::get<1>(q) < 0);
|
BOOST_ASSERT(std::get<1>(q) < 0);
|
||||||
std::cout << "2nd order Taylor : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
std::cout << "2nd order Taylor : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -134,13 +142,13 @@ int main(int argc, char** argv)
|
|||||||
if (totaylor.size() > 0)
|
if (totaylor.size() > 0)
|
||||||
{
|
{
|
||||||
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, totaylor);
|
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, totaylor);
|
||||||
assert(std::get<1>(q) < 0);
|
BOOST_ASSERT(std::get<1>(q) < 0);
|
||||||
std::cout << "3rd order Taylor : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
std::cout << "3rd order Taylor : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
||||||
|
|
||||||
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, septic_hermite);
|
q = boost::math::statistics::simple_ordinary_least_squares_with_R_squared(r, septic_hermite);
|
||||||
assert(std::get<1>(q) < 0);
|
BOOST_ASSERT(std::get<1>(q) < 0);
|
||||||
std::cout << "Septic Hermite : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
std::cout << "Septic Hermite : " << std::get<0>(q) << " - " << std::abs(std::get<1>(q)) << "r, R^2 = " << std::get<2>(q) << "\n";
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -24,4 +24,4 @@ int main() {
|
|||||||
}
|
}
|
||||||
std::cout << std::setprecision(1000) << "Reciprocal fibonacci constant after "
|
std::cout << std::setprecision(1000) << "Reciprocal fibonacci constant after "
|
||||||
<< ITR << " iterations is: " << ans << std::endl;
|
<< ITR << " iterations is: " << ans << std::endl;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,6 +2,11 @@
|
|||||||
// Use, modification and distribution are subject to the
|
// Use, modification and distribution are subject to the
|
||||||
// Boost Software License, Version 1.0. (See accompanying file
|
// Boost Software License, Version 1.0. (See accompanying file
|
||||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||||
|
//
|
||||||
|
// Deliberately contains some unicode characters:
|
||||||
|
//
|
||||||
|
// boost-no-inspect
|
||||||
|
//
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <boost/math/constants/constants.hpp>
|
#include <boost/math/constants/constants.hpp>
|
||||||
#include <boost/math/tools/simple_continued_fraction.hpp>
|
#include <boost/math/tools/simple_continued_fraction.hpp>
|
||||||
|
|||||||
Reference in New Issue
Block a user