<s>
In	O
numerical	B-General_Concept
analysis	I-General_Concept
,	O
Richardson	B-Algorithm
extrapolation	I-Algorithm
is	O
a	O
sequence	B-Algorithm
acceleration	I-Algorithm
method	O
used	O
to	O
improve	O
the	O
rate	B-Architecture
of	I-Architecture
convergence	I-Architecture
of	O
a	O
sequence	O
of	O
estimates	O
of	O
some	O
value	O
.	O
</s>
<s>
Practical	O
applications	O
of	O
Richardson	B-Algorithm
extrapolation	I-Algorithm
include	O
Romberg	B-Algorithm
integration	I-Algorithm
,	O
which	O
applies	O
Richardson	B-Algorithm
extrapolation	I-Algorithm
to	O
the	O
trapezoid	B-Algorithm
rule	I-Algorithm
,	O
and	O
the	O
Bulirsch	B-Algorithm
–	I-Algorithm
Stoer	I-Algorithm
algorithm	I-Algorithm
for	O
solving	O
ordinary	O
differential	O
equations	O
.	O
</s>
<s>
Furthermore	O
,	O
represents	O
the	O
truncation	B-Algorithm
error	I-Algorithm
of	O
the	O
approximation	O
such	O
that	O
Similarly	O
,	O
in	O
the	O
approximation	O
is	O
said	O
to	O
be	O
an	O
approximation	O
.	O
</s>
<s>
By	O
this	O
process	O
,	O
we	O
have	O
achieved	O
a	O
better	O
approximation	O
of	O
by	O
subtracting	O
the	O
largest	O
term	O
in	O
the	O
error	B-Algorithm
which	O
was	O
.	O
</s>
<s>
This	O
process	O
can	O
be	O
repeated	O
to	O
remove	O
more	O
error	B-Algorithm
terms	O
to	O
get	O
even	O
better	O
approximations	O
.	O
</s>
<s>
To	O
improve	O
our	O
approximation	O
from	O
to	O
by	O
removing	O
the	O
first	O
error	B-Algorithm
term	O
,	O
we	O
multiply	O
the	O
second	O
equation	O
(	O
2	O
)	O
by	O
and	O
subtract	O
the	O
first	O
equation	O
(	O
1	O
)	O
to	O
give	O
usThis	O
multiplication	O
and	O
subtraction	O
was	O
performed	O
because	O
is	O
an	O
approximation	O
of	O
.	O
</s>
<s>
The	O
Richardson	B-Algorithm
extrapolation	I-Algorithm
can	O
be	O
considered	O
as	O
a	O
linear	O
sequence	O
transformation	O
.	O
</s>
<s>
Additionally	O
,	O
the	O
general	O
formula	O
can	O
be	O
used	O
to	O
estimate	O
(	O
leading	O
order	O
step	O
size	O
behavior	O
of	O
Truncation	B-Algorithm
error	I-Algorithm
)	O
when	O
neither	O
its	O
value	O
nor	O
is	O
known	O
a	O
priori	O
.	O
</s>
<s>
Such	O
a	O
technique	O
can	O
be	O
useful	O
for	O
quantifying	O
an	O
unknown	O
rate	B-Architecture
of	I-Architecture
convergence	I-Architecture
.	O
</s>
<s>
Given	O
approximations	O
of	O
from	O
three	O
distinct	O
step	O
sizes	O
,	O
,	O
and	O
,	O
the	O
exact	O
relationshipyields	O
an	O
approximate	O
relationship	O
(	O
please	O
note	O
that	O
the	O
notation	O
here	O
may	O
cause	O
a	O
bit	O
of	O
confusion	O
,	O
the	O
two	O
O	O
appearing	O
in	O
the	O
equation	O
above	O
only	O
indicates	O
the	O
leading	O
order	O
step	O
size	O
behavior	O
but	O
their	O
explicit	O
forms	O
are	O
different	O
and	O
hence	O
cancelling	O
out	O
of	O
the	O
two	O
O	O
terms	O
is	O
approximately	O
valid	O
)	O
which	O
can	O
be	O
solved	O
numerically	B-General_Concept
to	O
estimate	O
for	O
some	O
arbitrary	O
choices	O
of	O
,	O
,	O
and	O
.	O
</s>
<s>
Then	O
is	O
called	O
the	O
Richardson	B-Algorithm
extrapolation	I-Algorithm
of	O
A(h )	O
,	O
and	O
has	O
a	O
higher-order	O
error	B-Algorithm
estimate	O
compared	O
to	O
.	O
</s>
<s>
Where	O
A( h′	O
)	O
can	O
cause	O
problems	O
due	O
to	O
limited	O
precision	O
(	O
rounding	B-Algorithm
errors	I-Algorithm
)	O
and/or	O
due	O
to	O
the	O
increasing	O
number	O
of	O
calculations	O
needed	O
(	O
see	O
examples	O
below	O
)	O
.	O
</s>
<s>
The	O
following	O
pseudocode	O
in	O
MATLAB	O
style	O
demonstrates	O
Richardson	B-Algorithm
extrapolation	I-Algorithm
to	O
help	O
solve	O
the	O
ODE	O
,	O
with	O
the	O
Trapezoidal	B-Algorithm
method	I-Algorithm
.	O
</s>
<s>
The	O
error	B-Algorithm
of	O
the	O
Trapezoidal	B-Algorithm
method	I-Algorithm
can	O
be	O
expressed	O
in	O
terms	O
of	O
odd	O
powers	O
so	O
that	O
the	O
error	B-Algorithm
over	O
multiple	O
steps	O
can	O
be	O
expressed	O
in	O
even	O
powers	O
;	O
this	O
leads	O
us	O
to	O
raise	O
to	O
the	O
second	O
power	O
and	O
to	O
take	O
powers	O
of	O
in	O
the	O
pseudocode	O
.	O
</s>
<s>
This	O
pseudocode	O
assumes	O
that	O
a	O
function	O
called	O
Trapezoidal(f, tStart, tEnd, h, y0 )	O
exists	O
which	O
attempts	O
to	O
compute	O
y(tEnd )	O
by	O
performing	O
the	O
trapezoidal	B-Algorithm
method	I-Algorithm
on	O
the	O
function	O
f	O
,	O
with	O
starting	O
point	O
y0	O
and	O
tStart	O
and	O
step	O
size	O
h	O
.	O
</s>
<s>
Note	O
that	O
starting	O
with	O
too	O
small	O
an	O
initial	O
step	O
size	O
can	O
potentially	O
introduce	O
error	B-Algorithm
into	O
the	O
final	O
solution	O
.	O
</s>
<s>
Although	O
there	O
are	O
methods	O
designed	O
to	O
help	O
pick	O
the	O
best	O
initial	O
step	O
size	O
,	O
one	O
option	O
is	O
to	O
start	O
with	O
a	O
large	O
step	O
size	O
and	O
then	O
to	O
allow	O
the	O
Richardson	B-Algorithm
extrapolation	I-Algorithm
to	O
reduce	O
the	O
step	O
size	O
each	O
iteration	O
until	O
the	O
error	B-Algorithm
reaches	O
the	O
desired	O
tolerance	O
.	O
</s>
