Sie sind auf Seite 1von 6

MAT 3310 (2009-2010, Second Term)

Suggested Solution for Midterm Examination

1. (a) (5 marks) Obviously, det(L) = 1. Because every elementary permutation changes the
sign of det(P ), and in the end det(P ) = (1)k .
It is straight forward to get det(A) = (1)k det(U ).
(b) (12 marks) Any possible answer. One of the answers:

0 1 0 0 0
1 0 0 0 0

P =
0 0 0 1 0
0 0 0 0 1
0 0 1 0 0
(2 marks)

L=

1
3
0
2
1

0 0 0
1 0 0
1 1 0
0 2 1
0 3 0

0
0
0
0
1

(5 marks)

U =

5
0
0
0
0

0
1
0
0
0

1 1
0
2 2 0
3 0
1
0 1 4
0 0
3

(5 marks)
(c) (3 marks) Show your steps.

~x =

1
2
3
4
5

2. (a) (4 marks)
The problem is to minimize:
f (x1 , x2 , x3 , x4 ) = (x1 1)2 + (x2 1)2 + x23 + x24
(2 marks)
subject to

(
2x1 2x2 + 2x3 + x4 + 1 = 0
x21 2x1 x2 + x22 x23 x4 1 = 0

(1)

(2)

(2 marks)
(b) (6 marks) We reformulate this problem into an unconstrained problem.
The constraints are:
(
2x3 = 2x1 2x2 + x4 + 1
x23 = x21 2x1 x2 + x22 x4 1

(3)

Constraint 1 plus Constraint 2 and add 1 on both sides,


(x3 1)2 = (x1 x2 + 1)2
x3 1 = (x1 x2 + 1)

(4)
(5)

(2 marks)
case 1: x3 1 = x1 x2 + 1
Substitute x3 = x1 x2 + 2 into Constraint 2,
x4 = (x1 x2 )2 (x1 x2 + 2)2 1 = 5 4(x1 x2 )

(6)

then the objective function can be reformulated as:


g1 (x1 , x2 ) = (x1 1)2 + (x2 1)2 + (x1 x2 + 2)2 + (5 + 4x1 4x2 )2

(7)

and with no constraints on x1 , x2 .


(2 marks)
case 2: x3 1 = x1 + x2 1
i.e. x3 = x1 + x2 , Substitute it into Constraint 2,
x4 = (x1 x2 )2 (x2 x1 )2 1 = 1

(8)

Now the objective function becomes


g2 (x1 , x2 ) = (x1 1)2 + (x2 1)2 + (x2 x1 )2 + (1)2

(9)

(2 marks)
(c) (4 marks)
case 1: Now we find the stationary point of function g1 .
Take the first derivative on x1 and x2 , and set them to zero,
(
g1
x1 = 36x1 34x2 + 42 = 0
g1
x2 = 36x2 34x1 46 = 0
2

(10)

57
26
Solve this system, we get x1 = 13
35 , x2 = 35 , then x3 = x1 x2 + 2 = 35 , x4 =
1
57 26 1
5 4(x1 x2 ) = 35
, and the stationary point is ( 13
35 , 35 , 35 , 35 ).
(2 marks)
case 2: For function g2 (x1 , x2 ) = (x1 1)2 + (x2 1)2 + (x2 x1 )2 + (1)2 , take the
first derivative on x1 and x2 , and set them to zero,
(
g2
x1 = 4x1 2x2 2 = 0
(11)
g2
x2 = 4x2 2x1 2 = 0

Solve this system, we get x1 = 1, x2 = 1, then x3 = x2 x1 = 0, x4 = 1, and the


stationary point is (1, 1, 0, 1).
(2 marks)
(d) (6 marks) From (b) we know the objective function f can be reformulated as functions
of x1 and x2 , we prove in both cases the Hessian matrix is positive definite.
case 1:

36 34
H=
34 36
the eigenvalues of H are 1 = 70, 2 = 2, and H is positive definite.
So g1 (x1 , x2 ) has unique
local minimal solution at its stationary point, the distance

1645
13 57 26 1
is f ( 35 , 35 , 35 , 35 ) = 35 .
Or another explanation of case 1: one has x1 , x2 , g1 (x1 , x2 ) (x1 1)2 + (x2 1)2
according to (7), g1 (x1 , x2 ) is continuous over R2 , and goes to when k(x1 , x2 )k goes
13 57 26 1
to , thus g1 (x1 , x2 ) attains its minimum at the stationary point ( 35
, 35 , 35 , 35 ).
(2 marks)
case 2:

4 2
H=
2 4
the eigenvalues of H are 1 = 2, 2 = 6, and H is positive definite.
So g2 (x1 , x2 ) has unique local minimal solution at its stationary point, the distance
is f (1, 1, 0, 1) = 1.
Or another explanation of case 2: one has x1 , x2 , g2 (x1 , x2 ) 1 according to (9),
thus g2 (x1 , x2 ) attains its minimum at (1, 1, 0, 1).
(2 marks)
In conclusion, both functions have unique local minimal solution at its stationary
point. (1, 1, 0, 1) has the smaller value f of the two stationary points, and it is
minimal globally.
(2 marks)
3. (a) (5 marks)

K=

c1 + c2
c2
0
... ... ...
0
c2
c2 + c3
c3
0 ... ...
0
0
c3
c3 + c4 c4 0
...
0
...
...
...
... ... ...
cn
0
...
...
... 0 cn cn + cn+1
3

(b) (10 marks)


Obviously, K t = K. (2 marks)

K~v =

(c1 + c2 )v1 c2 v2
c2 v1 + (c2 + c3 )v2 c3 v3
c3 v2 + (c3 + c4 )v3 c4 v4
...
cn vn1 + (cn + cn+1 )vn

(3 marks, can be omitted)


~v t K~v
P
= (c1 + c2 )v12 c2 v1 v2 + n1
i=2 vi [ci vi1 + (ci + ci+1 )vi ci+1 vi+1 ]
2
cP
n vn1 vn + (cn + cn+1 )v
Pnn (2 marks)
2
= ni=1 (cP
i + ci+1 )vi 2
i=1 ci+1 vi vi+1
= c1 v12 + ni=2 ci (vi1 vi )2 + cn+1 vn2 (3 marks)
0 Now, ~v t K~v = 0 implies v1 = vn = 0 and vi1 = vi for 1 i n, or ~v = 0. (2
marks)
Thus, K is SPD.
(c) (10 marks)
Given ~v , such that K~v 0, we have
(c1 + c2 )v1 c2 v2 0
ci vi1 + (ci + ci+1 )vi ci+1 vi+1 0, where i = 2, ..., n 1
cn vn1 + (cn + cn+1 )vn 0 (3 marks)
Let vk = mini vi
If vk = v1 , c1 v1 c2 (v2 v1 ) 0 v1 0 vi 0
If vk = vn , cn+1 vn cn (vn1 vn ) 0 vn 0 vi 0
If vk = vi , ci (vi vi1 ) + ci+1 (vi vi+1 ) 0 vi = vi1 = vi+1 i vi = 0 (5 marks)
By Lemma 3.2, K is monotone. (2 marks)
(d) f~ 0 by definition,
K~u = f~ ~u = K 1 f~
K is monotone all entries of K 1 0, and all entries f~ 0 ~u 0
all masses can only move in the downward direction, or remain stable. (5 marks)
4. (a) (5 marks) To get the variational formulation, we multiply both sides of the equation
by the test function v with v(0) = v(1) = 0 (1 mark), and integrate from 0 to 1,
Z
0

(cu0 )0 vdx +

quvdx =
0

f vdx. (1mark)
0

(12)

Then integrate by part, and apply the condition v(0) = v(1) = 0,


Z

cu0 v 0 dx +

quvdx =
0

f vdx. (2marks)

(13)

So its variational formulation is:(1 mark)


Find u with u(0) = 1 and u(1) = 2 such that
Z

0 0

cu v dx +
0

quvdx =
0

f vdx,

(14)

v with v(0) = v(1) = 0.


(b) (5 marks) From the integral equation, we know u has a first derivative on ]0, 1[,
moreover u has values at 0 and 1, so u must be a continuous function in [0, 1], and
the limit from left hand side u ( 21 ) should equal the limit from the right hand side
u+ ( 12 ).
(c) (10 marks) We reformulate the variational formulation in (a) by integration by parts
after splitting the first integral in two parts,
Z

1
2

1
2

Z
(cu0 )0 vdx

Z
cu0 v 0 dx +

1
1
2

1
1
2

Z
cu0+ v 0 dx +
Z

(cu0+ )0 vdx +

quvdx =
0

f vdx

(15)

quvdx + (cu0 v)|02

Z
+ (cu0+ v)|11
2

f vdx (16)
0

(2 marks)
Z

Z
(cu ) vdx+

0 0

quvdx

1
1
f vdx+(cu0 v)( )(cu0 v)(0)+(cu0+ v)(1)(cu0+ v)( ) = 0
2
2
(17)

(2 marks)
Z
0

1
1
((cu0 )0 + qu f )vdx = (cu0+ v)( ) (cu0 v)( )
2
2

(18)

(2 marks)
The differential equation (cu0 )0 + qu f = 0 makes the integral in the first term
zero, so



1 du 1
du+ 1
1
2
v
= 0 (2marks)
(19)
2 dx 2
dx 2
2


1 du 1
du+ 1
=2
(2marks)
(20)
2 dx 2
dx 2
thus we proved the first derivative condition at x = 12 .

(d) (5 marks) Combining the conditions found in (b),(c), (u , u+ ) solves the following
problem, (1 mark for each equation)

12 (u )00 (x) + q(x)u (x) = f (x), 0 < x < 21

1
00

2(u+ ) (x) + q(x)u+ (x) = f (x), 2 < x < 1


(21)
u (0) = 1, u+ (1) = 2

1
1

u 2 = u+ 2

1 du 1
du+ 1
2 dx ( 2 ) = 2 dx ( 2 ).
(e) (5 marks) This new reformulation gives the interface condition by splitting the problem into two smaller subproblems of u(x) between the interval [0, 12 ) and ( 21 , 1]. It
helps to design efficient numerical methods.

Das könnte Ihnen auch gefallen