% vim: tw=50
% 29/11/2022 11AM

\begin{notation*}
    If $a \in \RR^n$ and $\delta > 0$, the
    \emph{closed ball of radius $\delta$ about
    $a$} is
    \[ \ol{B_\delta(a)} = \{\RR^n \mid \|x - a\|
    \le \delta\} \]
\end{notation*}

\begin{flashcard}[lindelof-picard-thm]
\begin{theorem}[Lindel\"of Picard]
    \cloze{
    Let $a, b \in \RR$ ($a < b$), $y_0 \in \RR^n$,
    $\delta > 0$ and $t_0 \in (a, b)$. Let $\phi :
    [a, b] \times \ol{B_\delta(y_0)} \to \RR^n$ be
    continuous and suppose there is some $K > 0$
    such that
    \[ \forall t \in [a, b] ~ \forall y, z \in
    \ol{B_\delta(y_0)} ~~\|\phi(t, y) - \phi(t,
    z)\| \le K\|y - z\| \]
    Then there is some $\eps > 0$ such that $[t_0
    - \eps, t_0 + \eps] \subset [a, b]$ and the
    initial value problem
    \[ f'(t) = \phi(t, f(t)) \quad \text{with}
    \quad f(t_0) = y_0 \tag{$*$} \]
    has a unique solution on $[t_0 - \eps, t_0 +
    \eps]$.
}
\end{theorem}
\end{flashcard}

\begin{hiddenflashcard}[lindeof-picard-thm-proof]
Proof of Lindel\"of Picard? \\
\cloze{
As $\phi$ is a continuous functioon on a compact
set, it is bounded. Let $M > 0$ such that
$\|\phi\| \le M$ everywhere. \\
Let $X$ be the set of continuous functions from
$[t_0 - \eps, t_0 + \eps]$ to $\ol{B_\delta(y_0}$.
By a lemma from lectures, $X$ is complete with the
uniform metric $d$. Also note $X$ non-empty. \\
Define $T : X \to X$ by
\[ Tg(t) = y_0 + \int_{t_0}^t \phi(x, g(x)) \dd x \]
Note by the Fundamental Theorem of Calculus, $f$
is a fixed point of $T$ if and only if is a
solution of the desired initial value problem. \\
If $g \in X$, $y \in [t_0 - \eps, t_0 + \eps]$ then
\[ \|Tg(t) - y_0\| \le \cdots \le M\eps \]
Also, if $g, h \in X$ and $t \in [t_0 - \eps, t_0 +
\eps]$ then
\[ \|Tg(t) - Th(t)\| \le \cdots \le K\eps d(g, h) \]
i.e. $d(Tg, Th) \le K\eps d(g, h)$. \\
Now pick $\eps > 0$ small enough so that $T$ maps
into $X$ ($\eps \le \frac{\delta}{M}$) and so that
it is a contraction mapping ($\eps < \frac{1}{K}$).
Then by the Contraction Mapping Theorem, $T$ has a
unique fixed point as desired.
}
\end{hiddenflashcard}

\begin{proof}
    As $\phi$ is a continuous function on a
    compact set so can find $M$ such that
    \[ \forall t \in [a, b] ~ \forall y \in
    \ol{B_\delta(y_0)} ~~ \|\phi(t, y)\| \le M \]
    Take $\eps > 0$ such that $[t_0 - \eps, t_0 +
    \eps] \subset [a, b]$. Let $X = \mathcal{C}([t_0
    - \eps, t_0 + \eps], \ol{B_\delta(y_0)})$. Then
    by Lemma 14, $X$ is complete with the uniform
    metric $d$. And obviously $X \neq \emptyset$.
    For $g \in X$, define $Tg : [t_0 - \eps, t_0 +
    \eps] \to \RR^n$ by
    \[ Tg(t) = y_0 + \int_{t_0}^t \phi(x, g(x))
    \dd x \]
    Note that by the Fundamental Theorem of
    Calculus, $Tf = f$ if and only if $f$ is a
    solution of ($*$). \\
    Now, if $g \in X$ and $t \in [t_0 - \eps, t_0
    + \eps]$ then
    \begin{align*}
        \|Tg(t) - y_0\|
        &= \left\| \int_{t_0}^t \phi(x, g(x)) \dd
        x \right\| \\
        &\le \int_{t_0}^t \|\phi(x, g(x))\| \dd x
        \\
        &\le M\eps
    \end{align*}
    Also, if $g, h \in X$ and $t \in [t_0 - \eps,
    t_0 + \eps]$ then
    \begin{align*}
        \|Tg(T) - Th(t)\|
        &= \left\|\int_{t_0}^t (\phi(x, g(x)) -
        \phi(x, h(x))) \dd x \right\| \\
        &\le \int_{t_0}^t \|\phi(x, g(x)) -
        \phi(x, h(x))\| \dd x \\
        &\le \int_{t_0}^t K \|g(x) - h(x)\| \dd x
        \\
        &\le K \eps d(g, h)
    \end{align*}
    i.e. $d(Tg, Th) \le K\eps d(g, h)$. So taking
    $\eps = \min \left\{ \frac{\delta}{M},
    \frac{1}{2K} \right\}$ we have that $T$ is a
    contraction of $X$ and so has a unique fixed
    point by Contraction Mapping Theorem as
    desired.
\end{proof}

\begin{remark*}
    Not that much use as stated - doesn't provide
    a global solution. Might or might not be one.
    In practice, given appropriate conditions on
    $\phi$ can often `patch together' local
    solutions. Beyond scope of this course.
\end{remark*}

\newpage
\section{The Inverse Function Theorem}

\begin{flashcard}[inverse-fn-thm]
\begin{theorem}[The Inverse Function Theorem]
    \cloze{
    Let $f : \RR^n \to \RR^n$ be \fcemph{continuously
    differentiable} at $a \in \RR^n$ with $\alpha =
    Df|_a$ being \fcemph{non-singular}. Then there exist
    open neighbourhoods $U$ of $a$ and $V$ of
    $f(a)$ such that $f|_U$ is a homeomorphism of
    $U$ onto $V$. \myskip
    Moreover, if $g : V \to U$ is the inverse of
    $f|_U$, then $g$ is differentiable at $f(a)$
    with $Dg|_{f(a)} = \alpha^{-1}$.
}
\end{theorem}
\end{flashcard}

\begin{proof}
    (We won't prove the fact about
    differentiability of the inverse in this
    course). \\
    Write
    \[ f(a + h) = f(a) + \alpha(h) + \eps(h) \|h\| \]
    where $\eps(h) \to 0$ as $h \to 0$. Let
    $\delta, \eta > 0$ such that $f$ is
    differentiable on $\ol{B_\delta(a)}$. Let $W =
    \ol{B_\delta(a)}$, $V = B_\eta(f(a))$. Define
    $\phi : \RR^n \to \RR^n$ by $\phi(x) = f(X) -
    \alpha(x)$. Then for $x \in W$, $\phi$ is
    differentiable at $x$ with
    \[ D\phi|_x = Df|_x - \alpha \to 0 \]
    as $x \to a$. Note $W$ is a complete,
    non-empty metric space. \\
    Fix $y \in V$. Define $T_y : W \to \RR^n$ by
    $T_y(x) = x - \alpha^{-1}(f(x) - y)$. Note
    $f(x) = y \iff T_y(x) = x$. Now, given $x \in
    W$,
    \begin{align*}
        \|T_y a\|
        &= \|\alpha^{-1}(\alpha x - f(x) + y -
        \alpha(a)\| \\
        &= \|\alpha^{-1}(y - f(x) + \alpha(x -
        a))\| \\
        &= \|\alpha^{-1}(y - f(a) - \eps(x - a)\|x
        - a\|)\| \\
        &\le \|\alpha^{-1}\|(\|y - f(a)\| +
        \|\eps(x - a)\| \|x - a\|) \\
        &\le \|\alpha^{-1}\|(\eta + \delta\|\eps(x
        - a)\|)
    \end{align*}
    Also, given $w, x \in W$,
    \begin{align*}
        \|T_y x - T_y w\|
        &= \|\alpha^{-1}(\alpha x - f(x) + f(w) -
        \alpha(w))\| \\
        &= \|\alpha^{-1}(\phi(w) - \phi(x))\| \\
        &\le \|\alpha^{-1}\| \|\phi(w) - \phi(x)\|
        \\
        &\le \|\alpha^{-1}\| \|w - x\| \sup_{z \in
        W} \|D \phi|_z\|
    \end{align*}
    by Mean Value Inequality. Pick $\delta > 0$
    sufficiently small such that $\forall x \in
    \ol{B_\delta(a)}$ we have $\|\eps(x - a)\| <
    \frac{1}{2\|\alpha^{-1}\|}$ and also $\sup_{z
    \in W} \|D \phi|_z\| < \frac{1}{\alpha^{-1}}$.
    (Can do this since $\eps(x - a) \to 0$ as $x
    \to a$ and $D\phi|_x \to 0$ as $x \to a$.).
    Take $y = \frac{\delta}{2}$. Then for each $y
    \in V$ we have $\forall x \in W \|T_y x - a\|
    < \delta$ and $\forall x, w \in W ~~ \|T_y x -
    T_y w\| \le K\|w - x\|$ where $K < 1$ is a
    constant. So $T_y$ is a contraction of $W$ and
    thus by Contraction Mapping Theorem has a
    unique fixed point, $x_y \in T_y(W) \subset
    B_\delta(a)$. That is, for each $y \in V$,
    there is a unique $x \in W$ with $f(x) = y$,
    and in fact $x \in B_\delta(a)$. \\
    Let $U$ be the set of all such $x$. Let $h =
    f|_{B_\delta(a)}$. Then $U = h^{-1}(V)$ so $U$
    is open in $B_\delta(a)$. But $B_\delta(a)$ is
    open in $\RR^n$ so $U$ is open in $\RR^n$. \\
    So now have open neighbourhoods $U$ of $a$ and
    $V$ of $f(a)$ such that $f$ maps $U$
    bijectively onto $V$. \\
    Remains to show inverse function is
    continuous. Let $X = \mathcal{C}(V, W)$. As
    $W$ is bounded, similarly to Lemma 14 we have
    $X$ is a complete, non-empty metric space with
    the uniform metric. Define $S : X \to X$ by
    \begin{align*}
        (Sg)(y)
        &= g(y) - \alpha^{-1}(f(g(y)) - y) \\
        &= T_y(g(y))
    \end{align*}
    Given $g, h \in X$ and $y \in V$,
    \begin{align*}
        \|(Sg)(y) - (Sh)(y)\|
        &= \|T_y(g(y)) - T_y(h(y))\| \\
        &\le K\|g(y) - h(y)\| \\
        &\le K d(g, h)
    \end{align*}
    So $d(Sg, Sh) \le K d(g, h)$. Now $S$ is a
    contraction of $X$ so by Contraction Mapping
    Theorem has a unique fixed point $g$. And by
    definition of $S$, for each $y \in V$, we have
    $g(y)$ is the unique $x \in W$ with $f(x) =
    y$. Hence $g = (f|_U)^{-1}$. But $g \in X$ so
    $(f|_U)^{-1}$ is continuous and thus $f|_U$ is
    a homeomorphism from $U$ onto $V$.
\end{proof}
