Student[NumericalAnalysis][Steffensen] - numerically approximate the real roots of an expression using Steffensen's method
|
Calling Sequence
|
|
Steffensen(f, x=a, opts)
Steffensen(f, a, opts)
|
|
Parameters
|
|
f
|
-
|
algebraic; expression in the variable x representing a continuous function
|
x
|
-
|
name; the independent variable of f
|
a
|
-
|
numeric; the initial approximate root
|
opts
|
-
|
(optional) equation(s) of the form keyword=value, where keyword is one of fixedpointiterator, functionoptions, lineoptions, maxiterations, output, pointoptions, showfunction, showlines, showpoints, stoppingcriterion, tickmarks, caption, tolerance, verticallineoptions, view; the options for approximating the roots of f
|
|
|
|
|
Description
|
|
•
|
The Steffensen command numerically approximates the roots of an algebraic function, f, using fixed-point iteration coupled with a slightly modified version of Aitken's technique of accelerating sequential convergence.
|
•
|
The first argument f may be substituted with an option of the form fixedpointiterator = fpexpr. See Notes.
|
•
|
The Steffensen command is a shortcut for calling the Roots command with the method=steffensen option.
|
|
|
Options
|
|
•
|
fixedpointiterator = algebraic (optional)
|
|
An expression that will be used to generate the fixed-point iteration sequence. If this option is specified, the first argument, f, must be omitted. See the Notes section for more details.
|
|
A list of options for the plot of the expression f. By default, f is plotted as a solid red line.
|
|
A list of options for the lines on the plot. By default the lines are solid blue.
|
|
The maximum number of iterations to to perform. The default value of maxiterations depends on which type of output is chosen:
|
–
|
output = value: default maxiterations = 100
|
–
|
output = sequence: default maxiterations = 10
|
–
|
output = information: default maxiterations = 10
|
–
|
output = plot: default maxiterations = 5
|
–
|
output = animation: default maxiterations = 10
|
•
|
output = value, sequence, plot, animation, or information
|
|
The return value of the function. The default is value.
|
–
|
output = value returns the final numerical approximation of the root.
|
–
|
output = plot returns a plot of f with each iterative approximation shown and the relevant information about the numerical approximation displayed in the caption of the plot.
|
–
|
output = animation returns an animation showing the iterations of the root approximation process.
|
–
|
output = information returns detailed information about the iterative approximations of the root of f.
|
|
The final plot options when output = plot or output = animation.
|
|
A list of options for the points on the plot. By default, the points are plotted as green circles.
|
•
|
showfunction = truefalse
|
|
Whether to display f on the plot or not. By default, this option is set to true.
|
|
Whether to display lines that accentuate each approximate iteration when output = plot. By default, this option is set to true.
|
|
Whether to display the points at each approximate iteration on the plot when output = plot. By default, this option is set to true.
|
•
|
stoppingcriterion = relative, absolute, or function_value
|
|
The criterion that the approximations must meet before discontinuing the iterations. The following describes each criterion:
|
–
|
relative : < tolerance
|
–
|
absolute : < tolerance
|
–
|
function_value : < tolerance
|
|
By default, stoppingcriterion = relative.
|
|
A caption for the plot. The default caption contains general information concerning the approximation. For more information about specifying a caption, see plot/typesetting.
|
|
The error tolerance of the approximation. The default value is .
|
•
|
verticallineoptions = list
|
|
A list of options for the vertical lines on the plot. By default, the lines are dashed and blue.
|
•
|
view = [realcons..realcons, realcons..realcons]
|
|
The plotview of the plot when output = plot. See plot/options for more information.
|
|
|
Notes
|
|
|
When output = plot or output = animation is specified, both the function and the fixed-point iterator function will be plotted and correspondingly labelled.
|
|
The tolerance option, when stoppingcriterion = function_value, applies to the function in the root-finding form of the problem.
|
|
|
Examples
|
|
>
|
|
>
|
|
>
|
|
| (1) |
>
|
|
| (2) |
>
|
|
>
|
|
|
|