First-order differential equations
-
Ordinary DE involves functions of a single variable.
-
Partial DE involves functions of multiple variables.
Define $$ \exp(x) = \sum_{n=0}^\infty \frac{x^n}{n!}.$$
Alternatively define $$ \exp(x) = \lim_{k\to\infty}\Big(1+\frac xk\Big)^k. $$
$$\frac{d}{dx}\exp(x) = \exp(x).$$
Alternatively define $\exp(x)$ as the unique solution of $$ \frac{df}{dx} = f\quad\text{with } f(0) = 1.$$
For all $z_1, z_2\in\mathbb C$, $$ \exp(z_1)\exp(z_2) = \exp(z_1+z_2). $$
Define $$ \exp(x) = e^x $$ where $$e = \exp(1) = \lim_{k\to\infty}\Big(1+\frac1k\Big)^k.$$
Define the natural log $\ln$ be the inverse of $\exp$.
Define for any $a,x\in\R$, $$ a^x = \exp(x\ln a). $$
-
Linear: $y$ and its derivative appear linearly.
-
First-order: highest derivative is $dy/dx$.
-
Homogenous: all terms involve $y$ or its derivative.
For the equation $$ ay' + by = 0,$$ take $$ y = Ae^{\lambda x}. $$ Then we get the characteristic equation $$ a\lambda + b = 0. $$
General method for any linear forced ODEs:
-
Find (guess) a particular integral $y_p(x)$ i.e. a single solution of the forced equation;
-
Write the general solution of the ODE as $$ y(x) = y_p(x) + y_c(x). $$ Then $y_c(x)$, the complementary function, satisfies the homogenous equation.
-
Combine $y_p$ and $y_c$ to get the general solution.
Consider the general equation $$ a(x) y' + b(x) y = c(x). $$ We usually write it in the standard form by dividing $a(x)$: $$ y' + p(x) y = f(x). $$
We let the integrating factor be $$ \mu(x) = \exp\Big(\int^x p(u)\,du\Big) $$ and our solution is $$ y(x) = \frac{1}{\mu(x)}\int^x \mu(u)f(u)\,du. $$
We consider the form $$ Q(x,y)y' + P(x,y) = 0. $$ In general this is not solvable.
A first-order ODE is separable if it can be written as $$ q(y)\,dy = p(x)\,dx, $$ which can be solved by direct intergration.
An ODE $P(x,y) \,dx + Q(x,y)\,dy = 0$ is exact if there exists $f(x,y)$ such that $$ df = P(x,y)\,dx + Q(x,y)\,dy. $$ Then $df=0$ so $f(x,y) =$ constant is the solution.
Therefore we need to find $f$ such that $$\begin{cases} \frac{\partial f}{\partial x} = P(x,y), \\ \frac{\partial f}{\partial y} = Q(x,y). \end{cases}$$
Check this condition in your head:
Note that $\frac{\partial^2 f}{\partial x\partial y} = \frac{\partial^2 f}{\partial y\partial x}$, so a necessary condition for an exact equation is $$ \frac{\partial P}{\partial y} = \frac{\partial Q}{\partial x}. $$
The theorem below says this is a sufficient condition under certain domains.
If $$\begin{align*} \frac{\partial P}{\partial y} = \frac{\partial Q}{\partial x} \end{align*}$$ throughout a simply connected domain $\mathcal D$, then $P\,dx + Q\,dy$ is an exact differential of single-valued $f(x,y)$ in $\mathcal D$.
Consider $y' = f(t,y)$. Each initial condition like $y(0) = y_0$ generates a distinct solution curve.
$f(t,y)$ represents the gradient of the solution curve. You can plot the slope field to visualise. You can also plot isoclines, which are curves along with $f(t,y)$ is constant.
A fixed point of an ODE $$ \frac{dy}{dt} = f(t,y) $$ is a constant solution $y=c$, i.e. $dy/dt = 0$ for all $t$.
-
A fixed point $y=c$ is stable if whenever $y$ deviates slightly from $c$, $y$ converges to $c$ as $t\to\infty$.
-
It is unstable if whenever $y$ deviates slightly from $c$, $y$ diverges from $c$ as $t\to\infty$.
To find out the stability of a fixed point, we consider a small perturbation of $y$ from $c$, $$ y(t) = c + \epsilon(t). $$ So $$ \frac{d\epsilon}{dt} = f(t, c+\epsilon(t)) = \underbrace{f(t, c)}_0 + \epsilon\frac{\partial f}{\partial y}\Big|_{t,c} + O(\epsilon^2). $$ Linearising the small $\epsilon$, $$ \frac{d\epsilon}{dt} \approx \epsilon\frac{\partial f}{\partial y}\Big|_{t,c}. $$ Then solve for $\epsilon$ to find out behaviour as $t\to\infty$.
An autonomous system has a differential equation of the form $$ \frac{dy}{dt} = f(y) $$ which does not depend on $t$.
Suppose we have a fixed point $y=c$, i.e. $f(c) = 0$. Then $$ \frac{d\epsilon}{dt} = \epsilon f'(c) + O(\epsilon^2) $$
Lectures notes say that by linearising, we have the solution $$ \epsilon(t) = \epsilon_0 e^{f'(c)t}. $$ In practice, just considering the sign of $f'(c)$, or the first non-zero derivative of $f$, is enough to determine the stability.
Hence the fixed point is
-
stable when $f'(c) < 0$;
-
unstable when $f'(c) > 0$.
A phase diagram shows the direction solutions flow as $t$ increases.
Consider a first-order discrete equation which is independent of $n$ $$ x_{n+1} = f(x_n). $$
A fixed point of a first-order discrete equation is a value $x_n$ such that $$ x_{n+1} = x_n $$ i.e. $$ f(x_n) = x_n. $$
Using perturbation analysis, let $x_f$ be a fixed point and we let $$ x_n = x_f + \epsilon_n. $$ Then $$ x_f + \epsilon_{n+1} = f(x_f + \epsilon_n) = \underbrace{f(x_f)}_{x_f\text{ by fixed point}} + \epsilon_n f'(x_f) + O(\epsilon_n)^2. $$ Neglecting higher order terms, $$ \epsilon_{n+1} \approx \epsilon_n f'(x_f). $$
Therefore, a stable point is
-
stable when $|f'(x_f)| < 1$;
-
unstable when $|f'(x_f)| > 1$.