mirror of
https://github.com/boostorg/math.git
synced 2026-01-19 04:22:09 +00:00
Added digamma.
Added needed #include to evaluation_type. Updated minimax and lanczos generators to take account of digamma. [SVN r3231]
This commit is contained in:
433
include/boost/math/special_functions/digamma.hpp
Normal file
433
include/boost/math/special_functions/digamma.hpp
Normal file
@@ -0,0 +1,433 @@
|
||||
// (C) Copyright John Maddock 2006.
|
||||
// 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)
|
||||
|
||||
#ifndef BOOST_MATH_SF_DIGAMMA_HPP
|
||||
#define BOOST_MATH_SF_DIGAMMA_HPP
|
||||
|
||||
#include <boost/math/tools/rational.hpp>
|
||||
#include <boost/math/tools/evaluation_type.hpp>
|
||||
#include <boost/math/tools/error_handling.hpp>
|
||||
#include <boost/math/constants/constants.hpp>
|
||||
|
||||
namespace boost{
|
||||
namespace math{
|
||||
namespace detail{
|
||||
//
|
||||
// Begin by defining the smallest value for which it is safe to
|
||||
// use the asymptotic expansion for digamma:
|
||||
//
|
||||
inline unsigned digamma_large_lim(const mpl::int_<0>*)
|
||||
{ return 20; }
|
||||
|
||||
inline unsigned digamma_large_lim(const void*)
|
||||
{ return 10; }
|
||||
//
|
||||
// Implementations of the asymptotic expansion come next,
|
||||
// the coefficients of the series have been evaluated
|
||||
// in advance at high precision, and the series truncated
|
||||
// at the first term that's too small to effect the result.
|
||||
// Note that the series becomes divergent after a while
|
||||
// so truncation is very important.
|
||||
//
|
||||
// This first one gives 34-digit precision for x >= 20:
|
||||
//
|
||||
template <class T>
|
||||
T digamma_imp_large(T x, const mpl::int_<0>*)
|
||||
{
|
||||
using namespace std; // ADL of std functions.
|
||||
static const T P[] = {
|
||||
0.083333333333333333333333333333333333333333333333333L,
|
||||
-0.0083333333333333333333333333333333333333333333333333L,
|
||||
0.003968253968253968253968253968253968253968253968254L,
|
||||
-0.0041666666666666666666666666666666666666666666666667L,
|
||||
0.0075757575757575757575757575757575757575757575757576L,
|
||||
-0.021092796092796092796092796092796092796092796092796L,
|
||||
0.083333333333333333333333333333333333333333333333333L,
|
||||
-0.44325980392156862745098039215686274509803921568627L,
|
||||
3.0539543302701197438039543302701197438039543302701L,
|
||||
-26.456212121212121212121212121212121212121212121212L,
|
||||
281.4601449275362318840579710144927536231884057971L,
|
||||
-3607.510546398046398046398046398046398046398046398L,
|
||||
54827.583333333333333333333333333333333333333333333L,
|
||||
-974936.82385057471264367816091954022988505747126437L,
|
||||
20052695.796688078946143462272494530559046688078946L,
|
||||
-472384867.72162990196078431372549019607843137254902L,
|
||||
12635724795.916666666666666666666666666666666666667L
|
||||
};
|
||||
x -= 1;
|
||||
T result = log(x);
|
||||
result += 1 / (2 * x);
|
||||
T z = 1 / (x*x);
|
||||
result -= z * tools::evaluate_polynomial(P, z);
|
||||
return result;
|
||||
}
|
||||
//
|
||||
// 19-digit precision for x >= 10:
|
||||
//
|
||||
template <class T>
|
||||
T digamma_imp_large(T x, const mpl::int_<64>*)
|
||||
{
|
||||
using namespace std; // ADL of std functions.
|
||||
static const T P[] = {
|
||||
0.083333333333333333333333333333333333333333333333333L,
|
||||
-0.0083333333333333333333333333333333333333333333333333L,
|
||||
0.003968253968253968253968253968253968253968253968254L,
|
||||
-0.0041666666666666666666666666666666666666666666666667L,
|
||||
0.0075757575757575757575757575757575757575757575757576L,
|
||||
-0.021092796092796092796092796092796092796092796092796L,
|
||||
0.083333333333333333333333333333333333333333333333333L,
|
||||
-0.44325980392156862745098039215686274509803921568627L,
|
||||
3.0539543302701197438039543302701197438039543302701L,
|
||||
-26.456212121212121212121212121212121212121212121212L,
|
||||
281.4601449275362318840579710144927536231884057971L,
|
||||
};
|
||||
x -= 1;
|
||||
T result = log(x);
|
||||
result += 1 / (2 * x);
|
||||
T z = 1 / (x*x);
|
||||
result -= z * tools::evaluate_polynomial(P, z);
|
||||
return result;
|
||||
}
|
||||
//
|
||||
// 17-digit precision for x >= 10:
|
||||
//
|
||||
template <class T>
|
||||
T digamma_imp_large(T x, const mpl::int_<53>*)
|
||||
{
|
||||
using namespace std; // ADL of std functions.
|
||||
static const T P[] = {
|
||||
0.083333333333333333333333333333333333333333333333333L,
|
||||
-0.0083333333333333333333333333333333333333333333333333L,
|
||||
0.003968253968253968253968253968253968253968253968254L,
|
||||
-0.0041666666666666666666666666666666666666666666666667L,
|
||||
0.0075757575757575757575757575757575757575757575757576L,
|
||||
-0.021092796092796092796092796092796092796092796092796L,
|
||||
0.083333333333333333333333333333333333333333333333333L,
|
||||
-0.44325980392156862745098039215686274509803921568627L
|
||||
};
|
||||
x -= 1;
|
||||
T result = log(x);
|
||||
result += 1 / (2 * x);
|
||||
T z = 1 / (x*x);
|
||||
result -= z * tools::evaluate_polynomial(P, z);
|
||||
return result;
|
||||
}
|
||||
//
|
||||
// 9-digit precision for x >= 10:
|
||||
//
|
||||
template <class T>
|
||||
T digamma_imp_large(T x, const mpl::int_<24>*)
|
||||
{
|
||||
using namespace std; // ADL of std functions.
|
||||
static const T P[] = {
|
||||
0.083333333333333333333333333333333333333333333333333L,
|
||||
-0.0083333333333333333333333333333333333333333333333333L,
|
||||
0.003968253968253968253968253968253968253968253968254L
|
||||
};
|
||||
x -= 1;
|
||||
T result = log(x);
|
||||
result += 1 / (2 * x);
|
||||
T z = 1 / (x*x);
|
||||
result -= z * tools::evaluate_polynomial(P, z);
|
||||
return result;
|
||||
}
|
||||
//
|
||||
// Now follow rational approximations over the range [1,2].
|
||||
//
|
||||
// 35-digit precision:
|
||||
//
|
||||
template <class T>
|
||||
T digamma_imp_1_2(T x, const mpl::int_<0>*)
|
||||
{
|
||||
//
|
||||
// Now the approximation, we use the form:
|
||||
//
|
||||
// digamma(x) = (x - root) * (Y + R(x-1))
|
||||
//
|
||||
// Where root is the location of the positive root of digamma,
|
||||
// Y is a constant, and R is optimised for low absolute error
|
||||
// compared to Y.
|
||||
//
|
||||
// Max error found at 128-bit long double precision: 5.631e-35
|
||||
// Maximum Deviation Found (approximation error): 1.960e-35
|
||||
//
|
||||
static const float Y = 0.99558162689208984375F;
|
||||
|
||||
static const T root1 = 1569415565.0 / 1073741824uL;
|
||||
static const T root2 = (381566830.0 / 1073741824uL) / 1073741824uL;
|
||||
static const T root3 = ((111616537.0 / 1073741824uL) / 1073741824uL) / 1073741824uL;
|
||||
static const T root4 = (((503992063.0 / 1073741824uL) / 1073741824uL) / 1073741824uL) / 1073741824uL;
|
||||
static const T root5 = 0.75231638452626400509999138382223723380394592598054e-36L;
|
||||
|
||||
static const T P[] = {
|
||||
0.25479851061131551526977464225335883773L,
|
||||
-0.18680627276785631913044260934720955868L,
|
||||
-0.80363716137044194938509411262041851893L,
|
||||
-0.67238768156656204735119811446899962752L,
|
||||
-0.26578204405928542571891729794823602027L,
|
||||
-0.0577913339744471190265540061417732562L,
|
||||
-0.0071502599302302344168886861743721325075L,
|
||||
-0.00048820246337241825839308387373932012069L,
|
||||
-0.16502375271306657440386132787211370224e-4L,
|
||||
-0.20455790127365005976211054106294513345e-6L,
|
||||
-0.92211014694806710961336881668647739535e-11L,
|
||||
0.48185872432754633773293738021874799566e-13L
|
||||
};
|
||||
static const T Q[] = {
|
||||
1,
|
||||
2.6212362318426769040294336710114361821L,
|
||||
2.6854465068215025330325911346470503289L,
|
||||
1.4324621846378328535720514425511165882L,
|
||||
0.44127839367218238858671258622208841262L,
|
||||
0.081441923652895712841114777288711746235L,
|
||||
0.0089575839091639588314918592219010970046L,
|
||||
0.0005595920067347432979501367393705505528L,
|
||||
0.17654934314236241423226008246523175037e-4L,
|
||||
0.20719702289565546390545985045173039544e-6L
|
||||
};
|
||||
T g = x - root1;
|
||||
g -= root2;
|
||||
g -= root3;
|
||||
g -= root4;
|
||||
g -= root5;
|
||||
T r = tools::evaluate_polynomial(P, x-1) / tools::evaluate_polynomial(Q, x-1);
|
||||
T result = g * Y + g * r;
|
||||
|
||||
return result;
|
||||
}
|
||||
//
|
||||
// 19-digit precision:
|
||||
//
|
||||
template <class T>
|
||||
T digamma_imp_1_2(T x, const mpl::int_<64>*)
|
||||
{
|
||||
//
|
||||
// Now the approximation, we use the form:
|
||||
//
|
||||
// digamma(x) = (x - root) * (Y + R(x-1))
|
||||
//
|
||||
// Where root is the location of the positive root of digamma,
|
||||
// Y is a constant, and R is optimised for low absolute error
|
||||
// compared to Y.
|
||||
//
|
||||
// Max error found at 80-bit long double precision: 5.016e-20
|
||||
// Maximum Deviation Found (approximation error): 3.575e-20
|
||||
//
|
||||
static const float Y = 0.99558162689208984375F;
|
||||
|
||||
static const T root1 = 1569415565.0 / 1073741824uL;
|
||||
static const T root2 = (381566830.0 / 1073741824uL) / 1073741824uL;
|
||||
static const T root3 = 0.9016312093258695918615325266959189453125e-19L;
|
||||
|
||||
static const T P[] = {
|
||||
0.254798510611315515235L,
|
||||
-0.314628554532916496608L,
|
||||
-0.665836341559876230295L,
|
||||
-0.314767657147375752913L,
|
||||
-0.0541156266153505273939L,
|
||||
-0.00289268368333918761452L
|
||||
};
|
||||
static const T Q[] = {
|
||||
1,
|
||||
2.1195759927055347547L,
|
||||
1.54350554664961128724L,
|
||||
0.486986018231042975162L,
|
||||
0.0660481487173569812846L,
|
||||
0.00298999662592323990972L,
|
||||
-0.165079794012604905639e-5L,
|
||||
0.317940243105952177571e-7L
|
||||
};
|
||||
T g = x - root1;
|
||||
g -= root2;
|
||||
g -= root3;
|
||||
T r = tools::evaluate_polynomial(P, x-1) / tools::evaluate_polynomial(Q, x-1);
|
||||
T result = g * Y + g * r;
|
||||
|
||||
return result;
|
||||
}
|
||||
//
|
||||
// 18-digit precision:
|
||||
//
|
||||
template <class T>
|
||||
T digamma_imp_1_2(T x, const mpl::int_<53>*)
|
||||
{
|
||||
//
|
||||
// Now the approximation, we use the form:
|
||||
//
|
||||
// digamma(x) = (x - root) * (Y + R(x-1))
|
||||
//
|
||||
// Where root is the location of the positive root of digamma,
|
||||
// Y is a constant, and R is optimised for low absolute error
|
||||
// compared to Y.
|
||||
//
|
||||
// Maximum Deviation Found: 1.466e-18
|
||||
// At double precision, max error found: 2.452e-17
|
||||
//
|
||||
static const float Y = 0.99558162689208984F;
|
||||
|
||||
static const T root1 = 1569415565.0 / 1073741824uL;
|
||||
static const T root2 = (381566830.0 / 1073741824uL) / 1073741824uL;
|
||||
static const T root3 = 0.9016312093258695918615325266959189453125e-19L;
|
||||
|
||||
static const T P[] = {
|
||||
0.25479851061131551L,
|
||||
-0.32555031186804491L,
|
||||
-0.65031853770896507L,
|
||||
-0.28919126444774784L,
|
||||
-0.045251321448739056L,
|
||||
-0.0020713321167745952L
|
||||
};
|
||||
static const T Q[] = {
|
||||
1L,
|
||||
2.0767117023730469L,
|
||||
1.4606242909763515L,
|
||||
0.43593529692665969L,
|
||||
0.054151797245674225L,
|
||||
0.0021284987017821144L,
|
||||
-0.55789841321675513e-6L
|
||||
};
|
||||
T g = x - root1;
|
||||
g -= root2;
|
||||
g -= root3;
|
||||
T r = tools::evaluate_polynomial(P, x-1) / tools::evaluate_polynomial(Q, x-1);
|
||||
T result = g * Y + g * r;
|
||||
|
||||
return result;
|
||||
}
|
||||
//
|
||||
// 9-digit precision:
|
||||
//
|
||||
template <class T>
|
||||
T digamma_imp_1_2(T x, const mpl::int_<24>*)
|
||||
{
|
||||
//
|
||||
// Now the approximation, we use the form:
|
||||
//
|
||||
// digamma(x) = (x - root) * (Y + R(x-1))
|
||||
//
|
||||
// Where root is the location of the positive root of digamma,
|
||||
// Y is a constant, and R is optimised for low absolute error
|
||||
// compared to Y.
|
||||
//
|
||||
// Maximum Deviation Found: 3.388e-010
|
||||
// At float precision, max error found: 2.008725e-008
|
||||
//
|
||||
static const float Y = 0.99558162689208984f;
|
||||
static const T root = 1532632.0f / 1048576;
|
||||
static const T root_minor = static_cast<T>(0.3700660185912626595423257213284682051735604e-6L);
|
||||
static const T P[] = {
|
||||
0.25479851023250261e0,
|
||||
-0.44981331915268368e0,
|
||||
-0.43916936919946835e0,
|
||||
-0.61041765350579073e-1
|
||||
};
|
||||
static const T Q[] = {
|
||||
0.1e1,
|
||||
0.15890202430554952e1,
|
||||
0.65341249856146947e0,
|
||||
0.63851690523355715e-1
|
||||
};
|
||||
T g = x - root;
|
||||
g -= root_minor;
|
||||
T r = tools::evaluate_polynomial(P, x-1) / tools::evaluate_polynomial(Q, x-1);
|
||||
T result = g * Y + g * r;
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
template <class T, class Tag>
|
||||
T digamma_imp(T x, const Tag* t)
|
||||
{
|
||||
//
|
||||
// This handles reflection of negative arguments, and all our
|
||||
// error handling, then forwards to the T-specific approximation.
|
||||
//
|
||||
using namespace std; // ADL of std functions.
|
||||
|
||||
T result = 0;
|
||||
//
|
||||
// Check for negative arguments and use reflection:
|
||||
//
|
||||
if(x < 0)
|
||||
{
|
||||
// Reflect:
|
||||
x = 1 - x;
|
||||
// Argument reduction for tan:
|
||||
T remainder = x - floor(x);
|
||||
// Shift to negative if > 0.5:
|
||||
if(remainder > 0.5)
|
||||
{
|
||||
remainder -= 1;
|
||||
}
|
||||
//
|
||||
// check for evaluation at a negative pole:
|
||||
//
|
||||
if(remainder == 0)
|
||||
{
|
||||
return tools::pole_error<T>(BOOST_CURRENT_FUNCTION, 0, (1-x));
|
||||
}
|
||||
result = constants::pi<T>() / tan(constants::pi<T>() * remainder);
|
||||
}
|
||||
//
|
||||
// If we're above the lower-limit for the
|
||||
// asymptotic expansion then use it:
|
||||
//
|
||||
if(x >= digamma_large_lim(t))
|
||||
{
|
||||
result += digamma_imp_large(x, t);
|
||||
}
|
||||
else
|
||||
{
|
||||
//
|
||||
// If x > 2 reduce to the interval [1,2]:
|
||||
//
|
||||
while(x > 2)
|
||||
{
|
||||
x -= 1;
|
||||
result += 1/x;
|
||||
}
|
||||
//
|
||||
// If x < 1 use recurrance to shift to > 1:
|
||||
//
|
||||
if(x < 1)
|
||||
{
|
||||
result = -1/x;
|
||||
x += 1;
|
||||
}
|
||||
result += digamma_imp_1_2(x, t);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
} // namespace detail
|
||||
|
||||
template <class T>
|
||||
T digamma(T x)
|
||||
{
|
||||
typedef typename tools::evaluation<typename remove_cv<T>::type>::type value_type;
|
||||
typedef typename mpl::if_c<
|
||||
(std::numeric_limits<T>::digits == 0)
|
||||
||
|
||||
(std::numeric_limits<T>::digits > 64),
|
||||
mpl::int_<0>,
|
||||
typename mpl::if_c<
|
||||
(std::numeric_limits<T>::digits < 25),
|
||||
mpl::int_<24>,
|
||||
typename mpl::if_c<
|
||||
(std::numeric_limits<T>::digits < 54),
|
||||
mpl::int_<53>,
|
||||
mpl::int_<64>
|
||||
>::type
|
||||
>::type
|
||||
>::type tag_type;
|
||||
|
||||
return tools::checked_narrowing_cast<typename remove_cv<T>::type>(detail::digamma_imp(
|
||||
static_cast<value_type>(x),
|
||||
static_cast<const tag_type*>(0)), BOOST_CURRENT_FUNCTION);
|
||||
}
|
||||
|
||||
} // namespace math
|
||||
} // namespace boost
|
||||
#endif
|
||||
@@ -6,6 +6,8 @@
|
||||
#ifndef BOOST_MATH_TOOLS_EVALUATION_TYPE_HPP
|
||||
#define BOOST_MATH_TOOLS_EVALUATION_TYPE_HPP
|
||||
|
||||
#include <boost/mpl/if.hpp>
|
||||
|
||||
namespace boost{ namespace math{ namespace tools{
|
||||
|
||||
template <class T>
|
||||
|
||||
@@ -1,6 +1,11 @@
|
||||
// (C) Copyright John Maddock 2006.
|
||||
// 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)
|
||||
|
||||
#define L22
|
||||
#include "../tools/ntl_rr_lanczos.hpp"
|
||||
#include "../tools/ntl_rr_digamma.hpp"
|
||||
#include <boost/math/tools/ntl.hpp>
|
||||
#include <boost/math/tools/polynomial.hpp>
|
||||
#include <boost/math/special_functions/log1p.hpp>
|
||||
@@ -10,6 +15,7 @@
|
||||
|
||||
#include <cmath>
|
||||
|
||||
|
||||
NTL::RR f(const NTL::RR& x, int variant)
|
||||
{
|
||||
static const NTL::RR tiny = boost::math::tools::min_value<NTL::RR>() * 64;
|
||||
@@ -107,11 +113,6 @@ NTL::RR f(const NTL::RR& x, int variant)
|
||||
return sqrt(-2 * log(y)) / boost::math::erfc_inv(y);
|
||||
}
|
||||
case 9:
|
||||
{
|
||||
NTL::RR y = 0.5 - x;
|
||||
return boost::math::erfc_inv(y);
|
||||
}
|
||||
case 10:
|
||||
{
|
||||
NTL::RR x2 = x;
|
||||
if(x2 == 0)
|
||||
@@ -119,16 +120,32 @@ NTL::RR f(const NTL::RR& x, int variant)
|
||||
NTL::RR y = exp(-x2*x2); // sqrt(-log(x2)) - 5;
|
||||
return boost::math::erfc_inv(y) / x2;
|
||||
}
|
||||
case 10:
|
||||
{
|
||||
int current_precision = NTL::RR::precision();
|
||||
if(current_precision < 1000)
|
||||
NTL::RR::SetPrecision(1000);
|
||||
//
|
||||
// This value for the root of digamma is calculated using our
|
||||
// differentiated lanczos approximation. It agrees with Cody
|
||||
// to ~ 25 digits and to Morris to 35 digits. See:
|
||||
// TOLMS ALGORITHM 708 (Didonato and Morris).
|
||||
// and Math. Comp. 27, 123-127 (1973) by Cody, Strecok and Thacher.
|
||||
//
|
||||
NTL::RR root = boost::lexical_cast<NTL::RR>("1.4616321449683623412626595423257213234331845807102825466429633351908372838889871");
|
||||
|
||||
NTL::RR x2 = x;
|
||||
if(x2 == root)
|
||||
x2 += 1e-40;
|
||||
NTL::RR result = boost::math::digamma(x2) / (x2 - root);
|
||||
if(current_precision < 1000)
|
||||
NTL::RR::SetPrecision(current_precision);
|
||||
return result;
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
NTL::RR f(const NTL::RR& x, int variant)
|
||||
{
|
||||
return f0<NTL::RR>(x, variant);
|
||||
}*/
|
||||
|
||||
void show_extra(
|
||||
const boost::math::tools::polynomial<NTL::RR>& n,
|
||||
const boost::math::tools::polynomial<NTL::RR>& d,
|
||||
@@ -138,14 +155,9 @@ void show_extra(
|
||||
{
|
||||
switch(variant)
|
||||
{
|
||||
case 9:
|
||||
{
|
||||
NTL::RR v = boost::math::tools::log_min_value<NTL::RR>();
|
||||
v *= -2;
|
||||
v = sqrt(v);
|
||||
v = 1 / v;
|
||||
std::cout << "Minimum range = " << v << std::endl;
|
||||
}
|
||||
default:
|
||||
// do nothing here...
|
||||
;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,3 +1,7 @@
|
||||
// (C) Copyright John Maddock 2006.
|
||||
// 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)
|
||||
|
||||
#define BOOST_UBLAS_TYPE_CHECK_EPSILON (type_traits<real_type>::type_sqrt (boost::math::tools::epsilon <real_type>()))
|
||||
#define BOOST_UBLAS_TYPE_CHECK_MIN (type_traits<real_type>::type_sqrt ( boost::math::tools::min_value<real_type>()))
|
||||
@@ -61,6 +65,7 @@ void step_some(unsigned count)
|
||||
rel_error,
|
||||
skew,
|
||||
working_precision));
|
||||
std::cout << "Max error in interpolated form: " << std::setprecision(3) << std::scientific << boost::math::tools::real_cast<double>(p_remez->max_error()) << std::endl;
|
||||
//
|
||||
// Signal that we've started:
|
||||
//
|
||||
@@ -397,4 +402,4 @@ int test_main(int, char* [])
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -38,4 +38,7 @@ run test_roots.cpp ;
|
||||
run test_students_t.cpp ;
|
||||
run test_tgamma_ratio.cpp ;
|
||||
run test_toms748_solve.cpp ;
|
||||
run test_digamma.cpp ;
|
||||
|
||||
|
||||
|
||||
|
||||
505
test/digamma_data.ipp
Normal file
505
test/digamma_data.ipp
Normal file
@@ -0,0 +1,505 @@
|
||||
#define SC_(x) static_cast<T>(BOOST_JOIN(x, L))
|
||||
static const boost::array<boost::array<T, 2>, 500> digamma_data = {
|
||||
SC_(2.818432331085205078125), SC_(0.8484115700906551606307984398000472347785),
|
||||
SC_(4.6342258453369140625), SC_(1.421713669467331557347601964119226105014),
|
||||
SC_(4.783483982086181640625), SC_(1.457016504476551729585831562031964212238),
|
||||
SC_(8.0939121246337890625), SC_(2.02806725001046109435006913084666450899),
|
||||
SC_(11.90207004547119140625), SC_(2.434114987242530269375534072241650635459),
|
||||
SC_(13.53912639617919921875), SC_(2.568199379535107033473901142572267131293),
|
||||
SC_(15.40344142913818359375), SC_(2.70177959979566700235213147968567613712),
|
||||
SC_(16.5205841064453125), SC_(2.774036634025874647373138331993451055497),
|
||||
SC_(17.7738971710205078125), SC_(2.849336085709903318587899668469823726457),
|
||||
SC_(18.45084381103515625), SC_(2.887766358793563776387986802412157943366),
|
||||
SC_(29.2202816009521484375), SC_(3.357654052423628189208902434898861034575),
|
||||
SC_(31.832843780517578125), SC_(3.444709303236843682984386511584019805155),
|
||||
SC_(33.268566131591796875), SC_(3.48950850367834697800598135337384460165),
|
||||
SC_(34.31731414794921875), SC_(3.521009352966155255811365379184456009466),
|
||||
SC_(34.446079254150390625), SC_(3.524809514386367110160928575889334171204),
|
||||
SC_(35.711681365966796875), SC_(3.561411485674988633898237821294494311983),
|
||||
SC_(36.441249847412109375), SC_(3.581917907724542515429931900299321464116),
|
||||
SC_(40.471111297607421875), SC_(3.688183052096727944017539059038660866267),
|
||||
SC_(42.0541229248046875), SC_(3.727020872145296937504698477067321294092),
|
||||
SC_(43.023799896240234375), SC_(3.750086956755859174992028774044963741414),
|
||||
SC_(45.059543609619140625), SC_(3.796847336482220986142117794493357261772),
|
||||
SC_(46.171390533447265625), SC_(3.821492048093989120306052355659348850595),
|
||||
SC_(47.944286346435546875), SC_(3.859574612789685102190529392545009249772),
|
||||
SC_(49.654422760009765625), SC_(3.894984071254501776336224194667579417761),
|
||||
SC_(51.216426849365234375), SC_(3.92626605711337968996352527100620814691),
|
||||
SC_(53.152568817138671875), SC_(3.963730056566564459495465774334833292077),
|
||||
SC_(53.9501190185546875), SC_(3.978763447797611600078998595828792990884),
|
||||
SC_(59.779544830322265625), SC_(4.082276159182205975531619692613299061202),
|
||||
SC_(67.59537506103515625), SC_(4.206124370756245048917505923080906736667),
|
||||
SC_(75.8542938232421875), SC_(4.322208246185371494736862321857785356042),
|
||||
SC_(75.96668243408203125), SC_(4.323698582444848954937627922600414958993),
|
||||
SC_(77.55702972412109375), SC_(4.344552810478025331117690547449165135348),
|
||||
SC_(78.17552947998046875), SC_(4.352547177563450363247154506704116472633),
|
||||
SC_(81.125762939453125), SC_(4.389824647463436852929138346906265829317),
|
||||
SC_(83.821380615234375), SC_(4.422711187859794187691096231764756635029),
|
||||
SC_(84.43585205078125), SC_(4.430058755062111563873245625234033772093),
|
||||
SC_(85.5157928466796875), SC_(4.442842802158912826398856512764451371231),
|
||||
SC_(89.82315826416015625), SC_(4.492266007498633968205232190450336649676),
|
||||
SC_(95.3551788330078125), SC_(4.552355925956436228488375948364274467585),
|
||||
SC_(96.45452880859375), SC_(4.563878946335176406579712835902366153383),
|
||||
SC_(97.13177490234375), SC_(4.570912081982896265651973317486608671594),
|
||||
SC_(97.54039764404296875), SC_(4.575131786976403596191579466163638961361),
|
||||
SC_(100.73848724365234375), SC_(4.607556365921065105146592555963264085078),
|
||||
SC_(106.65277099609375), SC_(4.664882989935773341843363089846541745757),
|
||||
SC_(108.061920166015625), SC_(4.678070284634890633120327580057526752699),
|
||||
SC_(109.86175537109375), SC_(4.694664727381252692793513795934630009291),
|
||||
SC_(111.1192169189453125), SC_(4.706097230556212718518769127144178200579),
|
||||
SC_(111.20275115966796875), SC_(4.706852091693387791616938432500996073933),
|
||||
SC_(112.46451568603515625), SC_(4.718185320564378713782753437437734301757),
|
||||
SC_(113.192535400390625), SC_(4.724666465501466074724041170795702750496),
|
||||
SC_(117.41765594482421875), SC_(4.761472939730569483093207984677455277661),
|
||||
SC_(118.9976806640625), SC_(4.774896355243431821176509841645237231067),
|
||||
SC_(119.54718017578125), SC_(4.779522826588010949258957921967185987839),
|
||||
SC_(123.31893157958984375), SC_(4.81071393197534640354115364663320564994),
|
||||
SC_(125.18276214599609375), SC_(4.825775288759329337505915366578532955896),
|
||||
SC_(125.89662933349609375), SC_(4.83148439831388328994923062624365450503),
|
||||
SC_(126.98681640625), SC_(4.840140688918909476658690945857238201803),
|
||||
SC_(129.846527099609375), SC_(4.86249754984079778426805097304440742781),
|
||||
SC_(129.9062042236328125), SC_(4.862958815139702327034828252875472153454),
|
||||
SC_(131.973297119140625), SC_(4.878806177776566374942264024665615055025),
|
||||
SC_(132.99603271484375), SC_(4.886555076645559019076170710371114254694),
|
||||
SC_(133.73638916015625), SC_(4.892127259828019964975240621714384800823),
|
||||
SC_(135.4770050048828125), SC_(4.905106717626831988577402303939056656494),
|
||||
SC_(136.0685577392578125), SC_(4.90947974061898410128546715429801925019),
|
||||
SC_(138.0013275146484375), SC_(4.923635775505805776701767785882153544687),
|
||||
SC_(138.62445068359375), SC_(4.928157279267557841707446444163947285747),
|
||||
SC_(140.1438446044921875), SC_(4.939097350804489336186984804448028468727),
|
||||
SC_(141.8863372802734375), SC_(4.951498208532141218325182302525386281704),
|
||||
SC_(144.954803466796875), SC_(4.972968676588775902921394002712748457896),
|
||||
SC_(145.5389862060546875), SC_(4.977004557354005944430878448659040833139),
|
||||
SC_(147.829010009765625), SC_(4.992670168744977024725477253611297229446),
|
||||
SC_(149.113983154296875), SC_(5.001354113685057718576710684744348466536),
|
||||
SC_(149.29400634765625), SC_(5.002564723643670955839282486237921850327),
|
||||
SC_(152.378021240234375), SC_(5.023079513160560927910374282855545874691),
|
||||
SC_(154.43841552734375), SC_(5.036554381553671577576060432491657040309),
|
||||
SC_(157.6130828857421875), SC_(5.056967507189124773825675779780432867978),
|
||||
SC_(158.057586669921875), SC_(5.059792699534529307362125473412020388939),
|
||||
SC_(162.1822967529296875), SC_(5.085634872441444055790538285561513352114),
|
||||
SC_(162.3285064697265625), SC_(5.086538763499375385825459901390036092276),
|
||||
SC_(162.6117401123046875), SC_(5.088287436707226991346072251084741331228),
|
||||
SC_(162.8721160888671875), SC_(5.089892294410720846921196992521724082324),
|
||||
SC_(165.6487274169921875), SC_(5.106847973878888830832110337446518371119),
|
||||
SC_(167.5558013916015625), SC_(5.118329389684532657993072571814825296866),
|
||||
SC_(168.9900360107421875), SC_(5.126878082277710058624325179569901288279),
|
||||
SC_(170.708038330078125), SC_(5.137022881977642343120933693408155267379),
|
||||
SC_(171.1866912841796875), SC_(5.139831091399062175194966875853774050215),
|
||||
SC_(173.86517333984375), SC_(5.155401584700129074352914825821571994537),
|
||||
SC_(181.572967529296875), SC_(5.198901356355351487232884915474078625454),
|
||||
SC_(181.847015380859375), SC_(5.200413674777345067384965017459287722255),
|
||||
SC_(183.5111541748046875), SC_(5.209548346790303183756319086272109508414),
|
||||
SC_(183.9077911376953125), SC_(5.211713279243515056757039824210382332605),
|
||||
SC_(184.816314697265625), SC_(5.216654609736436280673189918782642034751),
|
||||
SC_(186.8726043701171875), SC_(5.227749118747922979749925127240621358077),
|
||||
SC_(188.3819732666015625), SC_(5.235815144271654507738040431638317824219),
|
||||
SC_(188.9550018310546875), SC_(5.238860434511886935491539718311895522563),
|
||||
SC_(194.4953765869140625), SC_(5.267835433896789878679452996831857175441),
|
||||
SC_(194.7642822265625), SC_(5.269220615601523996859748369572800146799),
|
||||
SC_(196.595245361328125), SC_(5.278601570477420849009352984342881774012),
|
||||
SC_(199.55120849609375), SC_(5.293563172363173736409123622092103582665),
|
||||
SC_(199.87286376953125), SC_(5.29517780707170337549563059440671599137),
|
||||
SC_(207.7422943115234375), SC_(5.333889582810755539805705568562512261187),
|
||||
SC_(208.06805419921875), SC_(5.335460225032043059439507730667027716784),
|
||||
SC_(210.209075927734375), SC_(5.345722164946006440059254445596129365136),
|
||||
SC_(210.3018798828125), SC_(5.346164602882524533186213817875265383748),
|
||||
SC_(211.9243316650390625), SC_(5.353868096697531240993528975318640869535),
|
||||
SC_(213.7727508544921875), SC_(5.362572783030003908578204737735026180568),
|
||||
SC_(217.2378387451171875), SC_(5.378689393785450240762515278142610186647),
|
||||
SC_(221.0340576171875), SC_(5.396052995987518692513315434729480482768),
|
||||
SC_(221.746734619140625), SC_(5.399279376199210442291570588468305439493),
|
||||
SC_(223.419952392578125), SC_(5.406813587612010012477220821227640963526),
|
||||
SC_(223.8119354248046875), SC_(5.40857044312848898111490039577861789539),
|
||||
SC_(225.921783447265625), SC_(5.417974060411836810226948440207258474062),
|
||||
SC_(227.6642913818359375), SC_(5.425674313715258008117354357369952302663),
|
||||
SC_(228.976959228515625), SC_(5.431436168546949625044655797954749386032),
|
||||
SC_(230.15606689453125), SC_(5.436583618434440970405411512638103654567),
|
||||
SC_(230.4881591796875), SC_(5.438028613498667787626776999061156299023),
|
||||
SC_(234.7799072265625), SC_(5.45651734435963939743321146310693692221),
|
||||
SC_(237.2835693359375), SC_(5.467147257515587656692603812143613587167),
|
||||
SC_(239.5024566650390625), SC_(5.47647456024034998344432612758666650177),
|
||||
SC_(239.916168212890625), SC_(5.47820405414781872212296108547269195884),
|
||||
SC_(239.9525146484375), SC_(5.47835585519092106650208297916994251088),
|
||||
SC_(240.0759429931640625), SC_(5.478871182270947292729700821285916853014),
|
||||
SC_(241.6912841796875), SC_(5.48559104520771247073410657218711428497),
|
||||
SC_(243.52496337890625), SC_(5.493164873500147032216227026263947788629),
|
||||
SC_(244.138275146484375), SC_(5.495685348360518575357280836637213941973),
|
||||
SC_(247.84759521484375), SC_(5.510795296469788210349267225408057089008),
|
||||
SC_(251.0838470458984375), SC_(5.523794246827039306466724212993790091993),
|
||||
SC_(252.9559783935546875), SC_(5.53123754427692590099511415861194353476),
|
||||
SC_(254.2821807861328125), SC_(5.53647699008893800801173473697704786508),
|
||||
SC_(255.095123291015625), SC_(5.539675174361895155905420362931642677874),
|
||||
SC_(257.50823974609375), SC_(5.54910877645277178885293455204990306081),
|
||||
SC_(258.064697265625), SC_(5.551271568142368038329308299350794617341),
|
||||
SC_(258.2958984375), SC_(5.552168807470126931792259144648002540331),
|
||||
SC_(259.87042236328125), SC_(5.558257861474442709235556716423323490943),
|
||||
SC_(262.21173095703125), SC_(5.567244242836903141874863560065650986603),
|
||||
SC_(262.48223876953125), SC_(5.568277317584441062906205258279469903793),
|
||||
SC_(262.971282958984375), SC_(5.570142282612872731717692549388720316202),
|
||||
SC_(263.80291748046875), SC_(5.573305747885775172479587641948129399505),
|
||||
SC_(265.920654296875), SC_(5.581316533594154573012665212950951963344),
|
||||
SC_(272.753021240234375), SC_(5.606732421189819995671142457643674993514),
|
||||
SC_(276.02508544921875), SC_(5.618679227574827562968855008817945055844),
|
||||
SC_(276.9229736328125), SC_(5.62193275108461049287671704761080177701),
|
||||
SC_(278.49822998046875), SC_(5.627615285836316944304326354848356653533),
|
||||
SC_(281.6273193359375), SC_(5.638808187647616258573018310333124752979),
|
||||
SC_(282.673309326171875), SC_(5.642521977550928843609142257361465463159),
|
||||
SC_(285.839019775390625), SC_(5.653678528153416638005857155381996231704),
|
||||
SC_(287.80499267578125), SC_(5.660544848531287229964224746346326537309),
|
||||
SC_(296.32080078125), SC_(5.689754344363163686181089294681536867498),
|
||||
SC_(296.675872802734375), SC_(5.690953917746555781396415233069043398008),
|
||||
SC_(297.029449462890625), SC_(5.692147011020137765888724960240975571168),
|
||||
SC_(299.83172607421875), SC_(5.701552875188694305814208034977343378525),
|
||||
SC_(301.246337890625), SC_(5.706267638858004649656056828257867279121),
|
||||
SC_(301.827301025390625), SC_(5.708197511695138802806710871639099088268),
|
||||
SC_(301.913116455078125), SC_(5.708482262307644688021338490250719094243),
|
||||
SC_(303.61395263671875), SC_(5.714109269616552222989399906960963535438),
|
||||
SC_(306.3494873046875), SC_(5.723093554813365658046336277832734920358),
|
||||
SC_(308.16705322265625), SC_(5.729018642421226976646437744710250114317),
|
||||
SC_(311.102294921875), SC_(5.738513731255894331377758163498728167044),
|
||||
SC_(311.215057373046875), SC_(5.738876709545896308969873915166375996455),
|
||||
SC_(312.50799560546875), SC_(5.743029242434299652839488723689056915437),
|
||||
SC_(316.550445556640625), SC_(5.755902255817228423385699779528788254728),
|
||||
SC_(317.0994873046875), SC_(5.757637943754943613314524976138239539917),
|
||||
SC_(318.7783203125), SC_(5.762926632420383028466536214352273605745),
|
||||
SC_(322.5107421875), SC_(5.774585307653271847190205931939723481736),
|
||||
SC_(324.963531494140625), SC_(5.782173541925585116003437602057941223569),
|
||||
SC_(332.448272705078125), SC_(5.804979529807743662919055583913702847441),
|
||||
SC_(337.122650146484375), SC_(5.818962938187135636742305501932989080651),
|
||||
SC_(337.71942138671875), SC_(5.820734186921434094429909639202086179781),
|
||||
SC_(340.219696044921875), SC_(5.828121215221842999606169529284319625934),
|
||||
SC_(340.3857421875), SC_(5.828609869422364475855293647958724101162),
|
||||
SC_(343.83953857421875), SC_(5.838720219369554242298305075518187973959),
|
||||
SC_(343.92974853515625), SC_(5.838982927383424836208079234708676764532),
|
||||
SC_(344.32794189453125), SC_(5.840141715792665213495451845063858259471),
|
||||
SC_(346.2333984375), SC_(5.845668301886241439514342457852325235755),
|
||||
SC_(349.9837646484375), SC_(5.856457448655756722565805616029229423181),
|
||||
SC_(350.72711181640625), SC_(5.858582174643380806977967882520602080122),
|
||||
SC_(350.952392578125), SC_(5.859225209340739029885042670228181902477),
|
||||
SC_(351.659515380859375), SC_(5.861240917897877761839636580241630893874),
|
||||
SC_(352.76239013671875), SC_(5.864376660211097551985117273619920161247),
|
||||
SC_(353.1585693359375), SC_(5.865500698218050522379186042690723838268),
|
||||
SC_(354.63812255859375), SC_(5.869687345986841682980604946721230334574),
|
||||
SC_(356.34515380859375), SC_(5.874496004070293633977629973243397192974),
|
||||
SC_(360.8607177734375), SC_(5.887105844462842568231690256873044524566),
|
||||
SC_(361.29400634765625), SC_(5.888307496020129242675686611572690424192),
|
||||
SC_(363.18646240234375), SC_(5.893539037844593630113143804047702478072),
|
||||
SC_(368.484588623046875), SC_(5.908041366251291466893815884478290769093),
|
||||
SC_(369.246795654296875), SC_(5.910110524295502063829120796381053011945),
|
||||
SC_(378.50042724609375), SC_(5.934895617510447498576865442817972697249),
|
||||
SC_(378.609375), SC_(5.935183797060069242663195486702002966313),
|
||||
SC_(379.418853759765625), SC_(5.937322366182591168893192048144610446318),
|
||||
SC_(380.445831298828125), SC_(5.940028981977972573511311112384361555998),
|
||||
SC_(381.558441162109375), SC_(5.942953039189986310250537695096760920284),
|
||||
SC_(382.33294677734375), SC_(5.944983486642878955588861619779712183753),
|
||||
SC_(385.71051025390625), SC_(5.953790245535102839028892159533990782538),
|
||||
SC_(387.2958984375), SC_(5.957897438189758732168023760232019857062),
|
||||
SC_(388.569793701171875), SC_(5.961185480793951888080130571435866339859),
|
||||
SC_(388.61517333984375), SC_(5.961302410689641047121043666111858152527),
|
||||
SC_(389.73883056640625), SC_(5.964193390561584996249624057879172484094),
|
||||
SC_(392.227020263671875), SC_(5.970565491861186670927570593593922746651),
|
||||
SC_(392.320465087890625), SC_(5.970804009055547779176675482333698236361),
|
||||
SC_(393.58984375), SC_(5.974038465445461053564629207897789530972),
|
||||
SC_(394.908233642578125), SC_(5.977386766739159526527423143050993473122),
|
||||
SC_(398.738525390625), SC_(5.987051398521802594134573229887245743555),
|
||||
SC_(399.78265380859375), SC_(5.98966983297736662713511729544362351217),
|
||||
SC_(401.808013916015625), SC_(5.994729505682939003379681261442316095543),
|
||||
SC_(403.912139892578125), SC_(5.999958975030022983362581727689153017309),
|
||||
SC_(404.20849609375), SC_(6.000693328854312027033338977366250530793),
|
||||
SC_(404.98138427734375), SC_(6.002605968553351055079821088079186595986),
|
||||
SC_(408.7198486328125), SC_(6.011806124002334414126565011018849669266),
|
||||
SC_(408.731170654296875), SC_(6.011833858711596841091740153684611585383),
|
||||
SC_(412.666534423828125), SC_(6.021427722714450543272375426891465502276),
|
||||
SC_(417.267059326171875), SC_(6.032527694873243105931087101820210964016),
|
||||
SC_(420.18994140625), SC_(6.039516440455429955766164077664900139336),
|
||||
SC_(421.761260986328125), SC_(6.043253448414102502433018626928644727058),
|
||||
SC_(422.087677001953125), SC_(6.044028002107108186220134524106733043847),
|
||||
SC_(423.16510009765625), SC_(6.046580373164618907726121091198392578715),
|
||||
SC_(424.166778564453125), SC_(6.048947478773228346602304770587362502163),
|
||||
SC_(430.2073974609375), SC_(6.063104731694863158498203027307993195815),
|
||||
SC_(431.413818359375), SC_(6.065908337098829708316996099109173916052),
|
||||
SC_(435.245697021484375), SC_(6.074761476046398186404025268023433471772),
|
||||
SC_(435.698699951171875), SC_(6.075802928287907510845374398686273404793),
|
||||
SC_(435.85858154296875), SC_(6.07617023673887939600287017602598678356),
|
||||
SC_(436.1175537109375), SC_(6.076764907594542344403398466659178736447),
|
||||
SC_(438.66680908203125), SC_(6.08259989755215167271203767330669598323),
|
||||
SC_(438.744354248046875), SC_(6.082776858174768286116463240157641988703),
|
||||
SC_(438.8699951171875), SC_(6.083063508320507989449416901329106432625),
|
||||
SC_(441.223480224609375), SC_(6.088417864327000147587478272648801388231),
|
||||
SC_(442.67828369140625), SC_(6.091713370624069002395664415060658196535),
|
||||
SC_(445.586212158203125), SC_(6.09826820891842885583333776024666913377),
|
||||
SC_(446.78375244140625), SC_(6.100955175158840019640884425000576615711),
|
||||
SC_(447.584381103515625), SC_(6.102747557295619121106102670653678229036),
|
||||
SC_(449.55609130859375), SC_(6.107148011530301966053822903337711218286),
|
||||
SC_(450.541595458984375), SC_(6.10934021856897802099580290683898433424),
|
||||
SC_(450.9237060546875), SC_(6.110188914150944431871753996420181358557),
|
||||
SC_(456.032806396484375), SC_(6.121467937724061922128554049058015478328),
|
||||
SC_(457.989166259765625), SC_(6.125753403208273372726190971914060421286),
|
||||
SC_(458.49688720703125), SC_(6.126862586238352284366184295285682829153),
|
||||
SC_(458.848846435546875), SC_(6.127630765961755033027033241022489856889),
|
||||
SC_(462.47418212890625), SC_(6.135509201915263462051894175844019358072),
|
||||
SC_(469.390625), SC_(6.150369721809370729825444412044817108946),
|
||||
SC_(470.92333984375), SC_(6.153633200651127889846979557070586407071),
|
||||
SC_(471.956787109375), SC_(6.155827635510642589118081435451236816658),
|
||||
SC_(473.01507568359375), SC_(6.158069839252994031314486039965613313878),
|
||||
SC_(473.288848876953125), SC_(6.15864906693157877173538018092295228381),
|
||||
SC_(474.758697509765625), SC_(6.161753133400770857335496852979821817608),
|
||||
SC_(476.638092041015625), SC_(6.165708105278002487733159955708518039802),
|
||||
SC_(485.375640869140625), SC_(6.183892624705687372974280692449022738796),
|
||||
SC_(486.7916259765625), SC_(6.18680867358564366225953846900945967356),
|
||||
SC_(487.56890869140625), SC_(6.188405784992797235754687039867456958423),
|
||||
SC_(488.608978271484375), SC_(6.190538871937823182207008881895013566252),
|
||||
SC_(488.617706298828125), SC_(6.190556753080449523844892653864095258225),
|
||||
SC_(489.25262451171875), SC_(6.191856655555710657680907555429146440994),
|
||||
SC_(489.764404296875), SC_(6.192903221491570223625167765358468005398),
|
||||
SC_(490.301483154296875), SC_(6.194000346274314039340661485248412605601),
|
||||
SC_(490.58905029296875), SC_(6.194587283360205433159890246616353800577),
|
||||
SC_(490.864105224609375), SC_(6.195148360331463990452548262484128395487),
|
||||
SC_(492.441986083984375), SC_(6.198360967247667289203047166777662852555),
|
||||
SC_(493.32684326171875), SC_(6.200158053193846223394413941905224342212),
|
||||
SC_(498.36407470703125), SC_(6.210327265513424866339085669932575635988),
|
||||
SC_(498.544189453125), SC_(6.21068897490776727949765832965196264653),
|
||||
SC_(503.190032958984375), SC_(6.219973908373394206679161074530674466899),
|
||||
SC_(503.6627197265625), SC_(6.220913780825655911052191262801777393669),
|
||||
SC_(504.77099609375), SC_(6.223113978085038338735916934803931854624),
|
||||
SC_(505.49853515625), SC_(6.224555691973970405577369173344297221254),
|
||||
SC_(505.957061767578125), SC_(6.225463255838234486684327725118604039811),
|
||||
SC_(507.8582763671875), SC_(6.229217575393520147953064296764206590646),
|
||||
SC_(508.5086669921875), SC_(6.230498669894225271351080293124801058189),
|
||||
SC_(510.771575927734375), SC_(6.234943245832893913399836097415067319716),
|
||||
SC_(513.24951171875), SC_(6.239787603153936308761478021300341867958),
|
||||
SC_(527.3714599609375), SC_(6.26695675989766014952180473516016639132),
|
||||
SC_(528.53314208984375), SC_(6.269159200285662272626421793314655554156),
|
||||
SC_(529.84197998046875), SC_(6.271634836682912113235700829440296732259),
|
||||
SC_(530.79754638671875), SC_(6.273438405458562785658780556867743148032),
|
||||
SC_(532.8255615234375), SC_(6.277255406962121270372044267186720492822),
|
||||
SC_(533.93310546875), SC_(6.27933382124723736043226562438644919799),
|
||||
SC_(538.3424072265625), SC_(6.28756573791909313051189664771803422567),
|
||||
SC_(540.13800048828125), SC_(6.290898688375581006405495741840322979188),
|
||||
SC_(543.80548095703125), SC_(6.297671882932801362742512328060055029049),
|
||||
SC_(544.05609130859375), SC_(6.298133046141955500936690446904311697961),
|
||||
SC_(546.5919189453125), SC_(6.302787451011865112672341728223109009577),
|
||||
SC_(546.8814697265625), SC_(6.303317533868186538707062673105932672072),
|
||||
SC_(547.00885009765625), SC_(6.303550641132128690074401949014653406049),
|
||||
SC_(547.21551513671875), SC_(6.303928724516392966155084897475347327756),
|
||||
SC_(547.2205810546875), SC_(6.303937990566003104329651374824144391912),
|
||||
SC_(549.7236328125), SC_(6.308505842439691623988056771871693216424),
|
||||
SC_(549.86016845703125), SC_(6.308754409016708944632117615324933227263),
|
||||
SC_(550.1563720703125), SC_(6.309293442830642860089093034772365129842),
|
||||
SC_(552.88116455078125), SC_(6.314238460027511407047381188737584243717),
|
||||
SC_(558.268798828125), SC_(6.323944671432167039241381145581814873829),
|
||||
SC_(561.5574951171875), SC_(6.329823519476373092212405522576108829899),
|
||||
SC_(567.82159423828125), SC_(6.340926458002524075449031889956629217335),
|
||||
SC_(568.8236083984375), SC_(6.342691118582913267534099618695745472789),
|
||||
SC_(573.754638671875), SC_(6.351330140380622771107787271382996222648),
|
||||
SC_(575.2086181640625), SC_(6.353863287488337643657368466542593119861),
|
||||
SC_(578.52508544921875), SC_(6.359617392870022484646570771392481186969),
|
||||
SC_(579.70458984375), SC_(6.361655889694939183701010004548872090829),
|
||||
SC_(580.95672607421875), SC_(6.363815376071726439662811719409699982055),
|
||||
SC_(584.38226318359375), SC_(6.369699480584486422871125906468857080696),
|
||||
SC_(585.26409912109375), SC_(6.371208638389763868709447504290801733396),
|
||||
SC_(585.2677001953125), SC_(6.37121479653500333470827397736457127071),
|
||||
SC_(587.04473876953125), SC_(6.374249067232996439686972718899923431032),
|
||||
SC_(592.8238525390625), SC_(6.384053652275533641719864391983551192749),
|
||||
SC_(594.50360107421875), SC_(6.386885499848034458902157664992427248316),
|
||||
SC_(594.89605712890625), SC_(6.387545977951704153497341261837707303324),
|
||||
SC_(601.98193359375), SC_(6.399396614546605823173454188612392794784),
|
||||
SC_(602.84307861328125), SC_(6.400827295849304940475815798766156086542),
|
||||
SC_(604.23150634765625), SC_(6.403129687503785434500679408789199298648),
|
||||
SC_(616.044677734375), SC_(6.422507640667089449069553404969421958134),
|
||||
SC_(620.36004638671875), SC_(6.429493829366529691782302916589330838881),
|
||||
SC_(622.05511474609375), SC_(6.432224695074060781574961177412352412717),
|
||||
SC_(622.47509765625), SC_(6.432900163721955173795252325722094013871),
|
||||
SC_(623.435546875), SC_(6.434443164750907605937303777412492801794),
|
||||
SC_(625.61859130859375), SC_(6.437941484456789575138548752117584086992),
|
||||
SC_(627.38433837890625), SC_(6.440762161347675760635876431243167810861),
|
||||
SC_(632.3592529296875), SC_(6.448666772647988605535323096388911661556),
|
||||
SC_(633.06365966796875), SC_(6.449780967364441602752385978976936185726),
|
||||
SC_(639.76336669921875), SC_(6.460316625883878714928422495164000965323),
|
||||
SC_(643.9609375), SC_(6.466861422641841163115547439790852566178),
|
||||
SC_(644.318115234375), SC_(6.467416356975518058351605023347089876719),
|
||||
SC_(644.550537109375), SC_(6.467777297247478327338444774262678613444),
|
||||
SC_(646.31298828125), SC_(6.470510069949258359745036258720962577061),
|
||||
SC_(647.7459716796875), SC_(6.472726494325499127620694571869476943941),
|
||||
SC_(649.115478515625), SC_(6.474840157130650254368072192966429504885),
|
||||
SC_(651.9686279296875), SC_(6.479229339980760566248271955481499493423),
|
||||
SC_(654.0791015625), SC_(6.482463666223159470601395935144865056701),
|
||||
SC_(655.0980224609375), SC_(6.484021438312744798558143642548832482531),
|
||||
SC_(655.4779052734375), SC_(6.484601599785286175366253598788561328841),
|
||||
SC_(655.74066162109375), SC_(6.485002687522549887824574950594472055316),
|
||||
SC_(655.7799072265625), SC_(6.485062580665467941142729902484080793074),
|
||||
SC_(660.11944580078125), SC_(6.491663167216662693403076432415948835692),
|
||||
SC_(663.60552978515625), SC_(6.49693424239261660697884227280722447065),
|
||||
SC_(669.28509521484375), SC_(6.505462868816168906848474745781783475634),
|
||||
SC_(678.735107421875), SC_(6.519494084518996469650508956074345352049),
|
||||
SC_(679.51971435546875), SC_(6.520650251903972495307924790017120133482),
|
||||
SC_(679.70269775390625), SC_(6.52091969726851616942271814508002088275),
|
||||
SC_(679.81976318359375), SC_(6.521092039518570890159009605013714327936),
|
||||
SC_(680.28704833984375), SC_(6.521779675083894126919680539525971204723),
|
||||
SC_(680.4066162109375), SC_(6.521955549772378968850975278275518538879),
|
||||
SC_(681.35955810546875), SC_(6.523356145843551429282561007449588269899),
|
||||
SC_(686.77545166015625), SC_(6.531279168634480064303406688971587947728),
|
||||
SC_(689.21453857421875), SC_(6.53482696034163300895210941857399062802),
|
||||
SC_(694.82861328125), SC_(6.542945441035880360749863408250769056176),
|
||||
SC_(695.23284912109375), SC_(6.5435274682425404780673540153675890027),
|
||||
SC_(699.07672119140625), SC_(6.549045095113352556887019319492674591721),
|
||||
SC_(705.77423095703125), SC_(6.558586791026949965247721665028964915463),
|
||||
SC_(706.04608154296875), SC_(6.558972170428375943894892162331319111229),
|
||||
SC_(707.321533203125), SC_(6.560778289147646212053005392960932901218),
|
||||
SC_(709.36480712890625), SC_(6.563664910211286354361274659607364432189),
|
||||
SC_(710.703857421875), SC_(6.565552134560890098719864436298697541221),
|
||||
SC_(711.2158203125), SC_(6.566272742257831657216451568845017111234),
|
||||
SC_(716.1007080078125), SC_(6.573122422391305665202378372481901866655),
|
||||
SC_(718.469970703125), SC_(6.576427825470989904051723420894245752996),
|
||||
SC_(720.493408203125), SC_(6.579242137071712732628854802208909850768),
|
||||
SC_(725.8389892578125), SC_(6.586639196163926236455690072217971768091),
|
||||
SC_(726.6544189453125), SC_(6.587762769498345108593561389467357233635),
|
||||
SC_(726.9547119140625), SC_(6.588176222669208952468481654231519862001),
|
||||
SC_(730.33087158203125), SC_(6.592812902760243297414563417571806817033),
|
||||
SC_(731.722412109375), SC_(6.594717748731769186160610648305398172825),
|
||||
SC_(732.7987060546875), SC_(6.596188576803175388558793950872542497826),
|
||||
SC_(740.64727783203125), SC_(6.606849266552187262338997827259823953612),
|
||||
SC_(743.1324462890625), SC_(6.610201309160827227217063092842877635818),
|
||||
SC_(744.69281005859375), SC_(6.612300229797847496307719944337046025631),
|
||||
SC_(748.151611328125), SC_(6.616937183758078139241196510560664648452),
|
||||
SC_(749.94097900390625), SC_(6.619327641466965773804177461936924399101),
|
||||
SC_(751.26708984375), SC_(6.621095544221748738916949620438022847397),
|
||||
SC_(753.7291259765625), SC_(6.624369539120572790247890002187576586953),
|
||||
SC_(754.6866455078125), SC_(6.625639951090094344607777868204027432855),
|
||||
SC_(755.78985595703125), SC_(6.62710166378741985559108127492656943644),
|
||||
SC_(757.20025634765625), SC_(6.628967285239014652929108380360053789214),
|
||||
SC_(757.50360107421875), SC_(6.629368083169212155191930540373997326396),
|
||||
SC_(757.7401123046875), SC_(6.629680465113967501897080616727473070964),
|
||||
SC_(761.731201171875), SC_(6.634937195939679832108830040398849824872),
|
||||
SC_(762.42132568359375), SC_(6.635843374996103932953744864855947073907),
|
||||
SC_(762.931396484375), SC_(6.636512604288287695667831495157907988255),
|
||||
SC_(763.75), SC_(6.637585703139515450729086875916629124126),
|
||||
SC_(765.516845703125), SC_(6.639897925305579070472267454056802592828),
|
||||
SC_(773.9171142578125), SC_(6.650818577182925150685349765007717566496),
|
||||
SC_(774.91046142578125), SC_(6.652102114421492829419722285286772404085),
|
||||
SC_(775.712646484375), SC_(6.653137443611928596722616479632884363769),
|
||||
SC_(778.897705078125), SC_(6.6572376513800787667154306478413125791),
|
||||
SC_(779.167236328125), SC_(6.657583855585783056176609207961461550674),
|
||||
SC_(779.68939208984375), SC_(6.658254207016113619993993137077534358157),
|
||||
SC_(780.2274169921875), SC_(6.658944461745262492487573187543498710589),
|
||||
SC_(780.25201416015625), SC_(6.658976007098292587450609334547284886854),
|
||||
SC_(781.9091796875), SC_(6.661098998535236012443285119544067308945),
|
||||
SC_(792.207275390625), SC_(6.674191788190495720635040843079615121198),
|
||||
SC_(793.59759521484375), SC_(6.675946351193374567715402021389527667759),
|
||||
SC_(793.9749755859375), SC_(6.676422068894767804835061682908706231587),
|
||||
SC_(794.2845458984375), SC_(6.676812137779252911754812198193513578098),
|
||||
SC_(794.8314208984375), SC_(6.677500846866967477229981288001168637074),
|
||||
SC_(795.199951171875), SC_(6.677964689479356370863371111643685192501),
|
||||
SC_(797.2799072265625), SC_(6.680578554749739014414223828144905732992),
|
||||
SC_(797.3641357421875), SC_(6.680684260292981427494930116387169656838),
|
||||
SC_(797.92864990234375), SC_(6.681392428974166964964677408576394246851),
|
||||
SC_(798.1058349609375), SC_(6.68161459976456580623320912581051620254),
|
||||
SC_(799.6531982421875), SC_(6.683552730103765717785258709879113031128),
|
||||
SC_(800.0684814453125), SC_(6.684072249121468373962678765344998551064),
|
||||
SC_(800.28045654296875), SC_(6.684337325823917944748077105114139749528),
|
||||
SC_(801.01458740234375), SC_(6.685254820154850118553681554697581754228),
|
||||
SC_(802.1114501953125), SC_(6.686624079247030582774578430359074551284),
|
||||
SC_(807.531005859375), SC_(6.693362152645817588123872344533895119059),
|
||||
SC_(808.17547607421875), SC_(6.694160403193372004065984871882451973199),
|
||||
SC_(809.13720703125), SC_(6.695350434005938715450618220546308991728),
|
||||
SC_(809.7344970703125), SC_(6.696088799092145379287817855954413316766),
|
||||
SC_(811.58050537109375), SC_(6.698367379321691365123987787716196541633),
|
||||
SC_(811.87396240234375), SC_(6.69872912383054362547878895705642827061),
|
||||
SC_(814.2847900390625), SC_(6.701696008262299263121462513848022021511),
|
||||
SC_(814.72369384765625), SC_(6.702235199265751419311368399785889082955),
|
||||
SC_(815.76910400390625), SC_(6.70351831039065858731291819842905206617),
|
||||
SC_(817.30322265625), SC_(6.705398274761274025517280475385018089932),
|
||||
SC_(817.62774658203125), SC_(6.705795505605953960123274832847788002709),
|
||||
SC_(820.84075927734375), SC_(6.709719875947035021518634958560843902315),
|
||||
SC_(821.19403076171875), SC_(6.710150423121597468638525790922918705368),
|
||||
SC_(821.2459716796875), SC_(6.710213710127498226829732029114238959828),
|
||||
SC_(821.90325927734375), SC_(6.711014231224021145756877729370797694754),
|
||||
SC_(822.60498046875), SC_(6.711868162017285030823308685434146199673),
|
||||
SC_(823.45538330078125), SC_(6.712902048459101920134138581529056322254),
|
||||
SC_(823.45782470703125), SC_(6.712905015086914031224699618961034238211),
|
||||
SC_(825.8170166015625), SC_(6.715767636243291150268286133191516840221),
|
||||
SC_(830.82861328125), SC_(6.721821602486133073771415419589804218135),
|
||||
SC_(831.21429443359375), SC_(6.722285986772520722985120580144878454781),
|
||||
SC_(835.008544921875), SC_(6.726843042451428339229067173099443198509),
|
||||
SC_(840.71728515625), SC_(6.73366059021322264537674210235946387634),
|
||||
SC_(844.30877685546875), SC_(6.737925959738321890628442129723129258846),
|
||||
SC_(848.4677734375), SC_(6.742842689994820594916976128991288216001),
|
||||
SC_(849.12933349609375), SC_(6.743622556956527511542416448168619758566),
|
||||
SC_(853.0311279296875), SC_(6.748209779519757322824915399863143662548),
|
||||
SC_(854.45098876953125), SC_(6.749873859079778299591453176485066806485),
|
||||
SC_(855.8751220703125), SC_(6.751540168929954768274473011138988372597),
|
||||
SC_(862.67816162109375), SC_(6.759461989375137122955523168205353583437),
|
||||
SC_(868.6947021484375), SC_(6.766416056015530146135252193038369240874),
|
||||
SC_(869.29217529296875), SC_(6.767103998002709424523574394478208979411),
|
||||
SC_(870.186767578125), SC_(6.768133164641880669262131602717669262048),
|
||||
SC_(872.4288330078125), SC_(6.770707861861071404604235546152482005058),
|
||||
SC_(875.94281005859375), SC_(6.774729881353175605276607003284786011147),
|
||||
SC_(876.7574462890625), SC_(6.775659990483147584810245626024403172256),
|
||||
SC_(877.3638916015625), SC_(6.776351836800695164519969516994906905958),
|
||||
SC_(878.4306640625), SC_(6.777567674259764690685426386600703554342),
|
||||
SC_(885.99810791015625), SC_(6.786150373612182701581356639019071248638),
|
||||
SC_(887.72613525390625), SC_(6.788099946665576471808465592376033272437),
|
||||
SC_(890.90325927734375), SC_(6.791674512973996076620205962146827011757),
|
||||
SC_(900.0538330078125), SC_(6.80189895079299198904108771904549258351),
|
||||
SC_(900.1832275390625), SC_(6.802042783444049392389068654739673857143),
|
||||
SC_(902.71612548828125), SC_(6.804854149520866258225931342229077189181),
|
||||
SC_(904.88092041015625), SC_(6.807250694718158106286277547784604092869),
|
||||
SC_(905.79193115234375), SC_(6.808257518383144815884886145813559834871),
|
||||
SC_(907.36474609375), SC_(6.809993367381673942808480783672644328598),
|
||||
SC_(908.43359375), SC_(6.811171291835528522342757827992129791562),
|
||||
SC_(910.56494140625), SC_(6.81351601145607889196433654356525525846),
|
||||
SC_(910.6475830078125), SC_(6.813606815790404023323189518843380307986),
|
||||
SC_(912.5775146484375), SC_(6.815725030681610574873878555395906108156),
|
||||
SC_(913.33734130859375), SC_(6.816557756247443703552647371667225468139),
|
||||
SC_(913.3758544921875), SC_(6.816599945984404149476890515171707321892),
|
||||
SC_(915.73553466796875), SC_(6.819181496829614596845401444040303420405),
|
||||
SC_(917.117919921875), SC_(6.820690771903488486844573292669501047527),
|
||||
SC_(917.19366455078125), SC_(6.82077340337986035180672708919674786967),
|
||||
SC_(920.874755859375), SC_(6.824780979614736502636113976154470262398),
|
||||
SC_(923.379638671875), SC_(6.827498872615433477170026117448771541295),
|
||||
SC_(927.49285888671875), SC_(6.8319459105580415512096734861697582082),
|
||||
SC_(928.85418701171875), SC_(6.83341337535443392277100858245459000213),
|
||||
SC_(929.263671875), SC_(6.833854364953862271803203220770951435661),
|
||||
SC_(929.385986328125), SC_(6.833986052262011870912515832740972478803),
|
||||
SC_(933.99322509765625), SC_(6.838933753242727661252945811698284684698),
|
||||
SC_(934.01068115234375), SC_(6.838952452778342207434589177668657889371),
|
||||
SC_(939.0015869140625), SC_(6.844284594236099395567215793156428746645),
|
||||
SC_(940.07403564453125), SC_(6.845426666187627323729754250792575000864),
|
||||
SC_(942.05059814453125), SC_(6.847528135708265169237587238138487198853),
|
||||
SC_(944.7872314453125), SC_(6.850430437191786907351651758111614319783),
|
||||
SC_(948.925048828125), SC_(6.854802811834284555381489323758582235861),
|
||||
SC_(950.2220458984375), SC_(6.856169404714020378408540666432044534508),
|
||||
SC_(954.943359375), SC_(6.861128346520892642201796166599822038471),
|
||||
SC_(955.017578125), SC_(6.861206104783820446126170121986330983269),
|
||||
SC_(956.13458251953125), SC_(6.862375649747642715205235987065776445518),
|
||||
SC_(957.1669921875), SC_(6.863455405877975518619709756325785766734),
|
||||
SC_(957.5068359375), SC_(6.863810580012297609207700982417845904956),
|
||||
SC_(959.2913818359375), SC_(6.865673559355261880433729035303716037083),
|
||||
SC_(959.492431640625), SC_(6.865883228230126473126797544809231414745),
|
||||
SC_(959.74395751953125), SC_(6.866145475218019847811591867037562659094),
|
||||
SC_(961.8980712890625), SC_(6.868388594389408661650623078145486428762),
|
||||
SC_(964.88848876953125), SC_(6.871494254878780851989128297020995382715),
|
||||
SC_(964.96636962890625), SC_(6.871575008339416373031500751728687321642),
|
||||
SC_(967.6949462890625), SC_(6.874400118733980051857714900416741852838),
|
||||
SC_(968.640380859375), SC_(6.87537714276502884037846310503316214533),
|
||||
SC_(968.8677978515625), SC_(6.875612016002868563135875018985921894413),
|
||||
SC_(970.5927734375), SC_(6.877391753918391265533592997745089246348),
|
||||
SC_(977.00201416015625), SC_(6.883976856642686182085022703036491098977),
|
||||
SC_(979.74835205078125), SC_(6.886785333127100045440434410093146016624),
|
||||
SC_(979.9256591796875), SC_(6.886966381237166628662813047575594521666),
|
||||
SC_(981.10968017578125), SC_(6.888174544185669495233192817179284924608),
|
||||
SC_(981.72314453125), SC_(6.888799943368115034020659880636949694688),
|
||||
SC_(982.36053466796875), SC_(6.8894493197658087146525978621453836978),
|
||||
SC_(987.4595947265625), SC_(6.894629143910089536380903205901047293626),
|
||||
SC_(988.37939453125), SC_(6.895560662679555267312975090816879245672),
|
||||
SC_(988.5216064453125), SC_(6.895704609063605825635576817887832481836),
|
||||
SC_(990.1099853515625), SC_(6.897310953864133148550105914216515716675),
|
||||
SC_(992.88128662109375), SC_(6.900107437258989936275310085429403733899),
|
||||
SC_(993.53472900390625), SC_(6.900765679507473199060169339559463847836),
|
||||
SC_(994.0684814453125), SC_(6.901303031311155785795352189437299613696),
|
||||
SC_(996.13470458984375), SC_(6.903380469883631241011306751657568074638),
|
||||
SC_(996.4613037109375), SC_(6.903708447139272864766001846716835845992),
|
||||
};
|
||||
#undef SC_
|
||||
|
||||
206
test/digamma_neg_data.ipp
Normal file
206
test/digamma_neg_data.ipp
Normal file
@@ -0,0 +1,206 @@
|
||||
#define SC_(x) static_cast<T>(BOOST_JOIN(x, L))
|
||||
static const boost::array<boost::array<T, 2>, 200> digamma_neg_data = {
|
||||
SC_(-99.7181549072265625), SC_(2.03892909952497242038694056382195623059),
|
||||
SC_(-99.5216522216796875), SC_(4.3913617771941913117971009646096341326),
|
||||
SC_(-98.80979156494140625), SC_(-0.01795976054399933340057713377738267488686),
|
||||
SC_(-98.646087646484375), SC_(3.044214979883807667874683391024711390163),
|
||||
SC_(-98.2226104736328125), SC_(8.327061837969621994688065941368639650164),
|
||||
SC_(-96.81671905517578125), SC_(-0.2613967795671165924570265553692310141858),
|
||||
SC_(-96.555389404296875), SC_(4.023029392905834803729410679283679163172),
|
||||
SC_(-96.4288330078125), SC_(5.288313818176304987255615817663265383342),
|
||||
SC_(-96.35587310791015625), SC_(6.101607804168127653000043332720050192048),
|
||||
SC_(-95.3828582763671875), SC_(5.774458772879798661504785984613127024683),
|
||||
SC_(-94.87835693359375), SC_(-3.258775525008949657912384482006797161857),
|
||||
SC_(-94.60498809814453125), SC_(3.479509682356698077739870471765368709254),
|
||||
SC_(-93.2404632568359375), SC_(7.876249181059212250961342610258680843403),
|
||||
SC_(-92.41457366943359375), SC_(5.395652110469876120841383508575006667739),
|
||||
SC_(-90.2868194580078125), SC_(6.996060449908181672759658412431764721268),
|
||||
SC_(-90.2459564208984375), SC_(7.730510069525265980585453066651639424664),
|
||||
SC_(-89.013824462890625), SC_(76.7844527353150160809893161375899712728),
|
||||
SC_(-88.75354766845703125), SC_(1.279073328662160048752885420029490083884),
|
||||
SC_(-88.1002349853515625), SC_(14.12873575145206447240140060245136812233),
|
||||
SC_(-87.481719970703125), SC_(4.657749706875254767656016829355880725463),
|
||||
SC_(-87.41033935546875), SC_(5.385408972387998240975025273868320766616),
|
||||
SC_(-87.3013153076171875), SC_(6.737807742019520253440825060046509923858),
|
||||
SC_(-87.00937652587890625), SC_(111.0902104512757743601088229496385482381),
|
||||
SC_(-86.452301025390625), SC_(4.939690918031593302255270591348782158549),
|
||||
SC_(-86.1375579833984375), SC_(11.27311653802311845949475246171079728424),
|
||||
SC_(-85.81136322021484375), SC_(-0.2076024359899236820459284405564934682571),
|
||||
SC_(-85.08860015869140625), SC_(15.4432197184156901762673734012738165669),
|
||||
SC_(-85.0706024169921875), SC_(18.38013049788840734996810404641615698096),
|
||||
SC_(-84.55615997314453125), SC_(3.88321705564237834505242432670033691134),
|
||||
SC_(-84.2386932373046875), SC_(7.812678135978754145263274987740845778654),
|
||||
SC_(-84.194244384765625), SC_(8.931719867523162463837746400725488234199),
|
||||
SC_(-83.73882293701171875), SC_(1.505295935399338449868426369185929751229),
|
||||
SC_(-82.8813323974609375), SC_(-3.609402776980612588036128298328365683225),
|
||||
SC_(-82.6134796142578125), SC_(3.250221400281531800616333769504919375611),
|
||||
SC_(-81.31273651123046875), SC_(6.500209496762236219781012282892172792378),
|
||||
SC_(-81.16180419921875), SC_(10.04118609757139096209050165941519368701),
|
||||
SC_(-80.34047698974609375), SC_(6.113463877628090613614429157059502101004),
|
||||
SC_(-79.1931915283203125), SC_(8.902649813785723219406837941195708301933),
|
||||
SC_(-78.979095458984375), SC_(-43.39220275151493342151673584769713674459),
|
||||
SC_(-78.80756378173828125), SC_(-0.1741139524199893908631289936754328553595),
|
||||
SC_(-78.276214599609375), SC_(7.029126641974004636072711755974329319293),
|
||||
SC_(-77.8965911865234375), SC_(-4.965949067939776233732103672063117487233),
|
||||
SC_(-77.618804931640625), SC_(3.128016725588726483845498994960937165101),
|
||||
SC_(-76.9843902587890625), SC_(-59.66111542957708160367279993835116598861),
|
||||
SC_(-75.6475067138671875), SC_(2.762831843674791808646068344156198358292),
|
||||
SC_(-74.8916168212890625), SC_(-4.544467476010996269925717795920967036228),
|
||||
SC_(-74.57178497314453125), SC_(3.59770242115359475843120457380803078855),
|
||||
SC_(-74.49048614501953125), SC_(4.411294618813885078478516140128263239646),
|
||||
SC_(-74.249176025390625), SC_(7.472045154786435852081961669032387751756),
|
||||
SC_(-72.397491455078125), SC_(5.337270392731504876256252154330660996853),
|
||||
SC_(-72.30770111083984375), SC_(6.45618615562028783175344592523791857763),
|
||||
SC_(-72.150177001953125), SC_(10.44291983579332484719137950538141198138),
|
||||
SC_(-71.41609954833984375), SC_(5.123297394484169650507849264219211277233),
|
||||
SC_(-70.29705810546875), SC_(6.586989653308987758464004111780026164342),
|
||||
SC_(-70.0168304443359375), SC_(63.61661733083149880967450730403400964169),
|
||||
SC_(-69.808685302734375), SC_(-0.3289873714853887848889508326638941457588),
|
||||
SC_(-69.18329620361328125), SC_(9.082833286105283040745693219253094753599),
|
||||
SC_(-68.3449554443359375), SC_(5.895816498784197711310887233679346985484),
|
||||
SC_(-68.2900543212890625), SC_(6.667078439728477642775937857513723712022),
|
||||
SC_(-66.7551727294921875), SC_(0.9631089274457797371832913555201378277263),
|
||||
SC_(-66.2877349853515625), SC_(6.674402390903648107264524741943941318692),
|
||||
SC_(-65.96142578125), SC_(-21.60039097244717646250068532377671067773),
|
||||
SC_(-65.00162506103515625), SC_(619.5382407651047414044960295217348989637),
|
||||
SC_(-64.83405303955078125), SC_(-1.290399564904368875515657543138626740639),
|
||||
SC_(-64.72376251220703125), SC_(1.515712957371258935902920146011383158566),
|
||||
SC_(-64.36548614501953125), SC_(5.585036804770642096748234463405359373268),
|
||||
SC_(-63.870601654052734375), SC_(-3.132938413135016068514633000959251655011),
|
||||
SC_(-61.955417633056640625), SC_(-18.14906679867205714676685355624200206247),
|
||||
SC_(-61.84415435791015625), SC_(-1.762828050189299963414925510084105410157),
|
||||
SC_(-61.27040863037109375), SC_(6.885962246437210164247050669769241762116),
|
||||
SC_(-61.1430206298828125), SC_(10.63639337906714605332887925207272339472),
|
||||
SC_(-60.7772979736328125), SC_(0.3828568174285943765552196371752184023788),
|
||||
SC_(-60.767955780029296875), SC_(0.597630996899231770205669545427601282449),
|
||||
SC_(-60.50917816162109375), SC_(4.020425571512186535251807369058720729888),
|
||||
SC_(-60.126148223876953125), SC_(11.61249771821316227897371950731036451444),
|
||||
SC_(-59.5791473388671875), SC_(3.298014524278177804824357796228486139154),
|
||||
SC_(-59.12688446044921875), SC_(11.54738093463764209365528407465938463008),
|
||||
SC_(-58.733348846435546875), SC_(1.252516603233681404470535780337376850768),
|
||||
SC_(-57.823871612548828125), SC_(-1.020030805813282973065541328061417103161),
|
||||
SC_(-57.791233062744140625), SC_(-0.01721196139850082730515140522511875898686),
|
||||
SC_(-57.6834869384765625), SC_(2.021283718214246528807976825874750730944),
|
||||
SC_(-56.1255645751953125), SC_(11.58306242149007962260737588966574096145),
|
||||
SC_(-55.441379547119140625), SC_(4.6095090326877333856682583039277727222),
|
||||
SC_(-54.396717071533203125), SC_(5.062176320861478792112156635998489324447),
|
||||
SC_(-54.201084136962890625), SC_(8.295102791777500360299701370233860660785),
|
||||
SC_(-53.06093597412109375), SC_(20.19053903029668873838826742013474757079),
|
||||
SC_(-52.671115875244140625), SC_(2.10070123867348232297487204513445237558),
|
||||
SC_(-52.52413177490234375), SC_(3.73213352669881119442059765740051858078),
|
||||
SC_(-51.462436676025390625), SC_(4.323002262954298089562762598650242024201),
|
||||
SC_(-51.243106842041015625), SC_(7.226998934762993806818100988804419542686),
|
||||
SC_(-51.0235595703125), SC_(46.31011451882384360024092555028601375848),
|
||||
SC_(-50.94109344482421875), SC_(-12.8413475810657768775226051735008739843),
|
||||
SC_(-50.163593292236328125), SC_(9.490021355163248564818621481640556958139),
|
||||
SC_(-49.63372802734375), SC_(2.511313156813305996562305257857390789172),
|
||||
SC_(-49.404293060302734375), SC_(4.884246649262366888920411419024147958277),
|
||||
SC_(-47.262851715087890625), SC_(6.763893885944739117755918311467424143999),
|
||||
SC_(-46.920246124267578125), SC_(-8.416023355487745311972990967262253971971),
|
||||
SC_(-45.31185150146484375), SC_(5.932978383248106730387626359282358526882),
|
||||
SC_(-45.278446197509765625), SC_(6.448720313065481170040935613035156187478),
|
||||
SC_(-45.277942657470703125), SC_(6.457159638091017467737698925977740795224),
|
||||
SC_(-45.027637481689453125), SC_(39.91011698129930359222267887372752760268),
|
||||
SC_(-43.8442535400390625), SC_(-2.107933118887280485309161602735949216416),
|
||||
SC_(-43.217838287353515625), SC_(7.628256500265451720152832482834432955622),
|
||||
SC_(-43.11763763427734375), SC_(11.88558178274471415613706962118145261485),
|
||||
SC_(-42.62453460693359375), SC_(2.468202270232387819257535057032048703186),
|
||||
SC_(-41.904331207275390625), SC_(-6.388806142931646581376930809159704270731),
|
||||
SC_(-41.473590850830078125), SC_(3.998311840817845119612809226760453214553),
|
||||
SC_(-41.47322845458984375), SC_(4.001904991009103072678533254287758877523),
|
||||
SC_(-40.71761322021484375), SC_(1.159373041348507101344016731863232548419),
|
||||
SC_(-40.549640655517578125), SC_(3.220862320117017004190871786172571326259),
|
||||
SC_(-38.39553070068359375), SC_(4.73066601123284545617603996389975515062),
|
||||
SC_(-36.764072418212890625), SC_(0.185641778964637473051349775352193113594),
|
||||
SC_(-36.0236663818359375), SC_(45.77413334958292444754118070178767678465),
|
||||
SC_(-35.60390472412109375), SC_(2.522888342129267961559021180379112152327),
|
||||
SC_(-35.3686981201171875), SC_(4.954668236416411879662604875880175363163),
|
||||
SC_(-34.49019622802734375), SC_(3.651891900429621653936520779034983699363),
|
||||
SC_(-34.452213287353515625), SC_(4.029227315027716909301715786442880409125),
|
||||
SC_(-34.425933837890625), SC_(4.297752459205291355542460490934969321341),
|
||||
SC_(-33.6394500732421875), SC_(2.05879207452756962707410762095930722907),
|
||||
SC_(-32.12648773193359375), SC_(10.97049318285659411778704721045579811462),
|
||||
SC_(-32.02973175048828125), SC_(37.01840088144976405978561031600232101035),
|
||||
SC_(-32.018024444580078125), SC_(58.90273484616011864735901401561254400453),
|
||||
SC_(-31.864048004150390625), SC_(-3.425649819825478548122204473279221831269),
|
||||
SC_(-30.5171375274658203125), SC_(3.265278944239551980140922031510366995665),
|
||||
SC_(-30.4767131805419921875), SC_(3.663521748406629288062646856398131484428),
|
||||
SC_(-30.0923290252685546875), SC_(13.94615623704883065583726298948748620016),
|
||||
SC_(-29.4225749969482421875), SC_(4.178249593518503446782790798157935603259),
|
||||
SC_(-29.395389556884765625), SC_(4.46906479672600980848725781028158753644),
|
||||
SC_(-29.0635166168212890625), SC_(18.92098221867999526957587349227217750794),
|
||||
SC_(-28.929615020751953125), SC_(-10.59321162183541691346972253310776238772),
|
||||
SC_(-27.416103363037109375), SC_(4.17700594969969944426868830026842791532),
|
||||
SC_(-27.304531097412109375), SC_(5.54012214812515808522852628894283103891),
|
||||
SC_(-26.72013092041015625), SC_(0.7028843790088342764015208907756718567463),
|
||||
SC_(-25.9352741241455078125), SC_(-11.9614838597048426449728575053473182996),
|
||||
SC_(-25.6867523193359375), SC_(1.176826484915453835886205411786243733377),
|
||||
SC_(-24.8732929229736328125), SC_(-4.237136620209855403786484087613189060887),
|
||||
SC_(-24.6270904541015625), SC_(1.898484134239669451822687252748496404653),
|
||||
SC_(-24.53133392333984375), SC_(2.909938662308256016840011167255882888239),
|
||||
SC_(-24.27997589111328125), SC_(5.809456022692943160671997012588234680914),
|
||||
SC_(-24.225986480712890625), SC_(6.863255301509444395634121067991546441736),
|
||||
SC_(-23.8268795013427734375), SC_(-2.003570170516321537241642099057200674105),
|
||||
SC_(-23.6249980926513671875), SC_(1.882051906931976769141489221324624486755),
|
||||
SC_(-23.4483184814453125), SC_(3.690576780901990543590973501647480396476),
|
||||
SC_(-22.6082859039306640625), SC_(2.02829972990549794339388303789633983053),
|
||||
SC_(-22.1102294921875), SC_(11.82489297106174961055859856595077767589),
|
||||
SC_(-22.0832767486572265625), SC_(14.85021720005861723216276067526099288351),
|
||||
SC_(-20.779270172119140625), SC_(-0.7220286362185610999510531120120858367544),
|
||||
SC_(-20.6402416229248046875), SC_(1.570036502538595917265616936047416332984),
|
||||
SC_(-20.60250091552734375), SC_(2.001360446832507792499854867762750216251),
|
||||
SC_(-20.480007171630859375), SC_(3.241245764823419396963096620359809656269),
|
||||
SC_(-20.27201080322265625), SC_(5.768313318300353594949489118483966781535),
|
||||
SC_(-20.2071361541748046875), SC_(7.156819372589727235791276774661186960423),
|
||||
SC_(-20.1894168853759765625), SC_(7.670698039778866912498508209079922928436),
|
||||
SC_(-19.971954345703125), SC_(-32.54467844963252077717911577731405834236),
|
||||
SC_(-19.2469005584716796875), SC_(6.186480084023335387087272289090747328989),
|
||||
SC_(-19.1824493408203125), SC_(7.847002126080603757397510906504995585177),
|
||||
SC_(-19.0265483856201171875), SC_(40.55157678949956103482720787629324186475),
|
||||
SC_(-18.5715198516845703125), SC_(2.230314699128516174606595799951710607353),
|
||||
SC_(-18.5276336669921875), SC_(2.672586759609702793340088983364248246452),
|
||||
SC_(-17.9159221649169921875), SC_(-8.702502484177860216144583065634001249363),
|
||||
SC_(-17.8754024505615234375), SC_(-4.700545068020732462956282791568579773556),
|
||||
SC_(-17.8096714019775390625), SC_(-1.704910040367315348529245955199242558161),
|
||||
SC_(-17.654216766357421875), SC_(1.245525979337004465966586338242325823861),
|
||||
SC_(-16.9171390533447265625), SC_(-8.936978387990812220163335657856867859665),
|
||||
SC_(-16.4991436004638671875), SC_(2.841759414051282631909664692084257003501),
|
||||
SC_(-15.9282741546630859375), SC_(-10.90604642089629536174323573315025319791),
|
||||
SC_(-15.1532230377197265625), SC_(8.7652341843566231062515337784346464505),
|
||||
SC_(-15.0870685577392578125), SC_(13.94393218121241823357181745576517766981),
|
||||
SC_(-12.7571163177490234375), SC_(-0.7005285484888729861556721133426365160483),
|
||||
SC_(-12.32425594329833984375), SC_(4.486877647992933354241229013873681135288),
|
||||
SC_(-12.15693378448486328125), SC_(8.38572290746722802141392801697704201607),
|
||||
SC_(-10.90967655181884765625), SC_(-8.337781110433724243601733849861559188948),
|
||||
SC_(-9.42080593109130859375), SC_(3.093207549574642835823398326728433769791),
|
||||
SC_(-9.26352691650390625), SC_(5.164408378967561819557747661923746174341),
|
||||
SC_(-8.66241455078125), SC_(0.4573363030846697184753722937434504783991),
|
||||
SC_(-8.42644596099853515625), SC_(2.928692490941547323611393715468003596111),
|
||||
SC_(-8.28063488006591796875), SC_(4.761502420123261711232867499795716416469),
|
||||
SC_(-7.91252231597900390625), SC_(-9.011928670506620642435146780806294048492),
|
||||
SC_(-7.073635101318359375), SC_(15.36275862317279916670563199810883722471),
|
||||
SC_(-6.600677967071533203125), SC_(0.9328456790163266794082601288835098544981),
|
||||
SC_(-6.59893131256103515625), SC_(0.9516512759861559819594253210068193102636),
|
||||
SC_(-5.9925975799560546875), SC_(-133.1949549912806814878528595454864731658),
|
||||
SC_(-4.9777927398681640625), SC_(-43.25515309581336581959034619574585012987),
|
||||
SC_(-4.4982433319091796875), SC_(1.628080704179537179987368246302687190569),
|
||||
SC_(-4.28330326080322265625), SC_(4.11144188155776750659420254650051070116),
|
||||
SC_(-4.24931621551513671875), SC_(4.714952991490022604296929488005221371491),
|
||||
SC_(-4.0708599090576171875), SC_(15.40013806764590763994801524236096523633),
|
||||
SC_(-4.05075550079345703125), SC_(21.05232398567253746583677948874966443745),
|
||||
SC_(-4.0256023406982421875), SC_(40.48643215403911174179393965158605983731),
|
||||
SC_(-3.5111486911773681640625), SC_(1.281561880048097406180157051598176902444),
|
||||
SC_(-3.5033643245697021484375), SC_(1.356501581084328750160720447675663936527),
|
||||
SC_(-3.2305061817169189453125), SC_(4.871536212360443209892217244039906620205),
|
||||
SC_(-3.1132221221923828125), SC_(9.744280495465310545518498968361342433867),
|
||||
SC_(-2.9407203197479248046875), SC_(-15.4345615314581643435197891745342605011),
|
||||
SC_(-1.8890321254730224609375), SC_(-7.765572445501014244464453609042267110197),
|
||||
SC_(-1.2540400028228759765625), SC_(3.637637081727820317005755368640064000683),
|
||||
SC_(-1.1478424072265625), SC_(6.784401313345897445876900487443690652634),
|
||||
SC_(-0.7118701934814453125), SC_(-2.248647256037530489173954985789306442878),
|
||||
SC_(-0.593149662017822265625), SC_(-0.8263747473361177168793211424797478169291),
|
||||
SC_(-0.3538668155670166015625), SC_(1.443172070386911802413212733069332368731),
|
||||
};
|
||||
#undef SC_
|
||||
|
||||
|
||||
206
test/digamma_root_data.ipp
Normal file
206
test/digamma_root_data.ipp
Normal file
@@ -0,0 +1,206 @@
|
||||
#define SC_(x) static_cast<T>(BOOST_JOIN(x, L))
|
||||
static const boost::array<boost::array<T, 2>, 200> digamma_root_data = {
|
||||
SC_(1.39999997615814208984375), SC_(-0.06138456903152256550686860248931989075643),
|
||||
SC_(1.4005000591278076171875), SC_(-0.06087192929516339380130503872301167293378),
|
||||
SC_(1.40100002288818359375), SC_(-0.06035965880979232302674791723368356347747),
|
||||
SC_(1.4014999866485595703125), SC_(-0.05984763511635311349827564040488766194063),
|
||||
SC_(1.401999950408935546875), SC_(-0.0593358579881174546738279942752396761834),
|
||||
SC_(1.40250003337860107421875), SC_(-0.05882420526073090100751004662830533539728),
|
||||
SC_(1.40299999713897705078125), SC_(-0.0583129206425757749570876729240439746001),
|
||||
SC_(1.40349996089935302734375), SC_(-0.05780188191118900126815738602890619172921),
|
||||
SC_(1.4040000438690185546875), SC_(-0.05729096707893393080771549505001408983822),
|
||||
SC_(1.40450000762939453125), SC_(-0.056780419503293858705549580743156540668),
|
||||
SC_(1.4049999713897705078125), SC_(-0.05627011713868186213939939894956276866569),
|
||||
SC_(1.40550005435943603515625), SC_(-0.05575993817369138452985739956960740694737),
|
||||
SC_(1.40600001811981201171875), SC_(-0.05525012561586888099905375034247029300063),
|
||||
SC_(1.40649998188018798828125), SC_(-0.05474055759601525571890189603476879643263),
|
||||
SC_(1.40699994564056396484375), SC_(-0.05423123389038862937136671914178719811082),
|
||||
SC_(1.4075000286102294921875), SC_(-0.05372203292179596750107248206039107172611),
|
||||
SC_(1.40799999237060546875), SC_(-0.05321319723270065414202667836306539722927),
|
||||
SC_(1.4084999561309814453125), SC_(-0.05270460518832646256646398238653334023619),
|
||||
SC_(1.40900003910064697265625), SC_(-0.05219613538658003557049855371629116390416),
|
||||
SC_(1.40950000286102294921875), SC_(-0.05168803002221822433984269085445887545932),
|
||||
SC_(1.40999996662139892578125), SC_(-0.05118016763572077571206202324130731620467),
|
||||
SC_(1.410500049591064453125), SC_(-0.05067242699961275111564488922723020894775),
|
||||
SC_(1.4110000133514404296875), SC_(-0.05016504996189404179318756205383368841508),
|
||||
SC_(1.41149997711181640625), SC_(-0.04965791523781849836663795623050040651275),
|
||||
SC_(1.41200006008148193359375), SC_(-0.04915090177405025431768617393574718923719),
|
||||
SC_(1.41250002384185791015625), SC_(-0.04864425107277807126795345488864174180773),
|
||||
SC_(1.41299998760223388671875), SC_(-0.04813784202354994896630230505781776120276),
|
||||
SC_(1.41349995136260986328125), SC_(-0.04763167440643069181645608937840354367671),
|
||||
SC_(1.414000034332275390625), SC_(-0.04712562739952290889837033293650476187953),
|
||||
SC_(1.4144999980926513671875), SC_(-0.04661994204540782942709091596942293402734),
|
||||
SC_(1.41499996185302734375), SC_(-0.04611449746527775349715574804732130222007),
|
||||
SC_(1.41550004482269287109375), SC_(-0.04560917301026328003252147788241984436241),
|
||||
SC_(1.41600000858306884765625), SC_(-0.0451042093793269736581833678634701785191),
|
||||
SC_(1.41649997234344482421875), SC_(-0.04459948586684279443839061743784846261709),
|
||||
SC_(1.4170000553131103515625), SC_(-0.04409488199649628730133723954943974407746),
|
||||
SC_(1.417500019073486328125), SC_(-0.0435906381245648444628637002942433530947),
|
||||
SC_(1.4179999828338623046875), SC_(-0.04308663371813044418132048918710682813622),
|
||||
SC_(1.41849994659423828125), SC_(-0.04258286856012920630307449298163993137931),
|
||||
SC_(1.41900002956390380859375), SC_(-0.0420792224035827733504570446125334946695),
|
||||
SC_(1.41949999332427978515625), SC_(-0.04157593514930978152490152156879729835277),
|
||||
SC_(1.41999995708465576171875), SC_(-0.04107288649393147397031813049746661830252),
|
||||
SC_(1.4205000400543212890625), SC_(-0.04056995636192793782845393152872471220703),
|
||||
SC_(1.421000003814697265625), SC_(-0.04006738431359655642636465412836862063583),
|
||||
SC_(1.4214999675750732421875), SC_(-0.03956505021716870619391607561977829898393),
|
||||
SC_(1.42200005054473876953125), SC_(-0.0390628341681160707895772877982347062534),
|
||||
SC_(1.42250001430511474609375), SC_(-0.03856097538713614221174291451172868720556),
|
||||
SC_(1.42299997806549072265625), SC_(-0.03805935391360299407483745199209552218662),
|
||||
SC_(1.42349994182586669921875), SC_(-0.03755796953327570443031191372677272436563),
|
||||
SC_(1.4240000247955322265625), SC_(-0.03705670256888721277125707475995514593767),
|
||||
SC_(1.424499988555908203125), SC_(-0.03655579178977111826937882476062071563405),
|
||||
SC_(1.4249999523162841796875), SC_(-0.0360551174627633043738925866730974379965),
|
||||
SC_(1.42550003528594970703125), SC_(-0.03555456008050613945891518063349475611711),
|
||||
SC_(1.42599999904632568359375), SC_(-0.03505435807486918460538076814912383388358),
|
||||
SC_(1.42649996280670166015625), SC_(-0.03455439188274749223938775275471736825604),
|
||||
SC_(1.4270000457763671875), SC_(-0.03405454216623210245980763665400513878778),
|
||||
SC_(1.4275000095367431640625), SC_(-0.03355504702063797243050550756083487574355),
|
||||
SC_(1.427999973297119140625), SC_(-0.03305578705245798813618865616700236433431),
|
||||
SC_(1.42850005626678466796875), SC_(-0.03255664309277291143229018160781330281834),
|
||||
SC_(1.42900002002716064453125), SC_(-0.03205785290124899051424545775403784997954),
|
||||
SC_(1.42949998378753662109375), SC_(-0.03155929725351741957783226833498005852699),
|
||||
SC_(1.42999994754791259765625), SC_(-0.03106097593893646101388889322754816060391),
|
||||
SC_(1.430500030517578125), SC_(-0.03056277001319123536849588910788667969385),
|
||||
SC_(1.4309999942779541015625), SC_(-0.03006491678982831278985395858099735606325),
|
||||
SC_(1.431499958038330078125), SC_(-0.02956729726928046744375226173805018083445),
|
||||
SC_(1.43200004100799560546875), SC_(-0.029069792675158646894282928074400495447),
|
||||
SC_(1.43250000476837158203125), SC_(-0.02857263998746077965589217391685781750225),
|
||||
SC_(1.43299996852874755859375), SC_(-0.02807572037469272194244519088403794652932),
|
||||
SC_(1.4335000514984130859375), SC_(-0.02757891522793825630459486913227966938778),
|
||||
SC_(1.4340000152587890625), SC_(-0.02708246119454089526602248424490897334451),
|
||||
SC_(1.4344999790191650390625), SC_(-0.02658623961062601916105249666629939819311),
|
||||
SC_(1.434999942779541015625), SC_(-0.02609025026826734736532129982459892559412),
|
||||
SC_(1.43550002574920654296875), SC_(-0.02559437478113976107312669529902398957573),
|
||||
SC_(1.43599998950958251953125), SC_(-0.0250988493544413555894730759899566827115),
|
||||
SC_(1.43649995326995849609375), SC_(-0.02460355554708331611314729590329885967853),
|
||||
SC_(1.4370000362396240234375), SC_(-0.02410837513916324870453956495027706651788),
|
||||
SC_(1.4375), SC_(-0.02361354400529789914172989421521805262163),
|
||||
SC_(1.4379999637603759765625), SC_(-0.02311894387096655710370815673046310749581),
|
||||
SC_(1.43850004673004150390625), SC_(-0.02262445668224241951726505286548155427726),
|
||||
SC_(1.43900001049041748046875), SC_(-0.02213031798404363285679840262837603735113),
|
||||
SC_(1.43949997425079345703125), SC_(-0.02163640966796990067907296550632756430219),
|
||||
SC_(1.440000057220458984375), SC_(-0.02114261384562461502572001614025897932072),
|
||||
SC_(1.4405000209808349609375), SC_(-0.02064916573310666785738104392419687958556),
|
||||
SC_(1.4409999847412109375), SC_(-0.02015594738769022700601666231128218163721),
|
||||
SC_(1.4414999485015869140625), SC_(-0.0196629586049117094653247721121789058042),
|
||||
SC_(1.44200003147125244140625), SC_(-0.0191700817163872207492164657910951176529),
|
||||
SC_(1.44249999523162841796875), SC_(-0.01867755150116066387436310533382643774849),
|
||||
SC_(1.44299995899200439453125), SC_(-0.01818525023671041840942493794786294366844),
|
||||
SC_(1.443500041961669921875), SC_(-0.01769306041915025068329883160626130368828),
|
||||
SC_(1.4440000057220458984375), SC_(-0.01720121650074344257459977191565623298452),
|
||||
SC_(1.444499969482421875), SC_(-0.01670960092360902193107619746814218063958),
|
||||
SC_(1.44500005245208740234375), SC_(-0.01621809634791875134279906903350577844016),
|
||||
SC_(1.44550001621246337890625), SC_(-0.015726936900023407129612092249722223488),
|
||||
SC_(1.44599997997283935546875), SC_(-0.01523600518624245606690212546401818985812),
|
||||
SC_(1.44649994373321533203125), SC_(-0.01474530100472522827513829838650753549117),
|
||||
SC_(1.447000026702880859375), SC_(-0.01425470723370217219431406682491211640879),
|
||||
SC_(1.4474999904632568359375), SC_(-0.01376445756632729291905843124879046109968),
|
||||
SC_(1.4479999542236328125), SC_(-0.01327443482716782005100353254837490055862),
|
||||
SC_(1.44850003719329833984375), SC_(-0.01278452205749292497551903285885539659936),
|
||||
SC_(1.44900000095367431640625), SC_(-0.01229495262655675620536025426734759387572),
|
||||
SC_(1.44949996471405029296875), SC_(-0.01180560952210644817133945874679139627505),
|
||||
SC_(1.4500000476837158203125), SC_(-0.01131637594801586656260394588481713457627),
|
||||
SC_(1.450500011444091796875), SC_(-0.01082748495049637469227173996198819829549),
|
||||
SC_(1.4509999752044677734375), SC_(-0.01033881968004044725477451816247304271862),
|
||||
SC_(1.45150005817413330078125), SC_(-0.009850263502694288097376018889413894603933),
|
||||
SC_(1.45200002193450927734375), SC_(-0.009362049142480268951706194627385896301701),
|
||||
SC_(1.45249998569488525390625), SC_(-0.008874059912203315333901183590153038939381),
|
||||
SC_(1.45299994945526123046875), SC_(-0.008386295613345236665485880245372577446211),
|
||||
SC_(1.4535000324249267578125), SC_(-0.007898639827508066919974235979462981148542),
|
||||
SC_(1.453999996185302734375), SC_(-0.007411324850459837999980330364290265721957),
|
||||
SC_(1.4544999599456787109375), SC_(-0.006924234210747293687116178727328347532758),
|
||||
SC_(1.45500004291534423828125), SC_(-0.006437251651142443774260894146878774165176),
|
||||
SC_(1.45550000667572021484375), SC_(-0.005950609147203835378592212115736517701905),
|
||||
SC_(1.45599997043609619140625), SC_(-0.005464190388787066551639512688711491505847),
|
||||
SC_(1.45650005340576171875), SC_(-0.00497787927940728167871412685817772062165),
|
||||
SC_(1.4570000171661376953125), SC_(-0.004491907475256527500473978270689662215921),
|
||||
SC_(1.457499980926513671875), SC_(-0.004006158827071890461464755144012668001093),
|
||||
SC_(1.4579999446868896484375), SC_(-0.003520633138850239630378016887483403867021),
|
||||
SC_(1.45850002765655517578125), SC_(-0.003035214527765513668034604216830692388851),
|
||||
SC_(1.45899999141693115234375), SC_(-0.002550134225501944697075651923125347621858),
|
||||
SC_(1.45949995517730712890625), SC_(-0.002065276296639069833107196292495616468625),
|
||||
SC_(1.46000003814697265625), SC_(-0.001580525018104361453955140711216969645092),
|
||||
SC_(1.4605000019073486328125), SC_(-0.001096111304170043846745287256190494732511),
|
||||
SC_(1.460999965667724609375), SC_(-0.0006119193793063274064283424010699749479896),
|
||||
SC_(1.46150004863739013671875), SC_(-0.0001278336797728010038687456086772293940197),
|
||||
SC_(1.46200001239776611328125), SC_(0.0003559151967379670943728162750581078035161),
|
||||
SC_(1.46249997615814208984375), SC_(0.0008394428662870266119150633759096763287959),
|
||||
SC_(1.4630000591278076171875), SC_(0.001322864733702479649625580945291659569672),
|
||||
SC_(1.46350002288818359375), SC_(0.001805950517042218036842926190553563525984),
|
||||
SC_(1.4639999866485595703125), SC_(0.002288815673318872744259324682705288271519),
|
||||
SC_(1.464499950408935546875), SC_(0.002771460395327381562525270989780009242693),
|
||||
SC_(1.46500003337860107421875), SC_(0.003253999876667223767472091225924873652768),
|
||||
SC_(1.46549999713897705078125), SC_(0.003736204255104145549500401970100669234964),
|
||||
SC_(1.46599996089935302734375), SC_(0.004218188776241473723916466805139222942859),
|
||||
SC_(1.4665000438690185546875), SC_(0.004700068475739702789490158181882191908657),
|
||||
SC_(1.46700000762939453125), SC_(0.005181613805192456365413438059635728009745),
|
||||
SC_(1.4674999713897705078125), SC_(0.005662939852129155621931915752726712941002),
|
||||
SC_(1.46800005435943603515625), SC_(0.006144161494685809209920008019685283315534),
|
||||
SC_(1.46850001811981201171875), SC_(0.006625049497465130483020027415596322710511),
|
||||
SC_(1.46899998188018798828125), SC_(0.007105718790337639298786852855563148822142),
|
||||
SC_(1.46949994564056396484375), SC_(0.007586169563676627501200448950668213028167),
|
||||
SC_(1.4700000286102294921875), SC_(0.008066516486231662885434708649134127678999),
|
||||
SC_(1.47049999237060546875), SC_(0.008546530738674327360836097967927454942833),
|
||||
SC_(1.4709999561309814453125), SC_(0.00902632704131026480217858186061492831619),
|
||||
SC_(1.47150003910064697265625), SC_(0.009506019906325596650154195641432409630907),
|
||||
SC_(1.47200000286102294921875), SC_(0.009985380825502499855688695923101130679945),
|
||||
SC_(1.47249996662139892578125), SC_(0.01046452436244992624581900727741018711986),
|
||||
SC_(1.473000049591064453125), SC_(0.01094356487319982808059040901671966801919),
|
||||
SC_(1.4735000133514404296875), SC_(0.01142227415983642922640932055783984854239),
|
||||
SC_(1.47399997711181640625), SC_(0.01190076662968176394047411758437134448755),
|
||||
SC_(1.47450006008148193359375), SC_(0.01237915648302134259978832581154852202161),
|
||||
SC_(1.47500002384185791015625), SC_(0.01285721583143592736486164760948599640939),
|
||||
SC_(1.47549998760223388671875), SC_(0.01333505892636885712587736290231507253031),
|
||||
SC_(1.47599995136260986328125), SC_(0.01381268595510390028319865656189032981603),
|
||||
SC_(1.476500034332275390625), SC_(0.01429021091090032875378729920511744436802),
|
||||
SC_(1.4769999980926513671875), SC_(0.01476740631674500824066000704296476101248),
|
||||
SC_(1.47749996185302734375), SC_(0.01524438621687947040773770812918073015903),
|
||||
SC_(1.47800004482269287109375), SC_(0.01572126444976191365504766913460853166159),
|
||||
SC_(1.47850000858306884765625), SC_(0.01619781384600798034797161476617322052959),
|
||||
SC_(1.47899997234344482421875), SC_(0.01667414829492702066558118850104769852234),
|
||||
SC_(1.4795000553131103515625), SC_(0.01715038148057877526958196636506777091166),
|
||||
SC_(1.480000019073486328125), SC_(0.01762628654041217983419823745186174695842),
|
||||
SC_(1.4804999828338623046875), SC_(0.01810197720920750584264288401814595315433),
|
||||
SC_(1.48099994659423828125), SC_(0.01857745367191608501032749919254492077255),
|
||||
SC_(1.48150002956390380859375), SC_(0.01905282940736078826428345835701187921344),
|
||||
SC_(1.48199999332427978515625), SC_(0.01952787796086124235035667894483836618612),
|
||||
SC_(1.48249995708465576171875), SC_(0.02000271286178744470899885416201568506841),
|
||||
SC_(1.4830000400543212890625), SC_(0.02047744743549734724595413353304339596842),
|
||||
SC_(1.483500003814697265625), SC_(0.02095185553229931162465762694540459626532),
|
||||
SC_(1.4839999675750732421875), SC_(0.02142605052796892258114323238639681979697),
|
||||
SC_(1.48450005054473876953125), SC_(0.02190014559479680012423194248738781677386),
|
||||
SC_(1.48500001430511474609375), SC_(0.02237391488729442162211914583054893402186),
|
||||
SC_(1.48549997806549072265625), SC_(0.02284747162804102549936129615381098290523),
|
||||
SC_(1.48600006103515625), SC_(0.02332092883665599429697089795154616828867),
|
||||
SC_(1.4865000247955322265625), SC_(0.02379406097107123019383531656762472857036),
|
||||
SC_(1.486999988555908203125), SC_(0.02426698110106619670748667123423481731356),
|
||||
SC_(1.4874999523162841796875), SC_(0.02473968940861605188874507129358473978676),
|
||||
SC_(1.48800003528594970703125), SC_(0.02521229871039613408736493282176431879518),
|
||||
SC_(1.48849999904632568359375), SC_(0.02568458386767842754083514014266512257621),
|
||||
SC_(1.48899996280670166015625), SC_(0.02615665774712770972822278823384134472911),
|
||||
SC_(1.4895000457763671875), SC_(0.02662863301366652729705485156514156921969),
|
||||
SC_(1.4900000095367431640625), SC_(0.02710028483017233972822145485920594582439),
|
||||
SC_(1.490499973297119140625), SC_(0.02757172591142969944611182410222535997026),
|
||||
SC_(1.49100005626678466796875), SC_(0.02804306877099953245333159632753441304838),
|
||||
SC_(1.49150002002716064453125), SC_(0.02851408887259174195648360999928964786226),
|
||||
SC_(1.49199998378753662109375), SC_(0.02898489877950229580989209771050696266479),
|
||||
SC_(1.49249994754791259765625), SC_(0.02945549867145914132386877573515702816588),
|
||||
SC_(1.493000030517578125), SC_(0.02992600086081766434888226036243716094018),
|
||||
SC_(1.4934999942779541015625), SC_(0.03039618121119222213671842099543294002594),
|
||||
SC_(1.493999958038330078125), SC_(0.03086615208450468685425685392189632212515),
|
||||
SC_(1.49450004100799560546875), SC_(0.03133602564265587447963502512063650812183),
|
||||
SC_(1.49500000476837158203125), SC_(0.0318055780482999943002748605694401059607),
|
||||
SC_(1.49549996852874755859375), SC_(0.03227492151277847133068637874480248065187),
|
||||
SC_(1.4960000514984130859375), SC_(0.03274416804792387851799905190703885999517),
|
||||
SC_(1.4965000152587890625), SC_(0.03321309411466675105852178534017282410089),
|
||||
SC_(1.4969999790191650390625), SC_(0.0336818117741548556801742840271873983606),
|
||||
SC_(1.49750006198883056640625), SC_(0.03415043288853741106672780407819814754177),
|
||||
SC_(1.49800002574920654296875), SC_(0.03461873421626057425769027729390348592731),
|
||||
SC_(1.49849998950958251953125), SC_(0.03508682766866380229344336380060751609967),
|
||||
SC_(1.49899995326995849609375), SC_(0.03555471342260717737839815920297809359884),
|
||||
SC_(1.4995000362396240234375), SC_(0.03602250314126230243963242841830489771559),
|
||||
};
|
||||
#undef SC_
|
||||
|
||||
|
||||
39
test/digamma_small_data.ipp
Normal file
39
test/digamma_small_data.ipp
Normal file
@@ -0,0 +1,39 @@
|
||||
#define SC_(x) static_cast<T>(BOOST_JOIN(x, L))
|
||||
static const boost::array<boost::array<T, 2>, 33> digamma_small_data = {
|
||||
SC_(0.1690093176520690576580818742513656616211e-8), SC_(-591683355.0172646248558707395909205014789),
|
||||
SC_(0.2114990849122477811761200428009033203125e-8), SC_(-472815285.0570071002693788265718597340393),
|
||||
SC_(0.7099628440698779741069301962852478027344e-8), SC_(-140852442.1314070676912450420112690472767),
|
||||
SC_(0.136718796284185373224318027496337890625e-7), SC_(-73142832.95860873836229194739144163160831),
|
||||
SC_(0.1679341288252089725574478507041931152344e-7), SC_(-59547157.96538602413887273326920747232618),
|
||||
SC_(0.586768322818898013792932033538818359375e-7), SC_(-17042502.04007390142270552503694442817772),
|
||||
SC_(0.1140460881288163363933563232421875e-6), SC_(-8768385.503057815514505383587592316839882),
|
||||
SC_(0.1455586016163579188287258148193359375e-6), SC_(-6870085.813645861903628134604185829717845),
|
||||
SC_(0.38918477685001562349498271942138671875e-6), SC_(-2569474.152450422201931296992216788786447),
|
||||
SC_(0.623782625552848912775516510009765625e-6), SC_(-1603123.137920326054732670974252040029471),
|
||||
SC_(0.104669607026153244078159332275390625e-5), SC_(-955387.7506368215484908190151041836664367),
|
||||
SC_(0.2951089072666945867240428924560546875e-5), SC_(-338858.5294366592361422006155767583415332),
|
||||
SC_(0.4877083483734168112277984619140625e-5), SC_(-205041.1518328576044816818799248254570363),
|
||||
SC_(0.9066634447663091123104095458984375e-5), SC_(-110295.0867866920189113632829333848561728),
|
||||
SC_(0.2360353755648247897624969482421875e-4), SC_(-42367.10793974013680262660975431753380722),
|
||||
SC_(0.60817910707555711269378662109375e-4), SC_(-16443.10183188331524808941398664226054956),
|
||||
SC_(0.000119476739200763404369354248046875), SC_(-8370.407052088278326658500142471452559876),
|
||||
SC_(0.0002437086659483611583709716796875), SC_(-4103.836730163294582058528454940279573003),
|
||||
SC_(0.00047970912419259548187255859375), SC_(-2085.173007504666107151589993385624082421),
|
||||
SC_(0.000960788573138415813446044921875), SC_(-1041.387348674624002438653075235083900513),
|
||||
SC_(0.00113048148341476917266845703125), SC_(-885.1541983038739901476427277144444120955),
|
||||
SC_(0.0033707791008055210113525390625), SC_(-297.2390039349243537614805191705277299023),
|
||||
SC_(0.007697627879679203033447265625), SC_(-130.474775285766139271184373586979099581),
|
||||
SC_(0.0154774188995361328125), SC_(-65.1622965036480167454852163183367159499),
|
||||
SC_(0.0305807329714298248291015625), SC_(-33.22833448837103737169827250947288832931),
|
||||
SC_(0.0346831791102886199951171875), SC_(-29.35398677269140057359817914882516787732),
|
||||
SC_(0.09283597767353057861328125), SC_(-11.20575716299454988174075282116985360081),
|
||||
SC_(0.22476322948932647705078125), SC_(-4.707226986627979845318377740205580092891),
|
||||
SC_(0.4500701129436492919921875), SC_(-2.233123888225926352977853470362332872207),
|
||||
SC_(0.64851474761962890625), SC_(-1.375098345846253151137062991270963899568),
|
||||
SC_(1.14188635349273681640625), SC_(-0.3652988540135093192143191973421561168173),
|
||||
SC_(2.0095670223236083984375), SC_(0.4289360116443062870701048575669258219731),
|
||||
SC_(5.68704509735107421875), SC_(1.647702940606041030337068005600358865775),
|
||||
};
|
||||
#undef SC_
|
||||
|
||||
|
||||
160
test/test_digamma.cpp
Normal file
160
test/test_digamma.cpp
Normal file
@@ -0,0 +1,160 @@
|
||||
// (C) Copyright John Maddock 2006.
|
||||
// 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 <boost/math/concepts/real_concept.hpp>
|
||||
#include <boost/test/included/test_exec_monitor.hpp>
|
||||
#include <boost/test/floating_point_comparison.hpp>
|
||||
#include <boost/math/special_functions/digamma.hpp>
|
||||
#include <boost/array.hpp>
|
||||
#include <boost/lambda/lambda.hpp>
|
||||
#include <boost/lambda/bind.hpp>
|
||||
|
||||
#include "handle_test_result.hpp"
|
||||
|
||||
//
|
||||
// DESCRIPTION:
|
||||
// ~~~~~~~~~~~~
|
||||
//
|
||||
// This file tests the digamma function. There are two sets of tests, spot
|
||||
// tests which compare our results with selected values computed
|
||||
// using the online special function calculator at
|
||||
// functions.wolfram.com, while the bulk of the accuracy tests
|
||||
// use values generated with NTL::RR at 1000-bit precision
|
||||
// and our generic versions of these functions.
|
||||
//
|
||||
// Note that when this file is first run on a new platform many of
|
||||
// these tests will fail: the default accuracy is 1 epsilon which
|
||||
// is too tight for most platforms. In this situation you will
|
||||
// need to cast a human eye over the error rates reported and make
|
||||
// a judgement as to whether they are acceptable. Either way please
|
||||
// report the results to the Boost mailing list. Acceptable rates of
|
||||
// error are marked up below as a series of regular expressions that
|
||||
// identify the compiler/stdlib/platform/data-type/test-data/test-function
|
||||
// along with the maximum expected peek and RMS mean errors for that
|
||||
// test.
|
||||
//
|
||||
|
||||
void expected_results()
|
||||
{
|
||||
//
|
||||
// Define the max and mean errors expected for
|
||||
// various compilers and platforms.
|
||||
//
|
||||
add_expected_result(
|
||||
".*", // compiler
|
||||
".*", // stdlib
|
||||
".*", // platform
|
||||
".*", // test type(s)
|
||||
"Inverse Erf.*", // test data group
|
||||
"boost::math::erfc?_inv", 18, 4); // test function
|
||||
|
||||
//
|
||||
// Finish off by printing out the compiler/stdlib/platform names,
|
||||
// we do this to make it easier to mark up expected error rates.
|
||||
//
|
||||
std::cout << "Tests run with " << BOOST_COMPILER << ", "
|
||||
<< BOOST_STDLIB << ", " << BOOST_PLATFORM << std::endl;
|
||||
}
|
||||
|
||||
template <class T>
|
||||
void do_test_digamma(const T& data, const char* type_name, const char* test_name)
|
||||
{
|
||||
typedef typename T::value_type row_type;
|
||||
typedef typename row_type::value_type value_type;
|
||||
|
||||
typedef value_type (*pg)(value_type);
|
||||
pg funcp = boost::math::digamma;
|
||||
|
||||
boost::math::tools::test_result<value_type> result;
|
||||
|
||||
std::cout << "Testing " << test_name << " with type " << type_name
|
||||
<< "\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n";
|
||||
|
||||
//
|
||||
// test digamma against data:
|
||||
//
|
||||
result = boost::math::tools::test(
|
||||
data,
|
||||
boost::lambda::bind(funcp,
|
||||
boost::lambda::ret<value_type>(boost::lambda::_1[0])),
|
||||
boost::lambda::ret<value_type>(boost::lambda::_1[1]));
|
||||
handle_test_result(result, data[result.worst()], result.worst(), type_name, "boost::math::digamma", test_name);
|
||||
std::cout << std::endl;
|
||||
}
|
||||
|
||||
template <class T>
|
||||
void test_digamma(T, const char* name)
|
||||
{
|
||||
//
|
||||
// The actual test data is rather verbose, so it's in a separate file
|
||||
//
|
||||
// The contents are as follows, each row of data contains
|
||||
// three items, input value a, input value b and erf(a, b):
|
||||
//
|
||||
# include "digamma_data.ipp"
|
||||
|
||||
do_test_digamma(digamma_data, name, "Digamma Function: Large Values");
|
||||
|
||||
# include "digamma_root_data.ipp"
|
||||
|
||||
do_test_digamma(digamma_root_data, name, "Digamma Function: Near the Positive Root");
|
||||
|
||||
# include "digamma_small_data.ipp"
|
||||
|
||||
do_test_digamma(digamma_small_data, name, "Digamma Function: Near Zero");
|
||||
|
||||
# include "digamma_neg_data.ipp"
|
||||
|
||||
do_test_digamma(digamma_neg_data, name, "Digamma Function: Negative Values");
|
||||
|
||||
}
|
||||
|
||||
template <class T>
|
||||
void test_spots(T, const char* t)
|
||||
{
|
||||
std::cout << "Testing basic sanity checks for type " << t << std::endl;
|
||||
//
|
||||
// basic sanity checks, tolerance is 10 epsilon expressed as a percentage:
|
||||
//
|
||||
T tolerance = boost::math::tools::epsilon<T>() * 300;
|
||||
BOOST_CHECK_CLOSE(::boost::math::digamma(static_cast<T>(0.125)), static_cast<T>(-8.3884926632958548678027429230863430000514460424495L), tolerance);
|
||||
BOOST_CHECK_CLOSE(::boost::math::digamma(static_cast<T>(0.5)), static_cast<T>(-1.9635100260214234794409763329987555671931596046604L), tolerance);
|
||||
BOOST_CHECK_CLOSE(::boost::math::digamma(static_cast<T>(1)), static_cast<T>(-0.57721566490153286060651209008240243104215933593992L), tolerance);
|
||||
BOOST_CHECK_CLOSE(::boost::math::digamma(static_cast<T>(1.5)), static_cast<T>(0.036489973978576520559023667001244432806840395339566L), tolerance);
|
||||
BOOST_CHECK_CLOSE(::boost::math::digamma(static_cast<T>(1.5) - static_cast<T>(1)/32), static_cast<T>(0.00686541147073577672813890866512415766586241385896200579891429L), tolerance);
|
||||
BOOST_CHECK_CLOSE(::boost::math::digamma(static_cast<T>(2)), static_cast<T>(0.42278433509846713939348790991759756895784066406008L), tolerance);
|
||||
BOOST_CHECK_CLOSE(::boost::math::digamma(static_cast<T>(8)), static_cast<T>(2.0156414779556099965363450527747404261006978069172L), tolerance);
|
||||
BOOST_CHECK_CLOSE(::boost::math::digamma(static_cast<T>(12)), static_cast<T>(2.4426616799758120167383652547949424463027180089374L), tolerance);
|
||||
BOOST_CHECK_CLOSE(::boost::math::digamma(static_cast<T>(22)), static_cast<T>(3.0681430398611966699248760264450329818421699570581L), tolerance);
|
||||
BOOST_CHECK_CLOSE(::boost::math::digamma(static_cast<T>(50)), static_cast<T>(3.9019896734278921969539597028823666609284424880275L), tolerance);
|
||||
BOOST_CHECK_CLOSE(::boost::math::digamma(static_cast<T>(500)), static_cast<T>(6.2136077650889917423827750552855712637776544784569L), tolerance);
|
||||
}
|
||||
|
||||
int test_main(int, char* [])
|
||||
{
|
||||
test_spots(0.0F, "float");
|
||||
test_spots(0.0, "double");
|
||||
#ifndef BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS
|
||||
test_spots(0.0L, "long double");
|
||||
test_spots(boost::math::concepts::real_concept(0.1), "real_concept");
|
||||
#endif
|
||||
|
||||
expected_results();
|
||||
|
||||
test_digamma(0.1F, "float");
|
||||
test_digamma(0.1, "double");
|
||||
#ifndef BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS
|
||||
test_digamma(0.1L, "long double");
|
||||
test_digamma(boost::math::concepts::real_concept(0.1), "real_concept");
|
||||
#else
|
||||
std::cout << "<note>The long double tests have been disabled on this platform "
|
||||
"either because the long double overloads of the usual math functions are "
|
||||
"not available at all, or because they are too inaccurate for these tests "
|
||||
"to pass.</note>" << std::cout;
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
67
tools/digamma_data.cpp
Normal file
67
tools/digamma_data.cpp
Normal file
@@ -0,0 +1,67 @@
|
||||
// (C) Copyright John Maddock 2006.
|
||||
// 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 "ntl_rr_digamma.hpp"
|
||||
#include <boost/test/included/test_exec_monitor.hpp>
|
||||
#include <boost/math/tools/test.hpp>
|
||||
#include <fstream>
|
||||
|
||||
#include <boost/math/tools/test_data.hpp>
|
||||
|
||||
using namespace boost::math::tools;
|
||||
using namespace std;
|
||||
|
||||
float external_f;
|
||||
float force_truncate(const float* f)
|
||||
{
|
||||
external_f = *f;
|
||||
return external_f;
|
||||
}
|
||||
|
||||
float truncate_to_float(NTL::RR r)
|
||||
{
|
||||
float f = boost::math::tools::real_cast<float>(r);
|
||||
return force_truncate(&f);
|
||||
}
|
||||
|
||||
int test_main(int argc, char*argv [])
|
||||
{
|
||||
NTL::RR::SetPrecision(1000);
|
||||
NTL::RR::SetOutputPrecision(40);
|
||||
|
||||
parameter_info<NTL::RR> arg1;
|
||||
test_data<NTL::RR> data;
|
||||
|
||||
bool cont;
|
||||
std::string line;
|
||||
|
||||
std::cout << "Welcome.\n"
|
||||
"This program will generate spot tests for the digamma function:\n"
|
||||
" digamma(z)\n\n";
|
||||
|
||||
do{
|
||||
if(0 == get_user_parameter_info(arg1, "z"))
|
||||
return 1;
|
||||
data.insert(&boost::math::digamma, arg1);
|
||||
|
||||
std::cout << "Any more data [y/n]?";
|
||||
std::getline(std::cin, line);
|
||||
boost::algorithm::trim(line);
|
||||
cont = (line == "y");
|
||||
}while(cont);
|
||||
|
||||
std::cout << "Enter name of test data file [default=digamma_data.ipp]";
|
||||
std::getline(std::cin, line);
|
||||
boost::algorithm::trim(line);
|
||||
if(line == "")
|
||||
line = "digamma_data.ipp";
|
||||
std::ofstream ofs(line.c_str());
|
||||
write_code(ofs, data, "digamma_data");
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
#include <boost/math/special_functions/log1p.hpp>
|
||||
#include <boost/lexical_cast.hpp>
|
||||
#include <boost/array.hpp>
|
||||
#include <boost/test/included/test_exec_monitor.hpp>
|
||||
|
||||
//
|
||||
// this is a sort of recursive include, since this file
|
||||
@@ -4277,7 +4278,7 @@ void find_best_lanczos(const char* name, T eps, int max_scan = 100)
|
||||
|
||||
print_code(best, name);
|
||||
}
|
||||
int main(int argc, char*argv[])
|
||||
int test_main(int argc, char*argv [])
|
||||
{
|
||||
bool test_double(false), test_long(false), test_float(false), test_quad(false), spots(false), test_data(false);
|
||||
|
||||
@@ -4315,6 +4316,7 @@ int main(int argc, char*argv[])
|
||||
if(spots)
|
||||
{
|
||||
// these are optimal N and R from Pugh:
|
||||
calculate_lanczos_spot(61, 63.192152);
|
||||
calculate_lanczos_spot(31, 32.080670);
|
||||
calculate_lanczos_spot(6, 5.581);
|
||||
calculate_lanczos_spot(11, 10.900511);
|
||||
|
||||
293
tools/ntl_rr_digamma.hpp
Normal file
293
tools/ntl_rr_digamma.hpp
Normal file
@@ -0,0 +1,293 @@
|
||||
// (C) Copyright John Maddock 2006.
|
||||
// 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)
|
||||
|
||||
#ifndef BOOST_MATH_NTL_DIGAMMA
|
||||
#define BOOST_MATH_NTL_DIGAMMA
|
||||
|
||||
#include <boost/math/tools/ntl.hpp>
|
||||
#include <boost/math/tools/rational.hpp>
|
||||
#include <boost/math/tools/evaluation_type.hpp>
|
||||
#include <boost/math/tools/error_handling.hpp>
|
||||
#include <boost/math/constants/constants.hpp>
|
||||
|
||||
namespace boost{ namespace math{
|
||||
|
||||
NTL::RR digamma_imp(NTL::RR x)
|
||||
{
|
||||
static const NTL::RR P[61] = {
|
||||
boost::lexical_cast<NTL::RR>("0.6660133691143982067148122682345055274952e81"),
|
||||
boost::lexical_cast<NTL::RR>("0.6365271516829242456324234577164675383137e81"),
|
||||
boost::lexical_cast<NTL::RR>("0.2991038873096202943405966144203628966976e81"),
|
||||
boost::lexical_cast<NTL::RR>("0.9211116495503170498076013367421231351115e80"),
|
||||
boost::lexical_cast<NTL::RR>("0.2090792764676090716286400360584443891749e80"),
|
||||
boost::lexical_cast<NTL::RR>("0.3730037777359591428226035156377978092809e79"),
|
||||
boost::lexical_cast<NTL::RR>("0.5446396536956682043376492370432031543834e78"),
|
||||
boost::lexical_cast<NTL::RR>("0.6692523966335177847425047827449069256345e77"),
|
||||
boost::lexical_cast<NTL::RR>("0.7062543624100864681625612653756619116848e76"),
|
||||
boost::lexical_cast<NTL::RR>("0.6499914905966283735005256964443226879158e75"),
|
||||
boost::lexical_cast<NTL::RR>("0.5280364564853225211197557708655426736091e74"),
|
||||
boost::lexical_cast<NTL::RR>("0.3823205608981176913075543599005095206953e73"),
|
||||
boost::lexical_cast<NTL::RR>("0.2486733714214237704739129972671154532415e72"),
|
||||
boost::lexical_cast<NTL::RR>("0.1462562139602039577983434547171318011675e71"),
|
||||
boost::lexical_cast<NTL::RR>("0.7821169065036815012381267259559910324285e69"),
|
||||
boost::lexical_cast<NTL::RR>("0.3820552182348155468636157988764435365078e68"),
|
||||
boost::lexical_cast<NTL::RR>("0.1711618296983598244658239925535632505062e67"),
|
||||
boost::lexical_cast<NTL::RR>("0.7056661618357643731419080738521475204245e65"),
|
||||
boost::lexical_cast<NTL::RR>("0.2685246896473614017356264531791459936036e64"),
|
||||
boost::lexical_cast<NTL::RR>("0.9455168125599643085283071944864977592391e62"),
|
||||
boost::lexical_cast<NTL::RR>("0.3087541626972538362237309145177486236219e61"),
|
||||
boost::lexical_cast<NTL::RR>("0.9367928873352980208052601301625005737407e59"),
|
||||
boost::lexical_cast<NTL::RR>("0.2645306130689794942883818547314327466007e58"),
|
||||
boost::lexical_cast<NTL::RR>("0.6961815141171454309161007351079576190079e56"),
|
||||
boost::lexical_cast<NTL::RR>("0.1709637824471794552313802669803885946843e55"),
|
||||
boost::lexical_cast<NTL::RR>("0.3921553258481531526663112728778759311158e53"),
|
||||
boost::lexical_cast<NTL::RR>("0.8409006354449988687714450897575728228696e51"),
|
||||
boost::lexical_cast<NTL::RR>("0.1686755204461325935742097669030363344927e50"),
|
||||
boost::lexical_cast<NTL::RR>("0.3166653542877070999007425197729038754254e48"),
|
||||
boost::lexical_cast<NTL::RR>("0.5566029092358215049069560272835654229637e46"),
|
||||
boost::lexical_cast<NTL::RR>("0.9161766287916328133080586672953875116242e44"),
|
||||
boost::lexical_cast<NTL::RR>("1412317772330871298317974693514430627922000"),
|
||||
boost::lexical_cast<NTL::RR>("20387991986727877473732570146112459874790"),
|
||||
boost::lexical_cast<NTL::RR>("275557928713904105182512535678580359839.3"),
|
||||
boost::lexical_cast<NTL::RR>("3485719851040516559072031256589598330.723"),
|
||||
boost::lexical_cast<NTL::RR>("41247046743564028399938106707656877.40859"),
|
||||
boost::lexical_cast<NTL::RR>("456274078125709314602601667471879.0147312"),
|
||||
boost::lexical_cast<NTL::RR>("4714450683242899367025707077155.310613012"),
|
||||
boost::lexical_cast<NTL::RR>("45453933537925041680009544258.75073849996"),
|
||||
boost::lexical_cast<NTL::RR>("408437900487067278846361972.302331241052"),
|
||||
boost::lexical_cast<NTL::RR>("3415719344386166273085838.705771571751035"),
|
||||
boost::lexical_cast<NTL::RR>("26541502879185876562320.93134691487351145"),
|
||||
boost::lexical_cast<NTL::RR>("191261415065918713661.1571433274648417668"),
|
||||
boost::lexical_cast<NTL::RR>("1275349770108718421.645275944284937551702"),
|
||||
boost::lexical_cast<NTL::RR>("7849171120971773.318910987434906905704272"),
|
||||
boost::lexical_cast<NTL::RR>("44455946386549.80866460312682983576538056"),
|
||||
boost::lexical_cast<NTL::RR>("230920362395.3198137186361608905136598046"),
|
||||
boost::lexical_cast<NTL::RR>("1095700096.240863858624279930600654130254"),
|
||||
boost::lexical_cast<NTL::RR>("4727085.467506050153744334085516289728134"),
|
||||
boost::lexical_cast<NTL::RR>("18440.75118859447173303252421991479005424"),
|
||||
boost::lexical_cast<NTL::RR>("64.62515887799460295677071749181651317052"),
|
||||
boost::lexical_cast<NTL::RR>("0.201851568864688406206528472883512147547"),
|
||||
boost::lexical_cast<NTL::RR>("0.0005565091674187978029138500039504078098143"),
|
||||
boost::lexical_cast<NTL::RR>("0.1338097668312907986354698683493366559613e-5"),
|
||||
boost::lexical_cast<NTL::RR>("0.276308225077464312820179030238305271638e-8"),
|
||||
boost::lexical_cast<NTL::RR>("0.4801582970473168520375942100071070575043e-11"),
|
||||
boost::lexical_cast<NTL::RR>("0.6829184144212920949740376186058541800175e-14"),
|
||||
boost::lexical_cast<NTL::RR>("0.7634080076358511276617829524639455399182e-17"),
|
||||
boost::lexical_cast<NTL::RR>("0.6290035083727140966418512608156646142409e-20"),
|
||||
boost::lexical_cast<NTL::RR>("0.339652245667538733044036638506893821352e-23"),
|
||||
boost::lexical_cast<NTL::RR>("0.9017518064256388530773585529891677854909e-27")
|
||||
};
|
||||
static const NTL::RR Q[61] = {
|
||||
boost::lexical_cast<NTL::RR>("0"),
|
||||
boost::lexical_cast<NTL::RR>("0.1386831185456898357379390197203894063459e81"),
|
||||
boost::lexical_cast<NTL::RR>("0.6467076379487574703291056110838151259438e81"),
|
||||
boost::lexical_cast<NTL::RR>("0.1394967823848615838336194279565285465161e82"),
|
||||
boost::lexical_cast<NTL::RR>("0.1872927317344192945218570366455046340458e82"),
|
||||
boost::lexical_cast<NTL::RR>("0.1772461045338946243584650759986310355937e82"),
|
||||
boost::lexical_cast<NTL::RR>("0.1267294892200258648315971144069595555118e82"),
|
||||
boost::lexical_cast<NTL::RR>("0.7157764838362416821508872117623058626589e81"),
|
||||
boost::lexical_cast<NTL::RR>("0.329447266909948668265277828268378274513e81"),
|
||||
boost::lexical_cast<NTL::RR>("0.1264376077317689779509250183194342571207e81"),
|
||||
boost::lexical_cast<NTL::RR>("0.4118230304191980787640446056583623228873e80"),
|
||||
boost::lexical_cast<NTL::RR>("0.1154393529762694616405952270558316515261e80"),
|
||||
boost::lexical_cast<NTL::RR>("0.281655612889423906125295485693696744275e79"),
|
||||
boost::lexical_cast<NTL::RR>("0.6037483524928743102724159846414025482077e78"),
|
||||
boost::lexical_cast<NTL::RR>("0.1145927995397835468123576831800276999614e78"),
|
||||
boost::lexical_cast<NTL::RR>("0.1938624296151985600348534009382865995154e77"),
|
||||
boost::lexical_cast<NTL::RR>("0.293980925856227626211879961219188406675e76"),
|
||||
boost::lexical_cast<NTL::RR>("0.4015574518216966910319562902099567437832e75"),
|
||||
boost::lexical_cast<NTL::RR>("0.4961475457509727343545565970423431880907e74"),
|
||||
boost::lexical_cast<NTL::RR>("0.5565482348278933960215521991000378896338e73"),
|
||||
boost::lexical_cast<NTL::RR>("0.5686112924615820754631098622770303094938e72"),
|
||||
boost::lexical_cast<NTL::RR>("0.5305988545844796293285410303747469932856e71"),
|
||||
boost::lexical_cast<NTL::RR>("0.4533363413802585060568537458067343491358e70"),
|
||||
boost::lexical_cast<NTL::RR>("0.3553932059473516064068322757331575565718e69"),
|
||||
boost::lexical_cast<NTL::RR>("0.2561198565218704414618802902533972354203e68"),
|
||||
boost::lexical_cast<NTL::RR>("0.1699519313292900324098102065697454295572e67"),
|
||||
boost::lexical_cast<NTL::RR>("0.1039830160862334505389615281373574959236e66"),
|
||||
boost::lexical_cast<NTL::RR>("0.5873082967977428281000961954715372504986e64"),
|
||||
boost::lexical_cast<NTL::RR>("0.3065255179030575882202133042549783442446e63"),
|
||||
boost::lexical_cast<NTL::RR>("0.1479494813481364701208655943688307245459e62"),
|
||||
boost::lexical_cast<NTL::RR>("0.6608150467921598615495180659808895663164e60"),
|
||||
boost::lexical_cast<NTL::RR>("0.2732535313770902021791888953487787496976e59"),
|
||||
boost::lexical_cast<NTL::RR>("0.1046402297662493314531194338414508049069e58"),
|
||||
boost::lexical_cast<NTL::RR>("0.3711375077192882936085049147920021549622e56"),
|
||||
boost::lexical_cast<NTL::RR>("0.1219154482883895482637944309702972234576e55"),
|
||||
boost::lexical_cast<NTL::RR>("0.3708359374149458741391374452286837880162e53"),
|
||||
boost::lexical_cast<NTL::RR>("0.1044095509971707189716913168889769471468e52"),
|
||||
boost::lexical_cast<NTL::RR>("0.271951506225063286130946773813524945052e50"),
|
||||
boost::lexical_cast<NTL::RR>("0.6548016291215163843464133978454065823866e48"),
|
||||
boost::lexical_cast<NTL::RR>("0.1456062447610542135403751730809295219344e47"),
|
||||
boost::lexical_cast<NTL::RR>("0.2986690175077969760978388356833006028929e45"),
|
||||
boost::lexical_cast<NTL::RR>("5643149706574013350061247429006443326844000"),
|
||||
boost::lexical_cast<NTL::RR>("98047545414467090421964387960743688053480"),
|
||||
boost::lexical_cast<NTL::RR>("1563378767746846395507385099301468978550"),
|
||||
boost::lexical_cast<NTL::RR>("22823360528584500077862274918382796495"),
|
||||
boost::lexical_cast<NTL::RR>("304215527004115213046601295970388750"),
|
||||
boost::lexical_cast<NTL::RR>("3690289075895685793844344966820325"),
|
||||
boost::lexical_cast<NTL::RR>("40584512015702371433911456606050"),
|
||||
boost::lexical_cast<NTL::RR>("402834190897282802772754873905"),
|
||||
boost::lexical_cast<NTL::RR>("3589522158493606918146495750"),
|
||||
boost::lexical_cast<NTL::RR>("28530557707503483723634725"),
|
||||
boost::lexical_cast<NTL::RR>("200714561335055753000730"),
|
||||
boost::lexical_cast<NTL::RR>("1237953783437761888641"),
|
||||
boost::lexical_cast<NTL::RR>("6614698701445762950"),
|
||||
boost::lexical_cast<NTL::RR>("30155495647727505"),
|
||||
boost::lexical_cast<NTL::RR>("114953256021450"),
|
||||
boost::lexical_cast<NTL::RR>("356398020013"),
|
||||
boost::lexical_cast<NTL::RR>("863113950"),
|
||||
boost::lexical_cast<NTL::RR>("1531345"),
|
||||
boost::lexical_cast<NTL::RR>("1770"),
|
||||
boost::lexical_cast<NTL::RR>("1")
|
||||
};
|
||||
static const NTL::RR PD[60] = {
|
||||
boost::lexical_cast<NTL::RR>("0.6365271516829242456324234577164675383137e81"),
|
||||
2*boost::lexical_cast<NTL::RR>("0.2991038873096202943405966144203628966976e81"),
|
||||
3*boost::lexical_cast<NTL::RR>("0.9211116495503170498076013367421231351115e80"),
|
||||
4*boost::lexical_cast<NTL::RR>("0.2090792764676090716286400360584443891749e80"),
|
||||
5*boost::lexical_cast<NTL::RR>("0.3730037777359591428226035156377978092809e79"),
|
||||
6*boost::lexical_cast<NTL::RR>("0.5446396536956682043376492370432031543834e78"),
|
||||
7*boost::lexical_cast<NTL::RR>("0.6692523966335177847425047827449069256345e77"),
|
||||
8*boost::lexical_cast<NTL::RR>("0.7062543624100864681625612653756619116848e76"),
|
||||
9*boost::lexical_cast<NTL::RR>("0.6499914905966283735005256964443226879158e75"),
|
||||
10*boost::lexical_cast<NTL::RR>("0.5280364564853225211197557708655426736091e74"),
|
||||
11*boost::lexical_cast<NTL::RR>("0.3823205608981176913075543599005095206953e73"),
|
||||
12*boost::lexical_cast<NTL::RR>("0.2486733714214237704739129972671154532415e72"),
|
||||
13*boost::lexical_cast<NTL::RR>("0.1462562139602039577983434547171318011675e71"),
|
||||
14*boost::lexical_cast<NTL::RR>("0.7821169065036815012381267259559910324285e69"),
|
||||
15*boost::lexical_cast<NTL::RR>("0.3820552182348155468636157988764435365078e68"),
|
||||
16*boost::lexical_cast<NTL::RR>("0.1711618296983598244658239925535632505062e67"),
|
||||
17*boost::lexical_cast<NTL::RR>("0.7056661618357643731419080738521475204245e65"),
|
||||
18*boost::lexical_cast<NTL::RR>("0.2685246896473614017356264531791459936036e64"),
|
||||
19*boost::lexical_cast<NTL::RR>("0.9455168125599643085283071944864977592391e62"),
|
||||
20*boost::lexical_cast<NTL::RR>("0.3087541626972538362237309145177486236219e61"),
|
||||
21*boost::lexical_cast<NTL::RR>("0.9367928873352980208052601301625005737407e59"),
|
||||
22*boost::lexical_cast<NTL::RR>("0.2645306130689794942883818547314327466007e58"),
|
||||
23*boost::lexical_cast<NTL::RR>("0.6961815141171454309161007351079576190079e56"),
|
||||
24*boost::lexical_cast<NTL::RR>("0.1709637824471794552313802669803885946843e55"),
|
||||
25*boost::lexical_cast<NTL::RR>("0.3921553258481531526663112728778759311158e53"),
|
||||
26*boost::lexical_cast<NTL::RR>("0.8409006354449988687714450897575728228696e51"),
|
||||
27*boost::lexical_cast<NTL::RR>("0.1686755204461325935742097669030363344927e50"),
|
||||
28*boost::lexical_cast<NTL::RR>("0.3166653542877070999007425197729038754254e48"),
|
||||
29*boost::lexical_cast<NTL::RR>("0.5566029092358215049069560272835654229637e46"),
|
||||
30*boost::lexical_cast<NTL::RR>("0.9161766287916328133080586672953875116242e44"),
|
||||
31*boost::lexical_cast<NTL::RR>("1412317772330871298317974693514430627922000"),
|
||||
32*boost::lexical_cast<NTL::RR>("20387991986727877473732570146112459874790"),
|
||||
33*boost::lexical_cast<NTL::RR>("275557928713904105182512535678580359839.3"),
|
||||
34*boost::lexical_cast<NTL::RR>("3485719851040516559072031256589598330.723"),
|
||||
35*boost::lexical_cast<NTL::RR>("41247046743564028399938106707656877.40859"),
|
||||
36*boost::lexical_cast<NTL::RR>("456274078125709314602601667471879.0147312"),
|
||||
37*boost::lexical_cast<NTL::RR>("4714450683242899367025707077155.310613012"),
|
||||
38*boost::lexical_cast<NTL::RR>("45453933537925041680009544258.75073849996"),
|
||||
39*boost::lexical_cast<NTL::RR>("408437900487067278846361972.302331241052"),
|
||||
40*boost::lexical_cast<NTL::RR>("3415719344386166273085838.705771571751035"),
|
||||
41*boost::lexical_cast<NTL::RR>("26541502879185876562320.93134691487351145"),
|
||||
42*boost::lexical_cast<NTL::RR>("191261415065918713661.1571433274648417668"),
|
||||
43*boost::lexical_cast<NTL::RR>("1275349770108718421.645275944284937551702"),
|
||||
44*boost::lexical_cast<NTL::RR>("7849171120971773.318910987434906905704272"),
|
||||
45*boost::lexical_cast<NTL::RR>("44455946386549.80866460312682983576538056"),
|
||||
46*boost::lexical_cast<NTL::RR>("230920362395.3198137186361608905136598046"),
|
||||
47*boost::lexical_cast<NTL::RR>("1095700096.240863858624279930600654130254"),
|
||||
48*boost::lexical_cast<NTL::RR>("4727085.467506050153744334085516289728134"),
|
||||
49*boost::lexical_cast<NTL::RR>("18440.75118859447173303252421991479005424"),
|
||||
50*boost::lexical_cast<NTL::RR>("64.62515887799460295677071749181651317052"),
|
||||
51*boost::lexical_cast<NTL::RR>("0.201851568864688406206528472883512147547"),
|
||||
52*boost::lexical_cast<NTL::RR>("0.0005565091674187978029138500039504078098143"),
|
||||
53*boost::lexical_cast<NTL::RR>("0.1338097668312907986354698683493366559613e-5"),
|
||||
54*boost::lexical_cast<NTL::RR>("0.276308225077464312820179030238305271638e-8"),
|
||||
55*boost::lexical_cast<NTL::RR>("0.4801582970473168520375942100071070575043e-11"),
|
||||
56*boost::lexical_cast<NTL::RR>("0.6829184144212920949740376186058541800175e-14"),
|
||||
57*boost::lexical_cast<NTL::RR>("0.7634080076358511276617829524639455399182e-17"),
|
||||
58*boost::lexical_cast<NTL::RR>("0.6290035083727140966418512608156646142409e-20"),
|
||||
59*boost::lexical_cast<NTL::RR>("0.339652245667538733044036638506893821352e-23"),
|
||||
60*boost::lexical_cast<NTL::RR>("0.9017518064256388530773585529891677854909e-27")
|
||||
};
|
||||
static const NTL::RR QD[60] = {
|
||||
boost::lexical_cast<NTL::RR>("0.1386831185456898357379390197203894063459e81"),
|
||||
2*boost::lexical_cast<NTL::RR>("0.6467076379487574703291056110838151259438e81"),
|
||||
3*boost::lexical_cast<NTL::RR>("0.1394967823848615838336194279565285465161e82"),
|
||||
4*boost::lexical_cast<NTL::RR>("0.1872927317344192945218570366455046340458e82"),
|
||||
5*boost::lexical_cast<NTL::RR>("0.1772461045338946243584650759986310355937e82"),
|
||||
6*boost::lexical_cast<NTL::RR>("0.1267294892200258648315971144069595555118e82"),
|
||||
7*boost::lexical_cast<NTL::RR>("0.7157764838362416821508872117623058626589e81"),
|
||||
8*boost::lexical_cast<NTL::RR>("0.329447266909948668265277828268378274513e81"),
|
||||
9*boost::lexical_cast<NTL::RR>("0.1264376077317689779509250183194342571207e81"),
|
||||
10*boost::lexical_cast<NTL::RR>("0.4118230304191980787640446056583623228873e80"),
|
||||
11*boost::lexical_cast<NTL::RR>("0.1154393529762694616405952270558316515261e80"),
|
||||
12*boost::lexical_cast<NTL::RR>("0.281655612889423906125295485693696744275e79"),
|
||||
13*boost::lexical_cast<NTL::RR>("0.6037483524928743102724159846414025482077e78"),
|
||||
14*boost::lexical_cast<NTL::RR>("0.1145927995397835468123576831800276999614e78"),
|
||||
15*boost::lexical_cast<NTL::RR>("0.1938624296151985600348534009382865995154e77"),
|
||||
16*boost::lexical_cast<NTL::RR>("0.293980925856227626211879961219188406675e76"),
|
||||
17*boost::lexical_cast<NTL::RR>("0.4015574518216966910319562902099567437832e75"),
|
||||
18*boost::lexical_cast<NTL::RR>("0.4961475457509727343545565970423431880907e74"),
|
||||
19*boost::lexical_cast<NTL::RR>("0.5565482348278933960215521991000378896338e73"),
|
||||
20*boost::lexical_cast<NTL::RR>("0.5686112924615820754631098622770303094938e72"),
|
||||
21*boost::lexical_cast<NTL::RR>("0.5305988545844796293285410303747469932856e71"),
|
||||
22*boost::lexical_cast<NTL::RR>("0.4533363413802585060568537458067343491358e70"),
|
||||
23*boost::lexical_cast<NTL::RR>("0.3553932059473516064068322757331575565718e69"),
|
||||
24*boost::lexical_cast<NTL::RR>("0.2561198565218704414618802902533972354203e68"),
|
||||
25*boost::lexical_cast<NTL::RR>("0.1699519313292900324098102065697454295572e67"),
|
||||
26*boost::lexical_cast<NTL::RR>("0.1039830160862334505389615281373574959236e66"),
|
||||
27*boost::lexical_cast<NTL::RR>("0.5873082967977428281000961954715372504986e64"),
|
||||
28*boost::lexical_cast<NTL::RR>("0.3065255179030575882202133042549783442446e63"),
|
||||
29*boost::lexical_cast<NTL::RR>("0.1479494813481364701208655943688307245459e62"),
|
||||
30*boost::lexical_cast<NTL::RR>("0.6608150467921598615495180659808895663164e60"),
|
||||
31*boost::lexical_cast<NTL::RR>("0.2732535313770902021791888953487787496976e59"),
|
||||
32*boost::lexical_cast<NTL::RR>("0.1046402297662493314531194338414508049069e58"),
|
||||
33*boost::lexical_cast<NTL::RR>("0.3711375077192882936085049147920021549622e56"),
|
||||
34*boost::lexical_cast<NTL::RR>("0.1219154482883895482637944309702972234576e55"),
|
||||
35*boost::lexical_cast<NTL::RR>("0.3708359374149458741391374452286837880162e53"),
|
||||
36*boost::lexical_cast<NTL::RR>("0.1044095509971707189716913168889769471468e52"),
|
||||
37*boost::lexical_cast<NTL::RR>("0.271951506225063286130946773813524945052e50"),
|
||||
38*boost::lexical_cast<NTL::RR>("0.6548016291215163843464133978454065823866e48"),
|
||||
39*boost::lexical_cast<NTL::RR>("0.1456062447610542135403751730809295219344e47"),
|
||||
40*boost::lexical_cast<NTL::RR>("0.2986690175077969760978388356833006028929e45"),
|
||||
41*boost::lexical_cast<NTL::RR>("5643149706574013350061247429006443326844000"),
|
||||
42*boost::lexical_cast<NTL::RR>("98047545414467090421964387960743688053480"),
|
||||
43*boost::lexical_cast<NTL::RR>("1563378767746846395507385099301468978550"),
|
||||
44*boost::lexical_cast<NTL::RR>("22823360528584500077862274918382796495"),
|
||||
45*boost::lexical_cast<NTL::RR>("304215527004115213046601295970388750"),
|
||||
46*boost::lexical_cast<NTL::RR>("3690289075895685793844344966820325"),
|
||||
47*boost::lexical_cast<NTL::RR>("40584512015702371433911456606050"),
|
||||
48*boost::lexical_cast<NTL::RR>("402834190897282802772754873905"),
|
||||
49*boost::lexical_cast<NTL::RR>("3589522158493606918146495750"),
|
||||
50*boost::lexical_cast<NTL::RR>("28530557707503483723634725"),
|
||||
51*boost::lexical_cast<NTL::RR>("200714561335055753000730"),
|
||||
52*boost::lexical_cast<NTL::RR>("1237953783437761888641"),
|
||||
53*boost::lexical_cast<NTL::RR>("6614698701445762950"),
|
||||
54*boost::lexical_cast<NTL::RR>("30155495647727505"),
|
||||
55*boost::lexical_cast<NTL::RR>("114953256021450"),
|
||||
56*boost::lexical_cast<NTL::RR>("356398020013"),
|
||||
57*boost::lexical_cast<NTL::RR>("863113950"),
|
||||
58*boost::lexical_cast<NTL::RR>("1531345"),
|
||||
59*boost::lexical_cast<NTL::RR>("1770"),
|
||||
60*boost::lexical_cast<NTL::RR>("1")
|
||||
};
|
||||
static const double g = 63.192152;
|
||||
|
||||
NTL::RR zgh = x + g - 0.5;
|
||||
|
||||
NTL::RR result = (x - 0.5) / zgh;
|
||||
result += log(zgh);
|
||||
result += tools::evaluate_polynomial(PD, x) / tools::evaluate_polynomial(P, x);
|
||||
result -= tools::evaluate_polynomial(QD, x) / tools::evaluate_polynomial(Q, x);
|
||||
result -= 1;
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
NTL::RR digamma(NTL::RR x)
|
||||
{
|
||||
if(x < 0)
|
||||
{
|
||||
return digamma_imp(1-x) + constants::pi<NTL::RR>() / tan(constants::pi<NTL::RR>() * (1-x));
|
||||
}
|
||||
return digamma_imp(x);
|
||||
}
|
||||
|
||||
}}
|
||||
|
||||
#endif // include guard
|
||||
Reference in New Issue
Block a user