1. Let $f: \mathbb{R} \rightarrow \mathbb{R}$ be twice differentiable, with $f''(x) \geq 0\,∀x \in \mathbb{R}$. Prove that $f\left(\frac{x+y}{2}\right) \leq \frac{1}{2}(f(x)+f(y)) \text { for all } x, y \in \mathbb{R}$.
    Assume there exist $x,y$ with $x\lt y$ and $f\left(\frac{x+y}{2}\right) \gt \frac{f(x)+f(y)}{2}$ then $\frac{f\left(\frac{x+y}2\right)-f(x)}{\frac{x+y}2-x} \gt \frac{f(y)-f\left(\frac{x+y}2\right)}{y-\frac{x+y}2}$.
    By MVT, there exists $t_1∈\left(x,\frac{x+y}2\right),t_2∈\left(\frac{x+y}2,y\right)$ such that $f'(t_1)=\frac{f\left(\frac{x+y}2\right)-f(x)}{\frac{x+y}2-x},f'(t_2)=\frac{f(y)-f\left(\frac{x+y}2\right)}{y-\frac{x+y}2}$, then $f'(t_1)>f'(t_2)$, by MVT, there exists $t∈(t_1,t_2)$ such that $f''(t)=\frac{f'(t_1)-f'(t_2)}{t_1-t_2}$, so $f''(t)<0$, contradicting to $f''(x)\ge0\, \forall x\in\mathbb R$.
  2. (a) Let $f: \mathbb{R} \rightarrow \mathbb{R}$ be differentiable and let $a \in \mathbb{R}$. Suppose that $f''(a)$ exists. Prove that $\lim_{h \rightarrow 0} \frac{f(a+h)+f(a-h)-2 f(a)}{h^2}=f''(a)$.[Second-order central difference]
    (b) Assume that $f: \mathbb{R} \rightarrow \mathbb{R}$ be twice differentiable on $\mathbb{R}$. Suppose that $f$ satisfies the following convex inequality $f\left(\frac{x+y}{2}\right) \leq \frac12(f(x)+f(y))$ for all $x, y \in \mathbb{R}$.
    Using (a) to show that $f''(a) \geq 0$ for all $a \in \mathbb{R}$.
    (a) $f$ is twice differentiable at $x=a$ so $f$ is continuous at $x=a$. Let $F(h)=f(a+h)+f(a-h)-2f(a)$, then $F(h)→0$ as $h→0$. Use L'Hopital's rule($\frac00$ type)$$\lim_{h→0}\frac{F(h)}{h^2}=\lim_{h→0}\frac{F'(h)}{2h}=\lim_{h→0}\frac{f'(a+h)-f'(a-h)}{2h}=f''(a)$$Another approach:
    By Taylor’s Theorem,$$f(a+h)=f(a)+hf'(a)+\frac{h^2}2f''(a)+o(h^2)$$$$f(a-h) =f(a)-hf' (a)+\frac{h^2}2f''(a)+o(h^2)$$Thus $$f(a+h)+f(a-h)-2f(a)=h^2f''(a)+o(h^2)$$ and we are done.
    (b) Substituting $x=a+h\atop y=a-h$, we get $f(a)\le\frac{f(a+h)+f(a-h)}2$⇒$\frac{f(a+h)+f(a-h)-2 f(a)}{h^2}≥0$, so $\lim_{h \rightarrow 0} \frac{f(a+h)+f(a-h)-2 f(a)}{h^2}=f''(a)≥0$.
  3. (a) Prove that $\cos x$ and $\sin x$, given by their power series: $\cos x=\sum_{n=0}^{\infty}(-1)^{n} \frac{x^{2 n}}{(2 n) !}$ and $\sin x=\sum_{n=0}^{\infty}(-1)^{n} \frac{x^{2 n+1}}{(2 n+1) !}$ are differentiable on $\mathbb{R}$.
    Hence prove that $\cos (x+y)=\cos x \cos y-\sin x \sin y$ for all $x, y \in \mathbb{R}$.
    Deduce from the addition formula for $\cos x$ the corresponding addition formula for $\sin x$, and prove that $|\cos x| \leq 1$ and $|\sin x| \leq 1$ for all $x \in \mathbb{R}$.
    (b) Prove that $\sin x \geq x-\frac{x^3}{3!}$ and that $\cos x \leq 1-\frac{x^2}2+\frac{x^{4}}{24}$ for $x \geq 0$, and deduce that $\cos 2<0, \sin x>0$ for $x \in(0,2)$ and $\cos$ is strictly decreasing on [0,2]. Hence, by using IVT, prove that there exists a unique $p∈[0,2]$ such that $\cos p=0$ and $\sin p=1$.
    Define $\pi=2 p$. Show that $\cos (x+2 \pi)=\cos x$, and $\sin (x+2 \pi)=\sin x$ for all $x \in \mathbb{R}$, and $2 \pi$ is the smallest strictly positive period of $\sin$ (or the same $\cos$ ) function.
    (c) Let $q \in \mathbb{R}$. Prove that $\sin q=0$ only if $q$ is of the form $q=k \pi$ for some $k \in \mathbb{Z}$.
    (d) Describe the continuous functions $f: \mathbb{R} \rightarrow \mathbb{R}$ which satisfy $\sin (f(x))=\sin x$ for all $x \in \mathbb{R}$. [Graphical presentation of answer acceptable.]
    (a) By ratio test, the series $\sum_{n=0}^{\infty}(-1)^{n} \frac{x^{2 n}}{(2 n) !}$ and $\sum_{n=0}^{\infty}(-1)^{n} \frac{x^{2 n+1}}{(2 n+1) !}$ converges for all $x∈\mathbb R$. By Theorem 2.1.15, $\sin x$ and $\cos x$ are differentiable on $\mathbb R$.$$(\sin x)'=\sum_{n=0}^{\infty}(-1)^{n} \frac{x^{2 n+1}}{(2 n+1) !}=\sum_{n=0}^{\infty}(-1)^{n} \frac{x^{2 n}}{(2 n) !}=\cos x$$Similarly, $(\cos x)'=-\sin x$.
    $\frac{\rm d}{\mathrm dt}(\cos(s-t)\cos(s+t)-\sin(s-t)\sin(s+t))=\sin(s-t)\cos(s+t)-\cos(s-t)\sin(s+t)+\cos(s-t)\sin(s+t)-\sin(s-t)\cos(s+t)=0$⇒$\cos(s-t)\cos(s+t)-\sin(s-t)\sin(s+t)$ is constant for $t$, taking $t=s$, we get $\cos(s-t)\cos(s+t)-\sin(s-t)\sin(s+t)=\cos2s$. Let $s=\frac{x+y}2,t=\frac{x-y}2$, we get $\cos x\cos y-\sin x\sin y=\cos(x+y)$.
    Take $y=-x$ we get $\cos^2x+\sin^2x=1$, so $|\cos x| \leq 1$ and $|\sin x| \leq 1$ for all $x \in \mathbb{R}$.
    (b) Consider function$$h(x)=\cos x-1+\frac{x^2}{2 !}-\frac{x^4}{4 !}$$Then \begin{array}l h'(x)=-\sin x+x-\frac{x^3}{3 !},\\ h''(x)=-\cos x+1-\frac{x^{2}}{2 !},\\ h^{(3)}(x)=\sin x-x,\\ h^{(4)}(x)=\cos x-1.\end{array} $h^{(4)}(x) \leq 0$
    ⇒$h^{(3)}$ is decreasing⇒$h^{(3)}(x) \leq h^{(3)}(0)=0$
    ⇒$h''$ is decreasing⇒$h''(x) \leq h''(0)=0$
    ⇒$h'$ is decreasing⇒$h'(x) \leq h'(0)=0⇒\sin x \geq x-\frac{x^3}{3!}$ for $x≥0$.
    ⇒$h$ is decreasing⇒$h(x) \leq h(0)=0⇒\cos x \leq 1-\frac{x^{2}}{2 !}+\frac{x^{4}}{4 !}$ for $x ≥ 0$.
    Take $x=2$ we get $\cos2≤-\frac13<1=\cos0$, by IVT, there exists a unique $p∈(0,2)$ such that $\cos p=0$, so $\sin^2p=1$, but $\sin p>0$, so $\sin p=1$.
    By the addition formula, $\cos(x+p)=\cos x\cos p-\sin x\sin p=-\sin x$, $\sin(x+p)=\sin x\cos p+\cos x\sin p=\cos x$,
    $\cos(x+π)=\cos((x+p)+p)=-\sin(x+p)=-\cos x$, $\sin(x+π)=\cos((x+p)+p)=\cos(x+p)=-\sin x$,
    $\sin(x+2π)=\sin((x+π)+π)=-\sin(x+π)=\sin x$, so $\sin x$ is 2π-periodic.
    Because $\sin (x+p)=\cos x$, we have $\sin x\in(0,1)$ for $x∈(0,2p)$, so $\sin x≠0$ for $x∈(0,2p)$, so 2π is the smallest strictly positive period of $\sin$ function.
    (c) Let $q=q_0+2mπ,m\in\mathbb Z,q_0∈[0,2π)$. $\sin q=\sin q_0=0$⇒$q_0=0$ or π⇒$q=k\pi$ for $k=2m$ or $2m+1$, respectively.
    (d) Let $g_k(x)=x+2kπ$ or $h_k(x)=π-x+2kπ$. For every $x∈\mathbb R$ there exists $k\in\mathbb Z$ such that $f(x)=g_k(x)$ or $h_k(x)$. So $f=g_k$ or $f=h_k$ or $f$ is a piecewise linear function, in this case, we consider $x>0$ ($x<0$ is similar). Let the positive turning points of $f$ be $s_1<s_2<⋯$(infinite) or $s_1<s_2<⋯<s_n$. If $g_u(x)=h_v(x)$ then $x=\fracπ2+(v-u)π$, so each $s_i$ has form $s_i=\fracπ2+k_iπ$ for some $k_i∈\mathbb Z$.
    Starting from $f(0)=2mπ$ for some $m\in \mathbb Z$, we have two cases:
    Case A. $f(x)=x+f(0)$ on $[0,s_1]$, then $f(x)=-(x-s_1)+f(s_1)$ on $[s_1,s_2]$, then $f(s_2)=x-s_2+f(s_2)$ on $[s_2,s_3]$, then $f(s_3)=-(x-s_3)+f(s_3)$ on $[s_3,s_4]$, ⋯ Hence $f(s_i)=(-1)^i(x-s_i)+f(s_i)$ on $[s_i,s_{i+1}]$ for $i=1,2,⋯$(infinite) or $i=1,2,⋯,n$.
    Case B. $f(x)=-x+f(0)$ on $[0,s_1]$, then $f(x)=x-s_1+f(s_1)$ on $[s_1,s_2]$, then $f(s_2)=-(x-s_2)+f(s_2)$ on $[s_2,s_3]$, then $f(s_3)=x-s_3+f(s_3)$ for $[s_3,s_4]$, ⋯ Hence $f(s_i)=(-1)^{i+1}(x-s_i)+f(s_i)$ on $[s_i,s_{i+1}]$ for $i=1,2,⋯$(infinite) or $i=1,2,⋯,n$.
  4. Suppose that $f: \mathbb{R} \rightarrow \mathbb{R}$ is differentiable everywhere.
    (a) Prove that if $f'(x)=a f(x)$ for all $x$, then $f(x)=A \exp (a x)$ for some constant $A$.
    (b) Prove that if $f''(x)-5f'(x)+6 f(x)=0$ then $f(x)=A \exp (2 x)+B \exp (3 x)$ for some constants $A,B$.
    (c) Prove that if $f''(x)+25 f(x)=0$ then $f(x)=A \cos (5 x)+B \sin (5 x)$ for some constants $A,B$.
    (d) What can be said about the solutions of the differential equation $f''(x)-4 f'(x)+4 f(x)=0$?
    (a) $(e^{-ax}f(x))'=e^{-ax}(f'(x)-af(x))=0$, by Identity Theorem, for some constant $A$ we have $e^{-ax}f(x)=A⇒f(x)=Ae^{ax}$.
    (b) $(f'(x)-2f(x))'=3(f'(x)-2f(x))$, by part (a), for some constant $B$ we have $f'(x)-2f(x)=Be^{3x}⇒(f(x)-Be^{3x})'=2(f(x)-Be^{3x})$, by part (a), for some constant $A$ we have $f(x)-Be^{3x}=Ae^{2x}⇒f(x)=Ae^{2x}+Be^{3x}$.
    (c) Put $A:=f(0),B:=f'(0) / 5,g(x):=f(x)-A \cos (5 x)-B \sin (5 x),$ then $g'(x)=f'(x)+5A\sin(5x)-5B\cos(5x)$, $g''(x)=f''(x)+25A\cos(5x)+25B\sin(5x)$,
    so $(\frac{25}{2} g(x)^{2}+\frac{1}{2} g'(x)^2)'=g'(x)(25g(x)+g''(x))=g'(x)(25f(x)+f''(x))=0$, by Identity Theorem, $\frac{25}{2} g(x)^{2}+\frac{1}{2} g'(x)^2=\frac{25}{2} g(0)^{2}+\frac{1}{2} g'(0)^2=0$, so $5g(x)=g'(x)$ or $-5g(x)=g'(x)$, so $g(x)=Ce^{5x}$ or $g(x)=Ce^{-5x}$ but $g(0)=g'(0)=0$ so $g(x)=0$ so $f(x)=A \cos (5 x)+B \sin (5 x)$.
    (d) $(f'(x)-2f(x))'=2(f'(x)-2f(x))$, by part (a), for some constant $B$ we have $f'(x)-2f(x)=Be^{2x}⇒(e^{-2x}f(x)-Bx)'=0$, by Identity Theorem, $e^{-2x}f(x)=A+Bx⇒f(x)=e^{2x}(A+Bx)$.
  5. Suppose $f:(-1,1)\to\mathbb R$ differentiable such that $f(0)=0$, $f'(0)>0$, Construct an example of $f$ that is not monotone in any neighborhood of 0.
    $f(x):=\left\{\begin{array}{ll}x+x^\alpha\sin(x^{-α})& \text { for } x \neq 0 \\ 0 & \text { for } x=0\end{array}\right.$ where $α>1$.
    $f'(0)=\lim_{x→0}\frac{x+x^α\sin(x^{-α})}x=1+\lim_{x→0}x^{α-1}\sin(x^{-α})=0$, so $f(x)$ is differentiable at 0.
    For $x_k^{-α}=kπ$, we have $\cos x_k^{-α}=(-1)^k,\sin x_k^{-α}=0$, so $f'(x_k)=1+α(x_k^{α-1}\sin(x_k^{-α})-x_k^{-1}\cos(x_k^{-α}))=1-α(-1)^kx_k^{-1}$ is oscillating and unbounded.