Why logarithm error bounds depend on location
The expression \(\ln(1+x)\) is defined for \(x>-1\), but its behavior is not symmetric around \(x=0\). Moving to the right from zero, the input \(1+x\) increases. Moving left, the input approaches zero, where the logarithm has a singularity. That nearby singularity affects how large the derivatives can become on the interval used in an error estimate.
The Taylor polynomial about zero is
where \(n\) is a nonnegative integer and \(P_0(x)=0\). We will use Lagrange’s remainder bound to control the difference between \(\ln(1+x)\) and \(P_n(x)\). The key practical task is to bound the \((n+1)\)st derivative on the entire interval from the center \(0\) to the input \(x\).
Derivatives and the required interval
For every positive integer \(m\), differentiating \(\ln(1+t)\) gives
For example, the first derivative is \(1/(1+t)\), the second is \(-1/(1+t)^2\), and the third is \(2/(1+t)^3\). The general formula follows by induction: differentiating the expression for order \(m\) multiplies by \(-m\) and raises the denominator’s power from \(m\) to \(m+1\), giving the stated expression for order \(m+1\).
To use the Lagrange bound for \(P_n\), set \(m=n+1\). The absolute value of the derivative that must be bounded is therefore
This function is largest where \(1+t\) is smallest. On the segment from \(0\) to a positive \(x\), the smallest value of \(1+t\) is \(1\). On the segment from a negative \(x\) to \(0\), it is \(1+x\). These are different derivative bounds, even when the two inputs have the same distance from zero.
The bound on either side of zero
For \(x\geq 0\), the derivative magnitude on \([0,x]\) is at most \(n!\). For \(-1<x<0\), it is at most \(n!/(1+x)^{n+1}\). Substitution into Lagrange’s formula gives the useful pointwise estimates below.
These estimates require no assumption that the polynomial actually gives a good approximation: they follow whenever the function has \(n+1\) continuous derivatives on an open interval containing the segment between zero and \(x\). For \(\ln(1+t)\), this condition holds whenever \(x>-1\). The quality of the bound is a separate question.
Worked Example: A positive input
Worked Example: Bounding the error at \(x=1/4\)
Approximate \(\ln(5/4)\) using the degree-three Taylor polynomial and find its Lagrange error bound. Since \(1+x=5/4\), the target value is indeed \(\ln(1+x)=\ln(5/4)\).
The polynomial is
At \(x=1/4\), its three terms are
On the interval \([0,1/4]\), the third-order derivative needed for the remainder is the fourth derivative. Its magnitude is \(3!/(1+t)^4\), which is at most \(3!=6\), attained at \(t=0\). Thus \(M=6\), and
The bound is about \(0.000977\). The polynomial value is \(43/192\), approximately \(0.223958\); the bound guarantees that the true logarithm differs from this value by no more than \(1/1024\). The calculation uses the maximum derivative on the full segment, not only the derivative at the target.
Worked Example: A negative input near the singularity
Worked Example: Bounding the error at \(x=-1/2\)
Use \(P_3\) to approximate \(\ln(1/2)\). Substitution gives
On \([-1/2,0]\), the fourth derivative has magnitude \(3!/(1+t)^4\). Since \(1+t\geq 1/2\) on this interval,
Consequently,
The exact Lagrange estimate is also obtained from the negative-side formula: \(\frac14( (1/2)/(1/2))^4=1/4\). The true difference is about \(0.02648\), which is below \(0.25\). The bound is valid but fairly loose.
How the distance to \(-1\) affects the bound
For a fixed negative input \(x=-a\), where \(0<a<1\), the estimate can be written
The number \(1-a\) is the distance from \(-a\) to the singular point \(-1\), while \(a\) is the distance from \(-a\) to the expansion center \(0\). The ratio compares those distances. When the target lies closer to the singularity than to the center, \(a>1-a\), so this ratio exceeds \(1\). In that case the bound eventually grows with the degree, although it may decrease initially. It is the bound that fails to become small; this observation alone does not establish that the actual error grows.
For example, at \(x=-3/5\), the ratio is \(3/2\). The bounds for degrees zero, one, and two are respectively
Thus the bound decreases at first and then stays the same. To see what happens eventually, write \(B_n=q^{n+1}/(n+1)\), where \(q=3/2\). The ratio of successive bounds is
For \(q=3/2\), this ratio exceeds \(1\) when \(3(n+1)>2(n+2)\), or \(n>1\). In particular, \(B_3>B_2\). More generally, if \(q>1\), this ratio is eventually greater than \(1\), and the exponential factor eventually dominates the factor \(1/(n+1)\). If \(q<1\), the bound tends to zero; if \(q=1\), it is \(1/(n+1)\), which also tends to zero.
Worked Example: A uniform bound on an interval
Worked Example: Bounding the error throughout \([-1/3,1/4]\)
Find a degree-four Lagrange error bound valid for every \(x\) in \([-1/3,1/4]\). For \(x\in[-1/3,0]\), the negative-side estimate is largest at \(x=-1/3\): the ratio \(|x|/(1+x)\) increases as \(|x|\) increases, and here its largest value is \((1/3)/(2/3)=1/2\). Therefore
For \(x\in[0,1/4]\), the positive-side estimate is at most
Since \(1/5120<1/160\), the single bound \(1/160\) applies across the whole interval. To check the derivative calculation directly, the fifth derivative has magnitude \(4!/(1+t)^5\). On the full interval, \(1+t\geq2/3\), so its maximum is \(24(3/2)^5=729/4\). With \(|x|\leq1/3\), the general Lagrange formula gives
This confirms the interval-wide result using one derivative maximum and the greatest distance from the center.
A common mistake: using the derivative bound from the wrong side
A tempting but incorrect shortcut is to use \(M=n!\) for negative inputs, just as on a positive interval. For the degree-three approximation at \(x=-1/2\), that shortcut would give
But \(6\) is not an upper bound for the fourth derivative’s magnitude on \([-1/2,0]\): at \(t=-1/2\), that magnitude is \(6/(1/2)^4=96\). The proposed bound \(1/64\) is even smaller than the actual error, approximately \(0.02648\), so it cannot be valid. The corrected derivative maximum is \(96\), yielding the valid bound \(1/4\). Always find the derivative maximum over the entire segment before applying the remainder formula.
What the estimate tells you—and what it does not
Lagrange’s bound is a certificate: if its value is below a requested tolerance, then the approximation is guaranteed to meet that tolerance. It need not be the smallest possible bound, and a large bound does not prove that the approximation itself is poor. It may simply be too crude to certify the actual error.
For positive inputs up to \(1\), the bound \(x^{n+1}/(n+1)\) tends to zero as the degree increases. On the negative side, the corresponding bound tends to zero for \(|x|\leq1/2\), but for \(1/2<|x|<1\) its ratio \(|x|/(1-|x|)\) exceeds \(1\), so this particular Lagrange estimate does not tend to zero. The distinction comes from the derivative maximum near \(-1\), not from a change in the remainder formula.
Check Your Understanding
Use the derivative maximum on the relevant segment in each question, rather than assuming the positive-side bound applies everywhere.
- State the Lagrange remainder bound for \(P_n\) and identify the derivative that must be bounded.
- For \(x=-1/4\), what is the ratio \(|x|/(1+x)\) in the negative-side estimate?
- Why does the maximum derivative magnitude on \([-a,0]\) occur at \(-a\), for \(0<a<1\)?
- For \(x=-3/5\), why does the Lagrange bound eventually increase with degree even though its first values do not increase at every step?
- What is wrong with using \(M=n!\) for a negative input without checking the interval of differentiation?