aitken | R Documentation |
Aitken's acceleration method.
aitken(f, x0, nmax = 12, tol = 1e-8, ...)
f |
Function with a fixpoint. |
x0 |
Starting value. |
nmax |
Maximum number of iterations. |
tol |
Relative tolerance. |
... |
Additional variables passed to f. |
Aitken's acceleration method, or delta-squared process, is used for accelerating the rate of convergence of a sequence (from linear to quadratic), here applied to the fixed point iteration scheme of a function.
The fixpoint (as found so far).
Sometimes used to accerate Newton-Raphson (Steffensen's method).
Quarteroni, A., and F. Saleri (2006). Scientific Computing with Matlab and Octave. Second Edition, Springer-Verlag, Berlin Heidelberg.
lambertWp
# Find a zero of f(x) = cos(x) - x*exp(x)
# as fixpoint of phi(x) = x + (cos(x) - x*exp(x))/2
phi <- function(x) x + (cos(x) - x*exp(x))/2
aitken(phi, 0) #=> 0.5177574
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.