Calculus Quiz 15

Calculus Quiz 15
1. (5 pts)
a. ˆ
Use the Trapezoidal Rule with n = 10 to approximate
20
cos(πx)dx. Compare your result to the actual value.
0
Can you explain the discrepancy?
b. Let f be a polynomial with deg f = 3 or lower, which
defined on [a, b]. Show that the Simpson’s Rule gives the
ˆ b
exact value of
f (x)dx [Hint: it suffice to show the result
a
when there are two subintervals (n = 2), since for a larger
even number of subintervals the sum of exact estimates is
exact.]
Sol.
20 − 0
a. Let f (x) = cos(πx), and ∆x =
= 2. The by Trape10
zoidal Rule,
2
T10 = f (0) + 2 f (2) + f (4) + · · · + f (18) + f (20)
2
= cos 0 + 2 cos 2π + cos 4π + · · · + cos 18π + cos 20π
= 1 + 2 · 18 + 1 = 20
The actual value of the integral is
ˆ
ˆ 20
1 20π
cos udu, by letting u=πx⇒du=πdx
cos(πx)dx =
π 0
0
u=20π
1
1
= sin u
=
sin 20π − sin 0 = 0
π
π
u=0
The discrepancy is due to the fact that the function is
sampled only at points of the form 2n, where its value
f (2n) = cos 2nπ = 1.
b−a
.
b. Let f (x) = Ax3 + Bx2 + Cx + D and let ∆x = h =
2
Then we set x0 = a, x1 = a + h, x2 = b. Without loss
of generality, we may shift our graph of f to the left such
that x1 = 0, that is, by letting y = x − a − h and g(y) =
f (x − a − h), then
ˆ h
ˆ b
g(y)dy =
f (x)dx
−h
a
By Simpson’s Rule, we have that
h
g(−h) + 4g(0) + g(h)
3
h
=
− Ah3 + Bh2 − Ch + D + 4D + Ah3 + Bh2 + Ch + D
3
2 3
= Bh + 2Dh
3
S2 =
The exact value of integral is
ˆ
ˆ
b
ˆ
h
f (x)dx =
−h
a
=
h
Ay 3 + By 2 + Cy + D dy
g(y)dy =
−h
h
2
B 3 C 2
y + y + y + Dy = Bh3 + 2Dh
4
3
2
3
−h
A
4
which is coincide with S2 , the prove is complete.
2. (5 pts) The extension of factorial to non-integer
values.
ˆ ∞
By the fact that the improper integral
tx−1 e−t dt is conver0
gent for x > 0. We define it as a function of x, called the
Gamma function Γ(x).
a. Show that Γ(x + 1) = xΓ(x) for x > 0, in particular Γ(n +
1) = n! when n is ˆpositive integer.
√
3
∞
π
−x2
e dx =
b. Have known that
. Find Γ
.
2
2
0
Sol.
a. For x ≥ 1, then x − 1 ≥ 0 and thus
ˆ
ˆ
∞
b
t e dt = lim
tx e−t dt
b→∞
0
0
b ˆ b
h
i
= lim − tx e−t +
xtx−1 e−t dt ,
b→∞
0
0
ˆ b
x −b
= − lim b e + x lim
tx−1 e−t dt
Γ(x + 1) =
x −t
b→∞
= xΓ(x)
b→∞
0
by letting
u=tx ,
dv=e−t dt
du=xtx−1 dt,
v=−e−t
where the limit lim bx e−b = 0 is due L’Hospital’s Rule. In
b→∞
fact,
x −b
lim b e
b→∞
= lim xb
x−1 −b
b→∞
e
[x]
Y
= · · · = lim
(x − i) bx−[x]−1 e−b
b→∞
i=0
x(x − 1) · · · (x − [x])
= lim
=0
b→∞
b1+[x]−x eb
For 0 < x < 1, then x − 1 < 0 and hence tx−1 e−t is singular
at t = 0. Thus, similar to above argument,
ˆ b
ˆ b
b
h
i
x −t
x −t x−1 −t
Γ(x + 1) = lim lim
t e dt = lim lim − t e + x
t e dt
a→0 b→∞ a
a→0 b→∞
a
a
ˆ ∞
x −a
x −b
= lim lim a e − b e
+x
tx−1 e−t dt
a→0 b→∞
x −a
= lim a e
a→0
0
x −b
− lim b e
b→∞
+ xΓ(x) = xΓ(x)
In particular, for n ∈ N \ {0},
Γ(n + 1) = nΓ(n) = n(n − 1)Γ(n − 1) = · · ·
ˆ ∞
= n(n − 1) · · · 3 · 2 · Γ(1) = n!
e−t dt
0
ˆ b
e−t dt = n! lim 1 − e−b = n!.
= n! lim
b→∞
0
b→∞
b.
ˆ ∞
3 ˆ ∞ 3
1
−1
−t
=
t 2 e dt =
t 2 e−t dt
Γ
2
0
0
ˆ ∞
2
1
1
dt
=2
s2 e−s ds, by letting s=t 2 ⇒ds= 12 t− 2 dt= 2s
⇒2sds=dt
0
b 1 ˆ b
i
h 1
2
2
u=s,
dv=se−s ds
−s2 e−s ds , by letting
= 2 lim − se +
2
du=ds, v=− 12 e−s
b→∞
2
2 0
0
ˆ b
ˆ ∞
b
2
−b2
−s2
e ds = − lim b2 +
= − lim be + lim
e−s ds
b→∞
b→∞ 0
b→∞ e
0
√
√
1
π
π
= − lim
=
2 +
b→∞ 2beb
2
2