# Fokker–Planck Equations is a class of partial differential equations that govern how uncertainty propagates through the dynamics of a stochastic differential equation (SDE). While SDEs themselves have very erratic behavior at the microscopic level, there is a hidden determinism in their behavior if one views them as an input-output machine that evolves probability densities. In terms of probabilities everything is suddenly paradoxically determinisitc. This paradox often captured precisely by the Fokker–Planck framework, which governs the deterministic flow of distributions induced by stochastic dynamics. Fokker–Planck equations have several applications in control and planning, including shaping uncertainty in a system, providing a probabilistic perspective on control, controlling swarms to match target distributions, and designing ergodic objectives. We will review each of these applications in subsequent posts. We will introduce the classical Fokker–Planck equation, that is well-known in probability and statistical physics literature. Later, we will see its *non-holonomic variants* as is relevant to control theory applications, when uncertainity is generated in the system through limited degrees of freedom. First, we start at the microscopic level. Suppose $U: \mathbb{R}^d \rightarrow \mathbb{R}$ is a potential function. We consider the stochastic dynamics: $$ \mathrm{d}X = -\nabla U(X)\, \mathrm{d}t + \sqrt{2} \, \mathrm{d}W + \mathrm{d}Z, $$ where $W$ denotes a $d$-dimensional Brownian motion, and $Z(t)$ is a process that constrains the dynamics to a domain $\Omega$. This equation is sometimes known as the (overdamped) Langevin equation. | ![langevin_with_potential(1)](https://hackmd.io/_uploads/r1e04EyHle.gif)| | -------- | |A particle undergoing overdamped Langevin dynamics in a quadratic potential. The path reflects the combined influence of deterministic drift (toward the minimum of the potential) and stochastic diffusion (modeled by Brownian noise). The contour lines represent the energy landscape $U(x)=\frac{1}{2}∣x∣^2$. | Let $\mathbb{P}(X(t) \in \mathrm{d}x) = p_t(x)\, \mathrm{d}x$ be the probability of the process occupying an infinitesimal region $\mathrm{d}x$ at time $t$. Then $p_t$ evolves according to the Fokker–Planck equation: $$ \partial_t p = \Delta p - \nabla \cdot (\nabla U(x)\, p), $$ where $\Delta := \sum_{i=1}^d \partial^2_{x_i}$ is the Laplacian and $\nabla \cdot$ denotes the divergence operator. If $\Omega \subsetneq \mathbb{R}^d$, the equation is supplemented with the **zero-flux boundary condition**: $$ \vec{n}(x) \cdot (\nabla p_t(x) - \nabla U(x)\, p_t(x)) = 0 \quad \text{on } \partial \Omega, $$ where $\vec{n}(x)$ is the unit outward normal to $\partial \Omega$. This ensures mass conservation: $\int_{\Omega} p_t(x)\, dx = 1$ for all $t \geq 0$. |![fokker_planck_slope_limiter](https://hackmd.io/_uploads/S1F_BUJrel.gif)| | -------- | |Evolution of Fokker-Planck Equation with Quadratic Potential| ### Convergence to Equilibrium One of the questions that naturally arise from a dynamical systems point of view is regarding the long-term behavior of this equation: _Does $p_t \to p_\infty$ as $t \to \infty$ for some stationary distribution $p_{\infty}$?_ First, lets consider a simple case to motivate the computations based on Lyapunov ideas. #### Case 1: $U \equiv 0$ — the heat equation In this case the equation reduces to, $$ \partial_t p = \Delta p. $$ The following inequality is useful in this context: **Poincaré Inequality**: If $f \in L^2(\Omega)$ and $\Omega$ is connected with smooth boundary and bounded, there exists a constant $C > 0$ such that $$ \boxed{ \| f - f_\Omega \|_2^2 \leq C \|\nabla f\|_2^2 }, \quad \text{where } f_\Omega := \frac{1}{|\Omega|} \int_\Omega f(x)\, dx. $$ **Claim:** If $p_0 \geq 0$, $\int p_0 = 1$, and $U \equiv 0$, then $$ \|p_t - p_\infty\|_2 \leq e^{-t / C} \|p_0 - p_\infty\|_2, \quad \text{with } p_\infty = \frac{1}{|\Omega|}. $$ **Informal Proof:** Define a Lyapunov functional: $$ \mathcal{F}(p_t) = \int_\Omega (p_t - p_\infty)^2\, dx = \|p_t - p_\infty\|_{L^2}^2. $$ Then, $$ \frac{d}{dt} \mathcal{F}(p_t) = 2 \int_\Omega \partial_t p_t \cdot (p_t - p_\infty)\, dx = 2 \int_\Omega \Delta p_t \cdot (p_t - p_\infty)\, dx. $$ Using Green’s theorem and $\vec{n} \cdot \nabla p_t = 0$: $$ = -2 \int_\Omega |\nabla p_t|^2\, dx. $$ Apply the Poincaré inequality: $$ \|p_t - p_\infty\|_{L^2}^2 \leq C \|\nabla p_t\|_{L^2}^2 \Rightarrow \frac{d}{dt} \|p_t - p_\infty\|^2 \leq -\frac{2}{C} \|p_t - (p_t)_{\Omega}\|^2. $$ We know that $\int_{\Omega}p_tdx = (p_t)_{\Omega}=1$ for all $t>0$ (this can be seen more explicitly computing the time derivative $\frac{d}{dt} (p_t)_{\Omega}$ and applying integration by parts). This gives us, $$ \|p_t - p_\infty\|_{L^2}^2 \leq -\frac{2}{C} \|p_t - p_{\infty}\|^2. $$ Then Grönwall’s inequality gives, $$ \|p_t - p_\infty\|^2 \leq \|p_0 - p_\infty\|^2 \cdot e^{-2t / C}. $$ --- Next, we extend the idea to the more general situation. ### Case 2: General $U(x)$ In this case the stationary distribution is given by: $$ p_\infty(x) = \frac{1}{Z} e^{-U(x)}, \quad Z = \int_\Omega e^{-U(x)} dx. $$ To treat this more general case, the vanilla $L_2$ norm is no more sufficient to capture the asymptotic behavior. We define the **weighted $L^2$ norm**: $$ \|f\|_{L^2(p_\infty^{-1})} := \left( \int_\Omega \frac{|f(x)|^2}{p_\infty(x)}\, dx \right)^{1/2}. $$ If $U \in C^1(\bar{\Omega})$, then $p_\infty$ is bounded away from 0 and ∞, so $$ c_1 \|f\|_{L^2} \leq \|f\|_{L^2(p_\infty^{-1})} \leq c_2 \|f\|_{L^2}, $$ As a consequence one can establish the weighted **Poincaré inequality**, $$ \boxed{ \|f - f_{\Omega,{p_{\infty}}}\|_{L^2(p_\infty^{-1})} \leq C' \|\nabla f\|_{L^2(p_\infty^{-1})} }. $$ where $f_{\Omega,p_{\infty}} =\int_{\Omega} fp_{\infty}dx$ --- ### Stability via Lyapunov Functional Define: $$ \mathcal{F}(p_t) := \int_\Omega (f_t - 1)^2 p_\infty\, dx = \|p_t - p_\infty\|_{L^2(p_\infty^{-1})}^2, $$ where $f_t := \frac{p_t}{p_\infty}$. We compute th time derivative, $$ \frac{d}{dt} \mathcal{F}(p_t) = 2 \int_\Omega \partial_t f_t \cdot (f_t - 1)\, p_\infty \, dx. $$ The Fokker–Planck equation can be expressed as: $$ \partial_t p_t = \nabla \cdot \left( p_\infty \nabla \left( \frac{p_t}{p_\infty} \right) \right) = \nabla \cdot (p_\infty \nabla f_t). $$ So, $$ \partial_t f_t = \frac{1}{p_\infty} \nabla \cdot (p_\infty \nabla f_t). $$ We substitute this into the energy derivative: $$ \frac{d}{dt} \mathcal{F}(p_t) = 2 \int_\Omega \nabla \cdot (p_\infty \nabla f_t) \cdot (f_t - 1)\, dx. $$ Then by integration by parts (and zero-flux BC): $$ \frac{d}{dt} \mathcal{F}(p_t) = -2 \int_\Omega p_\infty |\nabla f_t|^2\, dx \leq -2M \int_\Omega \frac{|\nabla f_t|^2}{p_\infty}\, dx. $$ for some constant $M>0$ that depends on $p_{\infty}$. By the weighted Poincaré inequality, $$ \int_\Omega (f_t - 1)^2 p_\infty\, dx \leq C' \int_\Omega \frac{|\nabla f_t|^2}{p_\infty}\, dx, $$ so: $$ \frac{d}{dt} \mathcal{F}(p_t) \leq -\frac{2M}{C'} \mathcal{F}(p_t). $$ Again, Grönwall’s inequality gives, $$ \mathcal{F}(p_t) \leq e^{-2Mt/C'}\mathcal{F}(p_0) \cdot $$ Hence, we get exponential convergence in the weighted norm: $$ \boxed{ \|p_t - p_\infty\|_{L^2(p_\infty^{-1})} \leq e^{-Mt / C'}\|p_0 - p_\infty\|_{L^2(p_\infty^{-1})} } $$ This proves exponential stability of the Fokker–Planck equation in the weighted $L^2$ norm.