CAAM 336 · DIFFERENTIAL EQUATIONS Homework 7

Transcription

CAAM 336 · DIFFERENTIAL EQUATIONS Homework 7
CAAM 336 · DIFFERENTIAL EQUATIONS
Homework 7
Posted Wednesday 15 October, 2014. Due 5pm Wednesday 22 October, 2014.
Please write your name and residential college on your homework.
1. [50 points: 10 points each]
Let the inner product (·, ·) : C[0, 1] × C[0, 1] →
R be defined by
1
Z
(v, w) =
v(x)w(x) dx
0
and let the norm k · k : C[0, 1] →
R be defined by
kvk =
p
(v, v).
2
[0, 1] → C[0, 1] be defined by
Let the linear operator L : CD
Lv = −v 00
where
2
CD
[0, 1] = {w ∈ C 2 [0, 1] : w(0) = w(1) = 0}.
Recall that the operator L has eigenvalues
λ n = n2 π 2
with corresponding eigenfunctions
φn (x) =
√
2 sin(nπx)
for n = 1, 2, . . .. Let N be a positive integer, let f ∈ C[0, 1] be defined by f (x) = 8x2 (1 − x) and let u
be the solution to
Lu = f.
(a) Compute the best approximation fN to f from span {φ1 , . . . , φN } with respect to the norm k · k.
(b) Write down the infinite series solution to
Lu = f
that is obtained using the spectral method, i.e.
u(x) =
∞
X
αj φj (x)
j=1
where αj are coefficients to be specified. Given this above series, determine the best approximation uN to u from span {φ1 , . . . , φN } with respect to the norm k · k.
(c) Plot the approximations uN to u that you obtained using the spectral method for N = 1, 2, 3, 4, 5, 6.
(d) By shifting the data and then using an infinite series solution that you have obtained previously
in this question, obtain a series solution to the problem of finding u
˜ ∈ C 2 [0, 1] such that
−˜
u00 (x) = f (x),
0 < x < 1;
u
˜(0) = −
and
u
˜(1) =
1
4
1
.
4
(e) Let u
˜N be the series solution that you obtained in part (d) but with ∞ replaced by N , i.e.
u
˜N (x) =
N
X
j=1
Plot u
˜N for N = 1, 2, 3, 4, 5, 6.
αj φj (x)
2. [50 points: 10 points each]
All parts of this question should be done by hand.
Let the inner product (·, ·) : C[0, 1] × C[0, 1] →
R be defined by
Z
1
(v, w) =
v(x)w(x) dx
0
and let the norm k · k : C[0, 1] →
R be defined by
kvk =
p
(v, v).
Let the linear operator L : S → C[0, 1] be defined by
Lv = −v 00
where
S = {w ∈ C 2 [0, 1] : w0 (0) = w(1) = 0}.
Note that S is a subspace of C[0, 1] and that
(Lv, w) = (v, Lw) for all v, w ∈ S.
Let N be a positive integer and let f ∈ C[0, 1] be defined by
1 − 2x if x ∈ 0, 21 ;
f (x) =
0 otherwise.
(a) The operator L has eigenvalues λn with corresponding eigenfunctions
√
2n − 1
πx
φn (x) = 2 cos
2
for n = 1, 2, . . .. Note that, for m, n = 1, 2, . . .,
1
(φm , φn ) =
0
if m = n;
if m =
6 n.
Obtain a formula for the eigenvalues λn for n = 1, 2, . . ..
(b) Compute fN , the best approximation to f from span {φ1 , . . . , φN } with respect to the norm k · k.
Plot fN for N = 1, 2, 3, 4, 5, 6.
(c) Use the spectral method to obtain a series solution to the problem of finding u
˜ ∈ C 2 [0, 1] such
that
−˜
u00 (x) = f (x), 0 < x < 1
and
u
˜0 (0) = u
˜(1) = 0.
(d) By shifting the data, obtain an infinite series solution to the problem of finding u ∈ C 2 [0, 1] such
that
−u00 (x) = f (x), 0 < x < 1
and
u0 (0) = u(1) = 1.
(e) Let u
˜N be the series solution that you obtained in part (d) but with ∞ replaced by N , i.e.
u
˜N (x) =
N
X
j=1
Plot u
˜N for N = 1, 2, 3, 4, 5, 6.
αj φj (x)