


Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Community
Ask the community for help and clear up your study doubts
Discover the best universities in your country according to Docsity users
Free resources
Download our free guides on studying techniques, anxiety management strategies, and thesis advice from Docsity tutors
Material Type: Lab; Professor: McCray; Class: Calculus/Precalculus II; Subject: Mathematics; University: Illinois Institute of Technology; Term: Unknown 1989;
Typology: Lab Reports
1 / 4
This page cannot be seen from the preview
Don't miss anything!
In class we defined the definite integral of the function f (x) on the interval [ a, b ] as
d
a
b
k = 1
n
f ( c (^) k )( xk − x (^) k − 1 )
where a = x 0 < x 1 < x 2 < ... < x (^) n − 1 < x (^) n = b is a partition of [ a, b ] , x (^) k − 1 < ck < xk for k =
1...n, and the limit is taken as n →∞ and the lengths of the subintervals [ x (^) k − 1 , x (^) k ]
determined by the partition go to 0.
The easiest and best way to evaluate the definite integral is by using the Fundamental
Theorem of Calculus , which says that
d
a
b
f ( x ) x = F (b) - F (a)
where F is any antiderivative of f ( i.e., F '(x) = f (x) ).
In this laboratory we will verify the Fundamental Theorem by first using MAPLE to
evaluate the limit of the sum directly and then by finding F and computing F (b) - F (a).
Let f (x) = x cos(πx) , 0 < x < 2π.
We will use partitions in which the xk 's are equally spaced and each c (^) k is the midpoint of
[ x (^) k − 1 , xk ].
First we illustrate the approximating rectangles using a partition with 20 points,
followed by computing the limit of the Riemann sum.
> with(student):
> f:=x->xcos(Pix);**
f := x → x cos( π x )
> middlebox(f(x),x=0..2Pi,20);*
The corresponding approximating sum is
> ms20:=middlesum(f(x),x=0..2Pi,20);*
ms20 :=
π
i = 0
19
i + ⎟⎟
π
cos ⎟
π
i + ⎟⎟
or
> mv20:=value(ms);
mv20 := ms
> evalf(mv20);
ms
If we use a partition with n points an approximating sum using middle points as
sample points is
> msn:=middlesum(f(x),x=0..2Pi,n);*
> F:=x->((cos(Pix)+Pixsin(Pix))/(Pi^2));**
F := x →
cos( π x )+π x sin( π x )
π
2
You should differentiate F (x) "by hand" to check that the derivative is actually f
(x)---non-computer methods for finding antiderivatives of functions like f (x) = x cos(π
x) will be developed in Math 152.
By the Fundamental Theorem, d
0
2 π
x cos( π x ) x = F (2π) - F (0).
> JFTC:=F(2Pi)-F(0);*
cos 2( π )+
2 2 π
2 sin 2( π )
2
π
2
π
2
This looks different from the answer obtained above, but the two are actually
equal.
Indeed,
> evalf(JFTC);
evalf(2(2sin(Pi^2)cos(Pi^2)Pi^2-1+cos(Pi^2)^2)/(Pi^**
));
This apparent differance is due to round off errors.
If we increase the number of digits and repeat the computations the agreement is closer:
> Digits:=15;
Digits := 15
The fifteen digit value from computing the limit of the Riemann sum is:
> evalf(2(2sin(Pi^2)cos(Pi^2)Pi^2-1+cos(Pi^2)^2)/(Pi^**
));
The fifteen digit value from the Fundamental Theorem of Calculus is:
> evalf((cos(2Pi^2)+2Pi^2sin(2Pi^2))/(Pi^2)-1/(Pi^2));**