MA1032 - Assignment 2

MA1032 - Assignment 2
Lecturer: Dr. Janitha Gunatilake
December 1, 2014
1. Consider the function g(x) = e−x .
(a) Prove that g is a contraction on G = [ln 1.1, ln 3].
(b) Prove that g : G → G.
(c) Show that g(x) has an unique fixed point z ∈ G.
(d) Prove that xn+1 = g(xn ) converges to the unique fixed point z ∈ G for any x0 ∈ G.
n
, x = limn→∞ xn and en = x−xn . Here [an , bn ] with n ≥ 0 denotes the successive
2. Let xn = an +b
2
intervals that arise in the bisection method when it is applied to a continuous function f .
(a) Show that |en | ≤ 2−(n+1) (b0 − a0 ).
(b) Show that |en | = O(2−n ) as n → ∞.
(c) Is it true that |e0 | ≥ |e1 | ≥ . . . ? Explain.
(d) Show that |xn − xn+1 | = 2−n−2 (b0 − a0 ).
(e) Show that for all n and m, am ≤ bn .
(f) Show that x is the unique element in ∩∞
n=0 [an , bn ].
(g) Show that for all n, [an , bn ] ⊃ [an+1 , bn+1 ].
3. The Van der Waals equation of state for a gas is given by
(
2 )
N
p+a
(V − N b) = kN T,
V
where V is the volume occupied by the gas, T is the temperature, p is the pressure, N is the
number of molecules contained and k is the Boltzmann constant. a and b are coefficients that
depend on the specific gas.
For carbon dioxide (CO2 ) a = 0.401P am6 , b = 42.7 × 10−6 m3 . Use bisection method to find
the volume occupied by 1000 molecules of CO2 at a temperature T = 300K and a pressure p =
3.5×107 P a, with a tolerance of 10−12 . The Boltzmann constant is k = 1.3806503×10−23 JK −1 .
You may use the MATLAB code provided.
1
MA1032 - Assignment 2
α
L
l1
γ
l2
Figure 1: A rod sliding in a corridor.
4. (a) Implement Newton’s method in MATLAB.
(b) A corridor has the form indicated in the Figure 1. The maximum length L of a rod that
can pass from one extreme to the other sliding on the ground is given by
L=
l2
l1
+
sin(π − γ − α) sin α
where α is the solution of the nonlinear equation
l2
cos(π − γ − α)
cos α
− l1 2 = 0.
2
sin (π − γ − α)
sin α
Compute α by Newton’s method when l2 = 10, l1 = 8 and γ = 3π/5. Use the MATLAB
code in (a) with a tolerance 10−6 .
Due date: December 12, 2014
Page 2