1. Compute the value of pi using the following series
src="http://www.facstaff.bucknell.edu/maneval/help211/images/prgex1.jpg">
How many terms are needed to obtain an accuracy of
1e-12? How accurate is
the sum of 100 terms of this
series?
2. The Fibonacci numbers are comuted according to the following
relation:
Fn = Fn-1 + Fn-2
with
F0 = F1 = 1.
a. Compute the first 10
Fibonacci numbers.
b. For the first 50 Fibonacci numbers,
compute the ratio
Fn / Fn-1
It is claimed that this ratio approaches the
value of the golden mean
( (1 + sqrt(5))/2
). What do your results show?
3. The
Legendre polynomials (Pn(x)) are defined by the following recurrance
relation
(n+1) Pn+1(x) - (2n+1) Pn(x) + n Pn-1(x) =
0
with P0(x) = 1, P1(x) = x and
P2(x) = (3×2 - 1)/2. Compute the next three
Legendre polynomials and plot all 6 over the interval
[-1,1].
href="http://www.facstaff.bucknell.edu/maneval/help211/progexercises.html" TARGET=_BLANK>CONTINUA
Giuseppe Ciaburro-998









Anteprima del commento