// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
#include <boost/math/tools/series.hpp>
+#include <boost/assert.hpp>
+
#include <iostream>
#include <complex>
#include <cassert>
{
// This is the function operator invoked by the summation
// algorithm, the first call to this operator should return
- // the first term of the series, the second call the second
+ // the first term of the series, the second call the second
// term and so on.
m_prod *= m_mult;
return m_prod / ++k;
T log1p(T x)
{
// We really should add some error checking on x here!
- assert(std::fabs(x) < 1);
+ BOOST_ASSERT(std::fabs(x) < 1);
// Construct the series functor:
log1p_series<T> s(x);
{
// This is the function operator invoked by the summation
// algorithm, the first call to this operator should return
- // the first term of the series, the second call the second
+ // the first term of the series, the second call the second
// term and so on.
m_prod *= m_mult;
return m_prod / T(++k);
std::complex<T> log1p(std::complex<T> x)
{
// We really should add some error checking on x here!
- assert(abs(x) < 1);
+ BOOST_ASSERT(abs(x) < 1);
// Construct the series functor:
log1p_series<std::complex<T> > s(x);