Java Number Cruncher: The Java Programmer's Guide to Numerical Computing By Ronald Mak
Table of Contents
Chapter 5. Finding Roots
If the graph of function f ( x ) touches or crosses the x axis tangentially, then there are multiple roots at that point. In other words, if f ( x r ) = 0 and f '( x r ) = 0, then x r is a multiple root. For example, 2 is a double root of the function
Multiple roots are problematic for Newton's algorithm and the secant algorithm because the derivative value is 0. The function plot does not cross the x axis at an even degree (double, quadruple, etc.) multiple root. Figure 5-4 shows that the function f ( x ) = x 2 - 4 x + 4 is always positive, so the bracketing algorithms, which require a sign change, won't work, either.
Figure 5-4. The graph of f ( x ) = x 2 - 4 x + 4 with a double root at x = 2.