SOLUTION TO PROBLEM SET 5, FYS3140
Problem 5.1 (Residue theory)
a) 14.7.17
Let us substitute x ! z and sin x ! eiz and start by evaluating the integral
in the upper half plane,
Z 1
I
x sin xdx
zeiz dz
!
2
2
z + 4z + 5
1 x + 4x + 5
I
I
iz
ze dz
zeiz dz
=
2
z + 4z + 5
(z + (i + 2))(z (i 2))
z=i
2 is the only pole in the upper half-plane, and its residue becomes
R(z = i
2) =
lim (z
z!(i 2)
2))
zeiz
(z + (i + 2))(z
(i
2))
2)ei(i 2)
(i
=
(i
2i
2)ei(i 2)
2i
( 2 cos 2 + sin 2) + i(cos 2 + 2 sin 2)
2ie
(i
=
=
and
I
zeiz dz
(z + (i + 2))(z (i
⇢
( 2 cos 2 + sin 2) + i(cos 2 + 2 sin 2)
2ie
( 2 cos 2 + sin 2) + i(cos 2 + 2 sin 2)
= ⇡
e
= 2⇡i ·
2))
Now the complex integral splits into integral along x-axit and along the
semicircle. Along x-axis, z ! x and on the semicircle z ! ⇢ei✓
I
zeiz dz
=
z 2 + 4z + 5
Z
⇢
⇢
xeix dx
+
x2 + 4x + 5
taking the limit ⇢ ! 1,
=
Z
1
1
xeix dx
+
x2 + 4x + 5
Z
1
⇡
0
Z
⇡
0
⇢eiz ⇢iei✓ d✓
⇢2 ei2✓ + 4⇢ei✓ + 5
eiz ⇢2 iei✓ d✓
⇢2 ei2✓ + 4⇢ei✓ + 5
The second part of RHS is evaluated as follows,
Z ⇡
Z ⇡
eiz ⇢2 iei✓ d✓
lim
=
lim
ei(⇢ cos ✓+i⇢ sin ✓) ie i✓ d✓
⇢!1 0 ⇢2 ei2✓ + 4⇢ei✓ + 5
⇢!1 0
Z ⇡
= lim i
ei( ✓+⇢ cos ✓) e ⇢ sin ✓ d✓
⇢!1
0
= 0
where we know that |eiy | = 1, and e ⇢ sin ✓ vanishes as ⇢ ! 1 (sin ✓ is
positive in upper half plane). You can also apply Jordan’s lemma. Therefore,
Z
1
1
x2
xeix dx
( 2 cos 2 + sin 2) + i(cos 2 + 2 sin 2)
=⇡
+ 4x + 5
e
Equating the real and imaginary parts of the two sides, we get
Z
1
1
xeix dx
2
x + 4x + 5
Z 1
x cos xdx
x sin xdx
+
i
2
2
1 x + 4x + 5
1 x + 4x + 5
( 2 cos 2 + sin 2) + i(cos 2 + 2 sin 2)
= ⇡
e
Z 1
x sin xdx
⇡
)
= (cos 2 + 2 sin 2)
2
e
1 x + 4x + 5
=
Z
1
b) 14.7.24
We use same procedure here as the previous problem. Making substitutions
x ! z and sin x ! eiz , we start by evaluating the following complex integral
in the upper half-plane. i.e
Z 1
I
x sin ⇡x
zei⇡z dz
dx
!
2
x
1 z2
1 1
here the poles z = 1 and z = 1 are at the boundary. Residue method is not
generally correct when multiple poles are present at the boundary. Thus, I
will evaluate the integral directly by excluding the poles from our region by
creating small circles of radius r about each pole.
I
zei⇡z dz
=0
(⇤)
1 z2
Now we let the small circles to vanish by taking the limit r ! 0.
For semicircle around z = 1 the following substitutions will be made: z =
1+rei✓ ; dz = riei✓ d✓ = i(z 1)d✓. When r ! 0; then z ! 1; and ei⇡z ! 1.
the integral around the small semicircle about z = 1 is thus
2
lim
Z
r!0 C 0
zei⇡z dz
(1 z)(1 + z)
Z
i
d✓
2
C
Z 0
i
=
d✓
⇡ 2
i⇡
=
2
=
0
similarly, for semicircle around z = 1, we make substitutions: z = 1 +
rei✓ ; dz = riei✓ d✓ = i(z + 1)d✓. When r ! 0; then z ! 1; and ei⇡z ! 1,
hence
Z
zei⇡z dz
i⇡
lim
=
r!0 C 0 (1
z)(1 + z)
2
Now we resolve the integral in eqn (*) into six components, i.e. along xaxis; along the two small circles of radius r; and along the larger semicircle
of radius ⇢. i.e.
I
zei⇡z dz
1
z2
=
+
+
zZ
I
|
I
|
= 0
1 r
⇢
0
C1
xei⇡x dx
1
x2
+
Z
1
}|
{
Z ⇢
xei⇡x dx
xei⇡x dx
+
x2
x2
1+r 1
1+r 1
1 r
I
zei⇡z dz
zei⇡z dz
+
0
1 z2
z2
C 1 1
{z
}
2
0
Cbig
zei⇡z dz
1 z2
{z
}
3
R1
when we take the limit as r ! 0 and ⇢ ! 1, integral (1) gives
1 ();
integral (2) is i⇡; and integral (3) vanishes by the Jordan’s lemma or the
technique we used in the previous problem. Thus,
I
Z 1
zei⇡z dz
xei⇡x dx
=
i⇡ = 0
1 z2
x2
1 1
)
Z
1
1
xei⇡x dx
= i⇡
1 x2
by equating real and imaginary parts of the two sides, we get
Z 1
x sin ⇡x
dx = ⇡
x2
1 1
3
c)
The poles are z1 =
1 and z2 = 2, both are inside |z| = 3, and both are simple poles. We find
˛
cos(z 1) dz
= 2⇡i (R( 1) + R(2))
(z + 1)(z 2)
✓
◆
cos( 2) cos(1)
= 2⇡i
+
3
3
2⇡i
=
(cos 1 cos 2)
3
(1)
d)
The poles are at z1 = 1 and z2 =
1, which is clear from rewriting the integral as
˛
e z dz
(z + 1)2 (z 1)2
(2)
The poles are of second order, so
d
z!1 dz
R(1) = lim
✓
e z
(z + 1)2
and
R( 1) = lim
z!
so
˛
d
1 dz
✓
◆
=
e
z
1)2
(z
e
1
· 22 2e
24
◆
=
e 1 · 22
1
·2
=
e
2
2e1 · ( 2)
24
e z dz
1
= 2⇡i ·
=
(z + 1)2 (z 1)2
2e
i⇡
e
1
=
=0
1
2e
(3)
(4)
(5)
Problem 5.2
a)
Solve
dy + (2xy
xe
x2
This is equivalent to
y 0 + 2xy = xe
we identify P (x) = 2x and Q(x) = xe
x2
(6)
)dx = 0
x2
(7)
. We have
µ(x) = e
´
P (x) dx
=e
´
2x dx
= ex
2
(8)
which gives us the new differential equation
0
(yµ(x)) = µ(x)xe
with the solution
y(x) =
✓
x2
◆
1 2
x +C e
2
1
=x
x2
(9)
(10)
b)
Solve
y 0 + y cos x = sin 2x
(11)
We identify P (x) = cos x and Q(x) = sin 2x. We find
µ(x) = e
´
P (x) dx
=e
´
cos x dx
= esin x
(12)
The new differential equation reads
0
(yµ(x)) = µ(x) sin 2x = esin x sin 2x = 2esin x sin x cos x
By integrating over x the LHS becomes y(x)µ(x). The RHS becomes
ˆ
ˆ
esin x sin 2x dx = esin x 2 sin x cos x dx
ˆ
= 2 ueu du
= 2esin x sin x
= 2e
sin x
(sin x
and therefore the solution is
y(x) = 2 sin x
2 + Ce
(13)
(14)
2esin x + C
1) + C
sin x
(15)
c)
Solve
y 0 cos x + y = cos2 x
(16)
In canonical form it is
1
y = cos x
cos x
and we identify P (x) = 1/ cos x and Q(x) = cos x. The integrating factor is
y0 +
µ(x) = e
´
P (x)dx
=e
´
1/ cos x dx
(17)
(18)
The integral is
ˆ
1
dx =
cos x
1
du
cos x cos x
ˆ
1
=
du
cos2 x
ˆ
1
=
du
1 u2
ˆ
1
1
1
=
+
du
2
1+u 1 u
1
1+u
= ln
2
1 u
1
1 + sin x
= ln
2
1 sin x
ˆ
2
(19)
where we have used the change of variable u = sin x and done partial fraction decomposition,
✓
◆
1
1
1
1
=
+
1 u2
2 1+u 1 u
Now that we have the integral, the integrating factor becomes
✓
◆1/2
´
1 + sin x
µ(x) = e P (x)dx =
1 sin x
(20)
(21)
since both numerator and denominator are positive semidefinite. Finally, the differential equation
becomes
ˆ
y(x)µ(x) = µ(x)R(x) dx
◆1/2
1 + sin x
cos x dx
1 sin x
◆1/2
ˆ ✓
1+u
=
du
1 u
ˆ
1
= (1 + u) p
du
1 u2
p
We do integration by parts with v = (1 + u), w0 = 1/ 1 u2 which gives
ˆ
y(x)µ(x) = (1 + u) arcsin(u)
arcsin(u) du
p
= (1 + u) arcsin(u)
1 u2 u · arcsin(u) + C
p
= (1 + sin x) arcsin(sin x)
1 sin2 x sin x · arcsin(sin x) + C
=
ˆ ✓
(22)
(23)
| cos x| + C
= arcsin(sin x)
Note that we cannot replace arcsin(sin x) with x here! The function f (x) = arcsin(sin x) behaves as x
from x = 0 to x = ⇡/2, like x from x = ⇡/2 to x = ⇡ etc. It has the property that
d
cos x
(arcsin(sin x)) =
dz
| cos x|
Finally the solution is
✓
◆1/2
1 sin x
y(x) =
(arcsin(sin x)
1 + sin x
| cos x| + C) =
1 sin x
(arcsin(sin x)
| cos x|
(24)
| cos x| + C)
(25)
Note that it is not defined for x = ⇡/2 + k⇡, because the differential equation in canonical form was
not defined at those points. The original differential equation demands that
y(⇡/2 + k⇡) = 0
(26)
4y 00 + 12y 0 + 9y = 0
(27)
Problem 5.3
a)
Solve the differential equation
3
The auxilliary equation is
4
2
(28)
+ 12 + 9 = 0
which has two coinciding solutions
1
=
The solution is therefore
y(x) = C1 e
2
3
2
=
3x/3
+ C2 xe
(29)
3x/2
(30)
b)
The auxilliary equation is
2
(31)
4 + 13 = 0
which has complex solutions
1
= 2 + 3i
2
=2
3i
(32)
The solution is therefore
y(x) = e2x C1 e3ix + C2 e
3ix
= e2x (A cos(3x) + B sin(3x))
4
(33)
© Copyright 2026 Paperzz