Dror Bar-Natan: Classes: 2002-03: Math 157 - Analysis I: (208) Next: Homework Assignment 19
Previous: Term Exam 3

Solution of Term Exam 3

this document in PDF: Solution.pdf

Problem 1. Suppose that $ f$ is nondecreasing on $ [a,b]$. Notice that $ f$ is automatically bounded on $ [a,b]$, because $ f(a)\leq
f(x)\leq f(b)$ for any $ x$ in $ [a,b]$.

  1. If $ P=\{t_0,\dots,t_n\}$ is a partition of $ [a,b]$, write formulas for $ L(f,P)$ and $ U(f,P)$ in as simple terms as possible.
  2. Suppose that $ t_i-t_{i-1}=\delta$ for each $ i$. Show that $ U(f,P)-L(f,P)=\delta[f(b)-f(a)]$.
  3. Prove that $ f$ is integrable.

Solution. Notice that as $ f$ is nondecreasing, $ m_i:=\inf_{[t_{i-1},t_i]}f(x)=f(t_{i-1})$ and $ M_i:=\inf_{[t_{i-1},t_i]}f(x)=f(t_i)$. Hence,

  1. The upper and lower sums are given by

    $\displaystyle L(f,P) := \sum_{i=1}^n(t_i-t_{i-1})m_i
= \sum_{i=1}^n(t_i-t_{i-1})f(t_{i-1}),
$

    $\displaystyle U(f,P) := \sum_{i=1}^n(t_i-t_{i-1})M_i
= \sum_{i=1}^n(t_i-t_{i-1})f(t_i).
$

  2. If $ t_i-t_{i-1}=\delta$ then $ L(f,P)=\sum_{i=1}^n(t_i-t_{i-1})f(t_{i-1})=\sum_{i=1}^n\delta f(t_{i-1})$ and likewise $ L(f,P)=\sum_{i=1}^n\delta f(t_i)$. Hence $ U(f,P)-L(f,P)=\delta\sum_{i=1}^n(f(t_i)-f(t_{i-1}))$. By telescopic summation, the last sum is $ f(t_n)-f(t_0)=f(b)-f(a)$.
  3. Setting $ t_i=a+i\frac{b-a}{n}$ we get partitions with $ \delta=t_i-t_{i-1}=\frac{b-a}{n}$. This can be made arbitrariry small, and hence $ U(f,P)-L(f,P)=\frac{b-a}{n}[f(b)-f(a)]$ can be made arbitrarily small, hence $ f$ is integrable.

Problem 2. In each of the following, $ f$ is a continuous function on $ [0,1]$.

  1. Show that

    $\displaystyle \int_0^\pi f(\sin x)\cos x dx=0. $

  2. Characterize the functions $ f$ that have the property that

    $\displaystyle \int_0^xf(t) dt=\int_x^1 f(t) dt$   for all $ x\in[0,1]$.$\displaystyle $

Solution.

  1. If $ F$ is a primitive of $ f$, i.e., $ F'=f$, then $ (F(\sin x))'=F'(\sin x)\cos x=f(\sin x)\cos x$. Hence using the second fundamental theorem of calculus,

    $\displaystyle \int_0^\pi f(\sin x)\cos x dx$ $\displaystyle = \int_0^\pi(F(\sin x))' = \left.F(\sin x)\right\vert _0^\pi$    
      $\displaystyle = F(\sin\pi)-F(\sin 0)=F(0)-F(0)=0.$    

  2. Differentiate both sides of the equality $ \int_0^xf(t) dt=\int_x^1 f(t) dt$ using the first fundamental theorem of calculus and get that $ f(x)=-f(x)$ and thus that $ f(x)=0$ for all $ x$.

Problem 3.

  1. Prove that if two functions $ f_1$ and $ f_2$ both satisfy the differential equation $ f''+f=0$ and if they have the same value and the same first derivative at 0, then they are equal.
  2. Use the above to show that $ \sin(\frac{\pi}{2}+x)=\cos x$ for all $ x$. (Do not use the formula for the $ \sin$ of a sum!)

Solution.

  1. Set $ f=f_1-f_2$. As $ f''=f_1''-f_2''$, it follows that $ f''+f=0$ and clearly $ f(0)=f'(0)=0$. Now set $ h(x)=f(x)^2+f'(x)^2$ and calculate $ h'=2ff'+2f'f''=2ff'-2f'f=0$. Hence $ h$ is a constant. But $ h(0)=f(0)^2+f'(0)^2=0^2+0^2=0$ hence $ h$ is the constant 0. But as the two terms composing $ h(x)$ a non-negative, this forces each of them to be 0, and in particular $ f^2=0$ and thus $ f_1-f_2=f=0$.
  2. Set $ f_1(x)=\sin(\frac{\pi}{2}+x)$ and $ f_2(x)=\cos x$. Then $ f_1'(x)=\cos(\frac{\pi}{2}+x)$, $ f_1''(x)=-\sin(\frac{\pi}{2}+x)$, $ f_2'(x)=-\sin x$ and $ f_2''(x)=-\cos x$. Hence $ f_1$ and $ f_2$ both satisfy the differential equation $ f''+f=0$. In addition, $ f_1(0)=\sin\frac{\pi}{2}=1=\cos 0=f_2(0)$ and $ f_1'(x)=\cos\frac{\pi}{2}=0=-\sin 0=f_2'(0)$. Hence the requirements for the theorem of the previous part of this problem are met, and hence its conslusion is satisfied. So $ f_1=f_2$ or $ \sin(\frac{\pi}{2}+x)=\cos x$.

Problem 4.

  1. Compute

    $\displaystyle \lim_{x\to 0}\frac{e^x-(1+x)}{x^2}. $

  2. Use your result to estimate the difference between $ e^{0.1}$ and $ 1.1$. Warning: a 10 digit answer obtained with your calculator may contribute negatively to your grade. You shouldn't use any calculating device and your derivation of the answer should be simple enough that it be clear that you didn't need any machine help.

Solution.

  1. Using L'Hôpital's rule twice, we get

    $\displaystyle \lim_{x\to 0}\frac{e^x-(1+x)}{x^2}
= \lim_{x\to 0}\frac{e^x-1}{2x}
= \lim_{x\to 0}\frac{e^x}{2} = \frac{e^0}{2} = \frac12.
$

  2. From the above we get that $ \frac{e^x-(1+x)}{x^2}$ is approximately $ \frac12$ if $ x$ is small. Hoping that $ x=0.1$ is small enough, we find that $ \frac{e^{0.1}-(1+0.1)}{0.1^2}\sim\frac12$, meaning that $ e^{0.1}-1.1\sim\frac{0.1^2}{2}=0.005$.

Problem 5. Evaluate the following integrals in terms of elementary functions:

  1. $ \displaystyle \int x^2\cos x dx$
  2. $ \displaystyle \int \frac{dx}{x^2-3x+2}$         (cancelled)
  3. $ \displaystyle \int_0^1\frac{dx}{1+e^x}$
  4. $ \displaystyle \int_0^\infty xe^{-x^2} dx$

Solution.

  1. We integrate by parts twice:

    $ \displaystyle \int x^2\cos x dx$ $\displaystyle = x^2\sin x - \int 2x\sin x dx$    
      $\displaystyle = x^2\sin x - 2x(-\cos x) + \int 2(-\cos x) dx$    
      $\displaystyle = x^2\sin x + 2x\cos x - 2\sin x.$    

  2. Not required, though still, $ \displaystyle\int\frac{dx}{x^2-3x+2} = \log\frac{x-2}{x-1}$.
  3. Take $ u=e^x$ and then $ du=e^xdx=udx$ and hence $ dx=\frac{du}{u}$ and so

    $ \displaystyle \int_0^1\frac{dx}{1+e^x}$ $\displaystyle = \int_1^e\frac{du}{u(1+u)}$    
      $\displaystyle = \int_1^e\left(\frac{1}{u}-\frac{1}{1+u}\right)du$    
      $\displaystyle = \left.\log u\right\vert _1^e - \left.\log(1+u)\right\vert _1^e$    
      $\displaystyle = \log e - \log 1 - \log (1+e) + \log 2 = 1 + \log 2 - \log (1+e).$    

  4. Take $ u=x^2$ and then $ du=2xdx$ and so

    $ \displaystyle \int_0^\infty xe^{-x^2} dx$ $\displaystyle = \frac12\int_0^\infty 2xe^{-x^2} dx$    
      $\displaystyle = \frac12\int_0^\infty e^{-u}du$    
      $\displaystyle = \left.-\frac12e^{-u}\right\vert _0^\infty = 0 - (-\frac12e^{-0}) = \frac12.$    

The results. 83 students took the exam; the average grade is 65.31, the median is 65 and the standard deviation is 25.17.

The generation of this document was assisted by LATEX2HTML.


Dror Bar-Natan 2003-02-17