Update of /cvsroot/boost-sandbox/boost-sandbox/boost/math/special_functions
In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv22857/boost/math/special_functions
Modified Files:
Tag: math_toolkit
ellint_1.hpp ellint_rf.hpp
Log Message:
Adjusted Mac OS error levels.
Fixed up pareto failures.
Added some debugging code to track remaining Mac OS failures.
Index: ellint_rf.hpp
===================================================================
RCS file: /cvsroot/boost-sandbox/boost-sandbox/boost/math/special_functions/Attic/ellint_rf.hpp,v
retrieving revision 1.1.2.2
retrieving revision 1.1.2.3
diff -u -d -r1.1.2.2 -r1.1.2.3
--- ellint_rf.hpp 5 Feb 2007 10:34:44 -0000 1.1.2.2
+++ ellint_rf.hpp 11 Apr 2007 11:44:42 -0000 1.1.2.3
@@ -54,10 +54,12 @@
if(tools::digits<T>() > 64)
{
tolerance = pow(tools::epsilon<T>(), T(1)/4.25f);
+ BOOST_MATH_INSTRUMENT_CODE(tolerance);
}
else
{
tolerance = pow(4*tools::epsilon<T>(), T(1)/6);
+ BOOST_MATH_INSTRUMENT_CODE(tolerance);
}
// duplication
@@ -82,11 +84,13 @@
}
// Check to see if we gave up too soon:
tools::check_series_iterations(BOOST_CURRENT_FUNCTION, k);
+ BOOST_MATH_INSTRUMENT_CODE(k);
// Taylor series expansion to the 5th order
E2 = X * Y - Z * Z;
E3 = X * Y * Z;
value = (1 + E2*(E2/24 - E3*T(3)/44 - T(0.1)) + E3/14) / sqrt(u);
+ BOOST_MATH_INSTRUMENT_CODE(value);
return value;
}
Index: ellint_1.hpp
===================================================================
RCS file: /cvsroot/boost-sandbox/boost-sandbox/boost/math/special_functions/Attic/ellint_1.hpp,v
retrieving revision 1.1.2.4
retrieving revision 1.1.2.5
diff -u -d -r1.1.2.4 -r1.1.2.5
--- ellint_1.hpp 5 Feb 2007 10:34:43 -0000 1.1.2.4
+++ ellint_1.hpp 11 Apr 2007 11:44:41 -0000 1.1.2.5
@@ -43,6 +43,7 @@
bool invert = false;
if(phi < 0)
{
+ BOOST_MATH_INSTRUMENT_CODE(phi);
phi = fabs(phi);
invert = true;
}
@@ -53,12 +54,14 @@
{
// Need to handle infinity as a special case:
result = tools::overflow_error<T>(BOOST_CURRENT_FUNCTION);
+ BOOST_MATH_INSTRUMENT_CODE(result);
}
else if(phi > 1 / tools::epsilon<T>())
{
// Phi is so large that phi%pi is necessarily zero (or garbage),
// just return the second part of the duplication formula:
result = 2 * phi * ellint_k_imp(k) / constants::pi<T>();
+ BOOST_MATH_INSTRUMENT_CODE(result);
}
else
{
@@ -70,19 +73,26 @@
// so rewritten to use fmod instead:
//
T rphi = fmod(phi, constants::pi<T>() / 2);
+ BOOST_MATH_INSTRUMENT_CODE(rphi);
T m = 2 * (phi - rphi) / constants::pi<T>();
+ BOOST_MATH_INSTRUMENT_CODE(m);
int s = 1;
if(fmod(m, T(2)) > 0.5)
{
m += 1;
s = -1;
rphi = constants::pi<T>() / 2 - rphi;
+ BOOST_MATH_INSTRUMENT_CODE(rphi);
}
T sinp = sin(rphi);
T cosp = cos(rphi);
result = s * sinp * ellint_rf_imp(cosp * cosp, 1 - k * k * sinp * sinp, T(1));
+ BOOST_MATH_INSTRUMENT_CODE(result);
if(m != 0)
+ {
result += m * ellint_k_imp(k);
+ BOOST_MATH_INSTRUMENT_CODE(result);
+ }
}
return invert ? -result : result;
}
|