%% 11. The fundamental existence theorem

%%
% <latex>
% \setcounter{page}{129}
% </latex>

%%
% <latex>
% More than most mathematical fields, the subject of ODE\kern .5pt s is
% founded on a key theorem: solutions to an IVP $y'= f(t,y)$,
% $y(0) = y_0^{}$
% exist and are unique so long as $f$ is continuous
% with respect to both variables and Lipschitz continuous with
% respect to~$y$, as defined below.  (If $\partial f/\partial y$
% exists and is uniformly bounded, that is enough to
% imply Lipschitz continuity, since
% a bound on $|\partial f / \partial y|$ will serve as
% a Lipschitz constant.)
% The theorem applies to
% systems as well as scalars, which means that by the usual addition
% of extra variables, it applies to higher-order as well as
% first-order equations.  We rely on this result throughout this
% book.  In this chapter we present one of the
% standard proofs, due to Picard and
% Lindel\"of.\footnote{We emphasize that this theorem and proof
% represent just one particularly noteworthy
% item from the theory of existence and
% uniqueness for ODE\kern .5pt s.  In fact, there is a whole book on the subject:
% R. P. Agarwal and V. Lakshmikantham,
% {\em Uniqueness and Nonuniqueness Criteria for Ordinary
% Differential Equations,} World Scientific, 1993.}
% </latex>

%%
% <latex>
% Since an ODE prescribes the slope of a curve at each point, it
% may seem obvious that a unique solution must always exist.  However,
% we saw examples in Chapter~3 showing this is not the
% case.  The problem $y'= y^2$, $y(0)=1$ of (3.9) has the solution
% $y(t) = 1/(1-t)$ on $[\kern .3pt 0,d\kern 1pt]$ for $d<1$, but no
% solution exists for $d\ge 1$; $y^2$ fails to be
% Lipschitz continuous as $y\to\infty$.
% The problem $y' = y^{1/2}$, $y(0) = 0$ of (3.16)
% has the distinct solutions $y(t) = 0$ and $y(t) = t^2/4$, as well
% as many others; $y^{1/2}$ is not Lipschitz continuous for $y\approx 0$.
% So existence and uniqueness cannot be taken for
% granted.
% </latex>
 
%%
% <latex>
% For simplicity, we will state and prove the theorem first in the scalar
% case, and then indicate the modest changes needed for the
% generalization to systems.
% </latex>

%%
% <latex>
% \smallskip
% {\em
% {\bf Theorem 11.1.  Existence and uniqueness for a
% first-order scalar ODE IVP (\textsf{\textbf{FlaShI}}).}\ \ If\/ $f$ is continuous
% with respect to\/ $t$ and\/ $y$ 
% and Lipschitz continuous with respect to\/ $y$, then
% the IVP
% $$ y'(t) = f(t,y), \quad
% t\in [\kern .3pt 0,d\kern 1pt], ~y(0) = y_0^{}  \eqno (11.1) $$
% has a solution, and it is unique.}
% </latex>

%%
% <latex>
% \smallskip
% \noindent
% By a solution to the IVP, we mean a continuously differentiable
% function $y(t)$ satisfying (11.1).
% The condition that $f$ is {\bf Lipschitz continuous}
% with respect to $y$ means that there exists a constant
% $K$ such that for all $t\in [\kern .3pt 0,d\kern 1pt]$ and
% $y\in {\bf R}$,
% $|f(t,y_2^{})-f(t,y_1^{})| \le K |y_2-y_1{}|$.
% Although our discussion assumes $d>0$ for simplicity,
% (11.1) is actually symmetric with respect to $t$, and the same result
% holds for $t\in [\kern .2pt d,0\kern .3pt]$ with $d<0$.
% </latex>

%%
% <latex>
% The standard proof of Theorem 11.1 is based on the process
% known as {\bf Picard iteration}.
% We note that integration of (11.1) yields the
% equation\footnote{This
% is an example of a {\em Volterra integral equation.}}
% $$ y(t) = y_0^{} + \int_0^t f(s,y(s)) \kern .7pt ds . \eqno (11.2) $$
% In the Picard iteration, we consider
% the sequence of functions defined by 
% $y^{(0)} = y_0^{}$ and then
% $$ y^{(k+1)}(t) = y_0^{}+\int_0^t\kern -1.5pt f(s,y^{(k)}(s)) \kern .7pt ds,
% \quad k = 0,1,2,\dots , \eqno (11.3) $$
% or as we may write abstractly for an operator $N$,
% $$ y^{(k+1)} = N(y^{(k)}), \quad k = 0,1,2,\dots . \eqno (11.4) $$
% The proof consists of showing that under the given assumptions,
% this successive substitution
% process converges to a unique solution of (11.1), at least
% on some smaller interval $[\kern .3pt 0,d/m]$.  By a succession of
% $m$ such steps we reach all of $[\kern .3pt 0,d\kern 1pt]$.
% </latex>

%%
% Before presenting the mathematical argument,
% let us see the construction in action.  The problem
% $$ y' = \sin(y) + \sin(t), \quad t\in [0,8], ~~ y(0) = 1 \eqno (11.5) $$ 
% is an example of a nonlinear IVP whose defining function
% $f(t,y)$ is continuous with respect to both variables and Lipschitz
% continuous with respect to $y$; the Lipschitz constant
% can be taken as $K=1$.
% Here is a plot of iterates $k = 0,\dots,4$:
ODEformats, d = 8; t = chebfun('t',[0 d]); y0 = 1;
y = y0 + 0*t; ss = @(k) ['$k = ' int2str(k) '$']; 
for k = 0:4
  plot(y,CO,ivpnl), hold on, ylim([-3 10])
  text(1.015*d,y(end),ss(k),IN,LT)
  y = y0 + cumsum(sin(y)+sin(t));
end
title(['Fig.~11.1.~~Picard iterates ' ...
       '$k = 0,\dots,4$ for (11.5)'],FS,11)
xlabel('$t$',FS,10,IN,LT), ylabel('$y$',FS,10,IN,LT), hold off
%%
% <latex> \vskip 1.02em </latex>

%%
% <latex>
% \noindent
% A second plot shows $k = 5,\dots,9$.
% </latex>
for k = 5:9
  plot(y,CO,ivpnl), hold on, ylim([0 7])
  if k==8, text(1.015*d,y(end)-.25,ss(k),IN,LT)
  elseif k==5, text(1.015*d,y(end)+.25,ss(k),IN,LT)
  else text(1.015*d,y(end),ss(k),IN,LT), end
  y = y0 + cumsum(sin(y)+sin(t));
end 
title('Fig.~11.2.~~Picard iterates $k = 5,\dots,9$',FS,11)
xlabel('$t$',FS,10,IN,LT), ylabel('$y$',FS,10,IN,LT), hold off
%%
% <latex> \vskip 1.02em </latex>

%%
% <latex>
% \noindent
% A third plot shows $k = 10,\dots ,14$, and this time,
% we include the true solution (a dashed lined in red, mostly hidden
% under the green curves) to confirm that
% the iteration is converging successfully.
% </latex>
N = chebop(0,d); N.op = @(t,y) diff(y) - sin(y); N.lbc = y0;
yexact = N\sin(t); plot(yexact,'--r'), ylim([1 6]), hold on
for k = 10:14
  plot(y,CO,ivpnl), text(1.015*d,y(end),ss(k),IN,LT)
  y = y0 + cumsum(sin(y)+sin(t));
end
title(['Fig.~11.3.~~Picard iterates ' ...
       '$k = 10,\dots,14$ with exact solution'],FS,11)
xlabel('$t$',FS,10,IN,LT), ylabel('$y$',FS,10,IN,LT), hold off
%%
% <latex> \vskip 1.02em </latex>

%%
% <latex>
% These figures give a vivid impression of how
% convergence works for the Picard iteration:
% {\em from left to right.}
% On a short interval like $[\kern .3pt 0,1]$, the convergence for
% this example is rapid, whereas on the longer
% interval $[\kern .5 pt 0,8\kern .5pt]$ the rate is not so good.
% In fact, the successive iterates satisfy
% $$ y^{(0)}(t)-y(t) = O(t), ~~ y^{(1)}(t)-y(t) = O(t^2), ~~
% y^{(2)}(t)-y(t) = O(t^3), \dots . \eqno (11.6) $$
% These estimates apply even if $f$ is not smooth with 
% respect to $t$ or $y$ (Exercise~11.7).
% For our example, the powers are readily confirmed on the computer
% by plotting the errors of $y^{(0)},\dots, y^{(4)}$
% as functions of\/ $t$ on a log-log plot.  (The vertical bars correspond
% to points where the error happens to cross through zero.)
% </latex>
y = y0 + 0*t; ss = @(k) ['$k = ' int2str(k) '$'];
tt = logspace(-2,log10(8),1200);
for k = 0:4
  err = abs(y(tt)-yexact(tt));
  for j = 10:1000
    if err(j)<=min(err(j-1:j+1)), err(j)=1e-20; end
  end
  loglog(tt,err,'k',LW,.7), hold on
  text(8.7,err(1),ss(k),IN,LT)
  y = y0 + cumsum(sin(y)+sin(t));
end
xlabel('$t$',FS,10,IN,LT), ylabel('error',FS,9,IN,LT)
title('Fig.~11.4.~~Errors of iterates $0,\dots,4$ for (11.5)',FS,11)
axis([1e-2 8 1e-16 1e3]), hold off
%%
% <latex> \vskip 1.02em </latex>

%%
% <latex>
% One way to prove Theorem 11.1 is to make (11.6) quantitative.
% (See for example chap.~12 of S\"uli and Mayers, {\em An
% Introduction to Numerical Analysis,} Cambridge, 2003.)
% We follow here the more abstract and elegant
% approach of regarding the mapping $N$ of (11.4)
% as a {\em contraction map}
% in the Banach space $C([\kern .3pt 0,d\kern 1pt ])$ of continuous functions
% on $[\kern .3pt 0,d\kern 1pt ]$ with the
% supremum norm.\footnote{Do we really need Banach spaces?
% Not really --- see p.~4 of Hastings and McLeod,
% {\em Classical Methods in Ordinary Differential Equations with
% Applications to Boundary Value Problems,} American Mathematical
% Society, 2012.}
% More precisely, it may be necessary to restrict the interval
% to $[\kern .3pt 0,d/m]$ for some $m$ and take $m$ steps.
% </latex>

%%
% <latex>
% \smallskip
% {\em Proof of Theorem\/ $11.1$.}
% As described above, we set $y^{(0)} = y_0^{}$ and iterate with
% the formula (11.3).
% By induction it follows that
% $y^{(k)}$ is well-defined and continuously differentiable
% for each $k$.
% From (11.2) we compute 
% $$ y^{(k+1)}(t) - y^{(k)}(t) = \int_0^t\kern -1.5pt 
% \left[ f(s,y^{(k)}(s)) - f(s,y^{(k-1)}(s))\right ]  ds. $$
% Since $t\le d$, this equation implies 
% $$ \| y^{(k+1)}-y^{(k)}\|_\infty\le d K \|y^{(k)}-y^{(k-1)}\|_\infty,
% \eqno (11.7) $$
% where $K$ is the Lipschitz constant.
% Now suppose $dK < 1$.  Then (11.7) asserts that the map
% $N$ of (11.4) is a
% {\em contraction} in the Banach space 
% $C([\kern .3pt 0,d\kern 1pt])$ of continuous functions
% on $[\kern .3pt 0,d\kern 1pt]$ with norm $\|\cdot \|_\infty$.  By a
% standard result known as the {\em Banach fixed-point theorem\/} or
% the {\em contraction mapping principle,}
% a contraction map has a unique fixed point, i.e., a point $y$ with
% $N(y) = y$, and the iteration converges to it.
% In our context, this means that the iteration converges to a unique
% function $y\in C([\kern .3pt 0, d\kern 1pt])$ that satisfies
% $N(y) = y$, i.e., (11.2).  From (11.2) it follows that $y$ is
% in fact continuously differentiable and satisfies (11.1).
% </latex>

%%
% <latex>
% \def\qed{\vrule height4pt width3pt depth4pt}
% This completes the proof if $dK < 1$.
% What if $dK > 1$?  In this case we may pick an integer
% $m$ such that $dK/m < 1$ and use the same argument to establish
% a unique solution in $C([\kern .3pt 0, d/m])$.
% From here, a second
% application of the fixed-point theorem gives a unique solution in
% $C([\kern .2pt d/m,2d/m])$; and so on for $m$ steps.
% \qed
% </latex>


%%
% <latex>
% \smallskip
% Theorem 11.1 extends in an immediate manner to a first-order
% system of $n$ equations.
% \smallskip
% </latex>

%%
% <latex>
% {\em
% {\bf Theorem 11.2.  Existence and uniqueness
% for a first-order system of ODE\kern .5pt s (\textsf{\textbf{FlashI}}).}
% If\/ {\bf f} is continuous
% with respect to\/ $t$ and\/ $\bf y$ and Lipschitz continuous
% with respect to\/ $\bf y$, then the IVP
% $$ {\bf y}'(t) = {\bf f}(t,{\bf y}), \quad
% t\in [\kern .3pt 0,d\kern 1pt], ~{\bf y}(0) = {\bf y}_0  \eqno (11.8) $$
% has a solution, and it is unique.}
% \smallskip
% </latex>

%%
% <latex>
% \noindent
% The same proof works as before, with the Banach space
% $C([\kern .3pt 0,d\kern 1pt])$ generalized to  
% $C^n([\kern .3pt 0,d\kern 1pt])$ and with $\|{\bf y}\|_\infty$
% now defined as the supremum for $t\in[\kern .3pt 0,d\kern 1pt]$
% of $\|{\bf y}(t)\|$, where $\|\cdot\|$ is any fixed norm on ${\bf R}^n$.
% Lipschitz continuity is also defined with respect
% to the latter norm.
% We say that ${\bf f}(t,{\bf y})$ is Lipschitz continuous
% with respect to $\bf y$ if there exists a constant
% $K$ such that for all $t\in [\kern .3pt 0,d\kern 1pt]$ and
% $y\in {\bf R}^n$,
% $\|f(t,{\bf y}_2^{})-f(t,{\bf y}_1^{})\| \le K \|{\bf y}_2-{\bf y}_1{}\|$.
% Since all norms are equivalent on a finite-dimensional space, this
% definition is independent of the choice of norm.
% </latex>

%%
% <latex>
% \vskip .1em
% \begin{center}
% *~~~*~~~*
% \end{center}
% \vskip -1em
% </latex>

%%
% The main business of this chapter is finished: the statement and
% proof of Theorems 11.1 and 11.2, which assume that $f(t,y)$ is continuous
% in $t$ and Lipschitz continuous in $y$.
% Let us now explore around the edges a
% little.  Although these theorems mark a center point
% of this field, there is more to be said about both
% existence and uniqueness.

%%
% <latex>
% The most important matter to note is
% that continuity of $f$ with respect to~$t$ is a stronger assumption
% than necessary for the Picard iteration argument.
% The simplest next step, sufficient for the
% examples explored in this book such as those of Figures~2.3 and~2.8,
% is to suppose that $f$ is piecewise continuous as in Theorems~2.2 and~2.3.  
% When we say that the bivariate function $f(t,y)$ is
% piecewise continuous with respect to $t$, we mean that
% it is continuous with respect to $t$ except for at most a finite
% set of jump discontinuities at points $t_1^{},\dots,t_k^{}$ that are
% independent of $y$.
% The proof by Picard iteration then goes through essentially as before, with
% the Banach space $C([\kern .3 pt 0,d\kern .3pt])$ generalized to the
% Banach space of piecewise continuous functions with jump discontinuities only
% at the same points
% $t_1^{},\dots,t_k^{}$, again with norm $\|\cdot\|_\infty^{}$.
% </latex>

%%
% <latex>
% \smallskip
% {\em
% {\bf Theorem 11.3.  Existence and uniqueness
% for discontinuous ODE\kern .5pt s (\textsf{\textbf{FlashI}}).}
% The conclusions of Theorems~$11.1$ and\/~$11.2$ also hold
% if\/ {\bf f} is piecewise continuous
% with respect to\/ $t$ as defined above
% and Lipschitz continuous with respect to\/ $\bf y$.}
% \smallskip
% </latex>

%%
% <latex>
% For an extensive treatment of existence theorems for
% discontinuous ODE\kern .5pt s, see
% A. F. Filippov, {\em Differential Equations
% with Discontinuous Righthand Sides,} Kluwer, 1988.
% One theme in this theory is to extend results like
% Theorem~11.3 to coefficients that are just integrable
% with respect to $t$.  More generally, one may also
% weaken the condition that $f$ is Lipschitz continuous
% with respect to $y$.
% One line of such results takes $f$ to be continuous
% but not necessarily Lipschitz continuous, which is
% enough to guarantee existence of a solution at least locally, on some interval
% $[\kern .3pt 0,\delta\kern .7pt ]$ with $\delta > 0\kern .5pt$; this is
% the {\em Peano existence theorem.}
% The solution need not be unique, however.
% A standard example is equation (3.16),
% $y' = y^{1/2}$, and here is another example, taken
% from Ince's {\em Ordinary Differential Equations\/}:
% $$ y' = f(t,y), \quad f(t,y) = \cases{0 & $t=y=0$,
% \cr\noalign{\vskip 4pt}
% \displaystyle{4 t^3 y\over y^2 + t^4} & otherwise.} \eqno (11.9) $$
% The function $f$ is continuous with respect
% to $t$ and $y$ for all $t$ and $y$, and
% away from the point $t=y=0$, it is (locally) Lipschitz continuous with
% respect to $y$, ensuring existence and uniqueness of solutions
% so long as they stay away from this point and $\pm \infty$.
% Here is a display of some such solutions.
% </latex>
N = chebop(0,1);
N.op = @(t,y) diff(y) - 4*t^3*y/(y^2+t^4);
for y0 = [-1.4:.2:-.2 .2:.2:1.4]
    N.lbc = y0; y = N\0; plot(y,CO,ivpnl), hold on
end
ylim([-1.5 1.5])
title(['Fig.~11.5.~~Solutions of (11.9) ' ...
       'that avoid the point $t=y=0$'],FS,11,IN,LT)
%% 
% <latex> \vskip 1.02em </latex>

%%
% <latex>
% \noindent
% The interesting matter is what happens with solutions that
% do touch the point $t=y=0$.
% We can quickly spot three such solutions,
% $y(t) = -t^2$, $y(t) = 0$, and $y(t)= t^2$.  We add dashed black curves
% for $-t^2$ and $t^2$ to the figure.
% </latex>
t = chebfun('t',[0,1]);
plot(-t^2,'--k'), plot(t^2,'--k')
title(['Fig.~11.6.~~Two solutions of (11.9) ' ...
       'passing through $t=y=0$'],FS,11,IN,LT)
%% 
% <latex> \vskip 1.02em </latex>

%%
% <latex>
% \noindent
% Between these two black curves, there is a continuum of
% solutions, all passing through the point $t=y=0$.  We compute
% some numerically by marching backwards from $t=1$ to $t=0.01$,
% plotting the results in orange.
% </latex>
N.domain = [.01 1]; N.lbc = [];
for y0 = [-.85:.17:.85]
    N.rbc = y0; y = N\0; plot(y,CO,orange)
end
plot(-t^2,'--k'), plot(t^2,'--k')
title(['Fig.~11.7.~~A continuum of solutions ' ...
       'passing through $t=y=0$'],FS,11,IN,LT)
hold off
%% 
% <latex> \vskip 1.02em </latex>

%%
% <latex>
% \noindent
% Actually, this problem has an analytic solution.  For any
% $c$, the function
% $$ y(t) = c^2 - (t^4+c^4)^{1/2} \eqno (11.10) $$
% satisfies (11.9) and takes the value $y(0) = 0$.
% The negative of (11.10) is also a solution.
% </latex>

%%
% <latex>
% In an image like Figure 11.7, nonuniqueness takes the form of
% multiple solutions emanating from a single point
% $t$ and $y(t)$.  It is interesting to consider the same
% effect in reverse time, solving the same ODE for example
% from $t=1$ to $t=0$, as we discussed for the ``leaky bucket'' problem
% of Chapter 3.  (We also reversed time to generate Figure 11.7.)
% Here, we see multiple trajectories that coalesce --- not just
% approximately but exactly.  In an ODE problem driven by
% a Lipschitz continuous function $f$, two distinct solutions
% can never coalesce, so in some sense information about the
% initial condition can never be completely lost.  Non-Lipschitz
% problems like the leaky bucket viewed backward in time,
% however, are different.
% One might say that the adjoint of nonuniqueness is extinction.
% </latex>

%%
% <latex>
% \begin{center}
% \hrulefill\\[1pt]
% {\sc Application: designer nonuniqueness}\\[-3pt]
% \hrulefill
% \end{center}
% </latex>

%%
% From examples like (3.16) and (11.9), one may get the impression
% that nonuniqueness is elusive, to be found only if
% one knows how to look in just the right hiding places.  In fact,
% generating nonunique solutions is as easy at sketching curves
% on a sheet of paper, and Figure 11.7 shows us the sort
% of curves that are needed.  Take this diagram of functions
% $a (\sin(\pi t))^2$ with $-1 \le a \le 1$, for example.
t = chebfun('t',[-2,2]);
for a = -1:.2:1
  y = a*sin(pi*t)^2; plot(y,LW,.5,CO,ivpnl)
  axis([-1.7 1.7 -2.5 2.5]), hold on
end
title('Fig.~11.8.~~Sketching nonunique solution trajectories', ...
  FS,11,IN,LT)
%% 
% <latex> \vskip 1.02em </latex>

%%
% <latex>
% \noindent
% Each of these curves $y(t)$ is smooth, with a well-defined derivative
% at each point, which we may call $f(t,y)$.  So the curves are solutions
% of $y'(t) = f(t,y)$ for this choice of $f$.  Yet
% the trajectory emanating from $t=0$, $y= 0$ is obviously nonunique, as
% is the trajectory emanating from $t=k$, $y=0$ for any integer $k$.
% \noindent
% </latex>

%%
% <latex>
% In the figure, suppose we imagine that trajectories have been
% specified as indicated for each value $a \in [-1, 1]$.  If the ODE
% is to be defined for all~$t$ and~$y$, we need to fill in the regions
% above the top curve and below the bottom one.  This can be
% done in any number of ways, and here is one of them, based on
% functions $\pm [b + (\sin(\pi t))^2]$ with $b>1$.
% </latex>
t = chebfun('t',[-2,2]);
for b = .2:.2:1
    y = b + sin(pi*t)^2; plot([y; -y],LW,.5,CO,ivpnl)
end
hold off
title('Fig.~11.9.~~Filling in the whole $t$-$y$ plane',FS,11,IN,LT)
%% 
% <latex> \vskip 1.02em </latex>

%%
% <latex>
% \noindent
% If $b$ is regarded as taking all values $1< b < \infty$, then we
% have completed a specification of a function $f(t,y)$ that is
% continuous with respect to both variables for all
% $t$ and $y$.  Since it has nonunique trajectories through certain
% points, it cannot possibly be Lipschitz
% continuous with respect to $y\kern .7pt.$
% And indeed it is not, at least when $t$ ranges over any interval
% that includes one of the integers (Exercise~11.6).
% </latex>

%%
% <latex>
% Once we start sketching trajectories in the plane, we can see that
% all kinds of effects are possible.  Here is a function {\tt pinch}
% that has the effect of ``pinching'' a square of diameter $2d$ centered
% at $(t_0^{},y_0^{})$ so as to introduce nonuniqueness at this point.
% </latex>
pinch = @(t,y,t0,y0,d) y - (abs(y-y0)<d).*(abs(t-t0)<d).* ...
    cos(pi*(t-t0)/(2*d)).^2.*sign(y-y0).*(d/2-abs(abs(y-y0)-d/2));

%%
% <latex>
% \noindent
% Rather than talk through the algebra we visualize the effect
% of applying {\tt pinch(t,y,0,0,1)} to a set of horizontal trajectories:
% </latex>
t = linspace(-2,2,200)';
for ys = -2:.05:2
  y = ys + 0*t; y = pinch(t,y,0,0,1);
  plot(t,y,LW,.4,CO,ivpnl), hold on
end
axis([-2 2 -2 2]), axis square
title(['Fig.~11.10.~~Pinching trajectories gives nonuniqueness ' ...
       '\vrule height 16pt width 0pt depth 6pt'],FS,11,IN,LT), hold off
set(gcf,'position',[380 220 540 300]), set(gca,YT,-2:2)
%% 
% <latex> \vskip 1.02em </latex>

%%
% <latex>
% \noindent
% By pinching the plane at the middle point, we have introduced 
% nonuniqueness there.  With a few more pinches we can introduce more
% points of nonuniqueness.
% </latex>
for ys = -2:.05:2
    y = ys + 0*t;
    y = pinch(t,y,0,0,1);
    y = pinch(t,y,1.3,1.3,.5); y = pinch(t,y,-1.3,-1.3,.5);
    y = pinch(t,y,1,-1,.3); y = pinch(t,y,-1,1,.3);
    plot(t,y,LW,.4,CO,ivpnl), hold on
end
axis([-2 2 -2 2]), axis square, hold off
title(['Fig.~11.11.~~Multiple pinch points' ...
       '\vrule height 16pt width 0pt depth 6pt'],FS,11,IN,LT)
set(gcf,'position',[380 220 540 300]), set(gca,YT,-2:2)
%% 
% <latex> \vskip 1.02em </latex>

%%
% <latex>
% \noindent
% In a paper published in 1963, based on an earlier publication
% by Lavrentieff in 1925, P. Hartman took this idea to a fascinating
% limit with a fractal flavor (``A differential
% equation with non-unique solutions,''
% {\em American Mathematical Monthly}).
% By introducing infinitely many pinches on successively smaller
% scales, he showed that one can
% construct a flow field with pinch points falling
% arbitrarily close to every value $(t,y)$.  This implies a
% remarkable consequence: there is an ODE $y' = f(t,y)$ with the
% property that for every choice of initial point $(t_0^{},y_0^{})$,
% the equation has more than one solution on every
% interval $[\kern .5pt t_0^{}, t_0^{}+\varepsilon\kern .5pt ]$.
% </latex>

%%
% <latex>
% \smallskip
% {\sc History.}  Theorem 11.2 is often called the
% Picard--Lindel\"of theorem,
% following publications by Picard in 1890 and Lindel\"of in 1894;
% another landmark was Goursat's {\em Cours d'analyse 
% math\'ematique} of 1908.
% It is also called the Cauchy--Lipschitz theorem, and an early
% publication was by Liouville in 1838.
% Peano's local existence theorem, without the Lip\-schitz requirement
% or the assertion of uniqueness, appeared in 1890 and was
% elaborated in his {\em Trait\'e d'Analyse,} though
% the idea of successive substitution is much older.\ \ Banach's
% fixed-point theorem appeared in 1922, and
% Carath\'eodory in 1927 published one of the first
% local existence theorems for ODE\kern .5pt s defined by
% discontinuous coefficient functions~$\bf f$.
% </latex>

%%
% <latex>
% \smallskip
% {\sc Our favorite reference.}  
% Discontinuous right-hand sides are ubiquitous in applications,
% and their dynamical consequences are explored in
% di Bernardo, Budd, Champneys, and Kowalczyk,
% {\em Piecewise-smooth Dynamical Systems: Theory and Applications,}
% Springer, 2008. 
% \smallskip
% </latex>

%%
% <latex>
% \begin{displaymath}
% \framebox[4.7in][c]{\parbox{4.5in}{\vspace{2pt}\sl
% {\sc Summary of Chapter 11.}  The fundamental existence theorem
% of ODE\kern .5pt s asserts that an ODE\/ ${\bf y}' = {\bf f}(t,{\bf y})$ subject to
% initial data ${\bf y}(0) = {\bf y}_0$ has a unique solution for all\/ $t$\/
% if\/ $\bf f$ is continuous with respect to\/ $t$ and Lipschitz
% continuous with respect to\/ $\bf y$.  This result applies to
% systems as well as scalars and thus covers higher-order
% ODE\kern .5pt s too if appropriate conditions are specified on derivatives.
% Both existence and uniqueness can fail if\/ $\bf f$ is merely continuous
% with respect to\/ $\bf y$, though existence still holds locally.
% \vspace{2pt}}}
% \end{displaymath}
% </latex>

%%
% <latex>\smallskip\small\parskip=1pt\parindent=0pt
% {\em Exercise $11.1$.  Cleve Moler's favorite ODE.}\ \ Consider
% the IVP $(y')^2 + y^2 = 1$, $y(0) = 0$ with 
% the additional constraint $-1 \le y \le 1$.
% {\em (a)} Show that there are exactly two solutions
% for $t\in [\kern .3pt 0,1]$ and state formulas for them.
% {\em (\kern .7pt b)} Show that there are infinitely many solutions
% for $t\in [\kern .3pt 0,2\kern .3pt ]$.
% \par
% {\em Exercise $11.2$.  From an integral equation to an IVP.}\ \ Convert
% the integral equation $y(t) = e^{\kern .3pt t} + 4\int_0^t (t-s) y(s) ds$
% to an ODE IVP (including the initial condition).  Determine
% the solution analytically.
% \par
% {\em Exercise $11.3$. Differentiability and Lipschitz continuity.}
% Prove that if a function $f(t,y)$ has a uniformly bounded derivative
% $|\partial f/\partial y|$ for all $t$ and $y$,
% then it is Lipschitz continuous.
% \par
% {\em Exercise $11.4$. Value of\/ $m$ for our example.}
% For the example (11.5) of the opening pages of this chapter,
% the Picard iteration converges over the whole interval
% $[\kern .3pt 0,8]$.  However, our proof of Theorem 11.1
% subdivides the interval into $m$ subintervals.  For this example,
% what is the smallest allowed number $m$?
% \par
% {\em Exercise $11.5$. A first-order two-point BVP.}\ \ {\em (a)}
% Sketch the solution curves of $y' = |y|^{1/2}$ in
% the $(t,y)$ plane.  How do nonuniqueness and extinction effects
% appear in this plot?
% {\em (\kern .7pt b)} Suppose $y(0) = -1$ and $y(6) = 1$.  There exists
% a unique solution for $t\in [\kern .3pt 0,6\kern .3pt ]$
% for these data (an unusual situation in that this is
% a first-order equation with two boundary conditions!).
% Determine this solution analytically.
% \par
% {\em Exercise $11.6$. Figure\/ $11.9$.}
% {\em (a)} Verify that the function $f$ described by Figure~11.9 is
% not Lipschitz continuous.
% {\em (\kern .7pt b)} Exactly
% how many solutions are there on $[-2,2]$ to the ODE described by
% this figure that satisfy $|y(t)|=1$ for $t = -1.5, -0.5, 
% 0.5, 1.5\kern .7pt ?$ 
% \par
% {\em \underline{Exercise $11.7$}. Nonsmooth $f$.}
% In the text it was mentioned that the estimates (11.6) apply
% even if $f$ is not smooth.  Verify this experimentally by
% reproducing Figure 11.4 with $f$ changed to
% {\em (a)} $\sin(y) + \hbox{sign}(\sin(50\kern .3pt t))$ and
% {\em (\kern .7pt b)} $|\sin(10\kern .3pt y)| + \sin(t)$.
% It is enough to work with the time interval $[\kern .3pt 0, 1]$.
% \par
% {\em \underline{Exercise $11.8$}. A growing exponent.}
% A function $y(t)$ is continuously differentiable, nonnegative, and unbounded for
% $t\in (0,4)$, where it satisfies
% $y' = y^t$.  For what subinterval of $(0,4)$ is 
% $y$ identically zero?
% ({\em Hint.}  Try integrating backward in time from $t=4$ to $t=1$
% with a boundary condition $y(4) = 4$ or $8$.) 
% </latex>
