Appendix E: Differential Equations Cheat Sheet April 14, 2026
E.1 First-Order ODEs ¶ General form: x ˙ = f ( x , t ) \dot{x} = f(x, t) x ˙ = f ( x , t ) .
Type Form Solution method Separable x ˙ = g ( x ) h ( t ) \dot{x} = g(x)h(t) x ˙ = g ( x ) h ( t ) Separate: ∫ d x / g ( x ) = ∫ h ( t ) d t \int dx/g(x) = \int h(t)dt ∫ d x / g ( x ) = ∫ h ( t ) d t Linear x ˙ + p ( t ) x = q ( t ) \dot{x} + p(t)x = q(t) x ˙ + p ( t ) x = q ( t ) Integrating factor: μ = e ∫ p d t \mu = e^{\int p\,dt} μ = e ∫ p d t Bernoulli x ˙ + p ( t ) x = q ( t ) x n \dot{x} + p(t)x = q(t)x^n x ˙ + p ( t ) x = q ( t ) x n Substitute v = x 1 − n v=x^{1-n} v = x 1 − n → linear Autonomous x ˙ = f ( x ) \dot{x} = f(x) x ˙ = f ( x ) Phase line analysis; x ∗ x^* x ∗ where f ( x ∗ ) = 0 f(x^*)=0 f ( x ∗ ) = 0
Linear first-order (constant coefficients): x ˙ = a x + b \dot{x} = ax + b x ˙ = a x + b .
Stability: Linearize x ˙ = f ( x ) \dot{x} = f(x) x ˙ = f ( x ) at x ∗ x^* x ∗ : u ˙ ≈ f ′ ( x ∗ ) u \dot{u} \approx f'(x^*)u u ˙ ≈ f ′ ( x ∗ ) u . Stable iff f ′ ( x ∗ ) < 0 f'(x^*) < 0 f ′ ( x ∗ ) < 0 .
E.2 Second-Order ODEs ¶ Linear, constant coefficients: x ¨ + p x ˙ + q x = r \ddot{x} + p\dot{x} + qx = r x ¨ + p x ˙ + q x = r .
Characteristic equation: λ 2 + p λ + q = 0 \lambda^2 + p\lambda + q = 0 λ 2 + p λ + q = 0 , roots λ 1 , 2 = ( − p ± p 2 − 4 q ) / 2 \lambda_{1,2} = (-p \pm \sqrt{p^2-4q})/2 λ 1 , 2 = ( − p ± p 2 − 4 q ) /2 .
Case Roots General solution Distinct real (p 2 > 4 q p^2>4q p 2 > 4 q ) λ 1 ≠ λ 2 ∈ R \lambda_1\neq\lambda_2\in\mathbb{R} λ 1 = λ 2 ∈ R C 1 e λ 1 t + C 2 e λ 2 t + x ∗ C_1e^{\lambda_1 t}+C_2e^{\lambda_2 t}+x^* C 1 e λ 1 t + C 2 e λ 2 t + x ∗ Repeated (p 2 = 4 q p^2=4q p 2 = 4 q ) λ = − p / 2 \lambda = -p/2 λ = − p /2 ( C 1 + C 2 t ) e λ t + x ∗ (C_1+C_2 t)e^{\lambda t}+x^* ( C 1 + C 2 t ) e λ t + x ∗ Complex (p 2 < 4 q p^2<4q p 2 < 4 q ) λ = α ± i β \lambda = \alpha\pm i\beta λ = α ± i β e α t ( C 1 cos β t + C 2 sin β t ) + x ∗ e^{\alpha t}(C_1\cos\beta t + C_2\sin\beta t)+x^* e α t ( C 1 cos βt + C 2 sin βt ) + x ∗
where α = − p / 2 \alpha = -p/2 α = − p /2 , β = 4 q − p 2 / 2 \beta = \sqrt{4q-p^2}/2 β = 4 q − p 2 /2 , x ∗ = r / q x^* = r/q x ∗ = r / q (particular solution).
Stability: All trajectories → x ∗ x^* x ∗ iff Re ( λ i ) < 0 \text{Re}(\lambda_i) < 0 Re ( λ i ) < 0 for both roots.
E.3 Systems of ODEs ¶ Linear system: x ˙ = A x + b \dot{\mathbf{x}} = A\mathbf{x} + \mathbf{b} x ˙ = A x + b .
Steady state: x ∗ = − A − 1 b \mathbf{x}^* = -A^{-1}\mathbf{b} x ∗ = − A − 1 b (if A A A invertible).
General solution: x ( t ) = e A t ( x 0 − x ∗ ) + x ∗ \mathbf{x}(t) = e^{At}(\mathbf{x}_0 - \mathbf{x}^*) + \mathbf{x}^* x ( t ) = e A t ( x 0 − x ∗ ) + x ∗ .
Stable iff all eigenvalues of A A A have negative real parts.
Saddle point iff det ( A ) < 0 \det(A) < 0 det ( A ) < 0 (eigenvalues of mixed sign).
Phase portrait classification (2D system, eigenvalues λ 1 , λ 2 \lambda_1, \lambda_2 λ 1 , λ 2 ):
Eigenvalue type λ 1 , λ 2 < 0 \lambda_1, \lambda_2 < 0 λ 1 , λ 2 < 0 λ 1 < 0 < λ 2 \lambda_1 < 0 < \lambda_2 λ 1 < 0 < λ 2 λ 1 , λ 2 > 0 \lambda_1, \lambda_2 > 0 λ 1 , λ 2 > 0 Complex α ± i β \alpha\pm i\beta α ± i β , α < 0 \alpha < 0 α < 0 Type Stable node Saddle Unstable node Stable spiral
E.4 Pontryagin Conditions Summary ¶ For max u ( t ) ∫ 0 ∞ e − ρ t F ( x , u ) d t \max_{u(t)}\int_0^\infty e^{-\rho t}F(x,u)dt max u ( t ) ∫ 0 ∞ e − ρt F ( x , u ) d t s.t. x ˙ = f ( x , u ) \dot{x} = f(x,u) x ˙ = f ( x , u ) :
Condition Formula Interpretation Current-value Hamiltonian H = F ( x , u ) + μ f ( x , u ) \mathcal{H} = F(x,u) + \mu f(x,u) H = F ( x , u ) + μ f ( x , u ) utility + shadow value × rate of change Optimality (FOC) ∂ H / ∂ u = 0 \partial\mathcal{H}/\partial u = 0 ∂ H / ∂ u = 0 Maximize H \mathcal{H} H over u u u Costate equation μ ˙ = ρ μ − ∂ H / ∂ x \dot{\mu} = \rho\mu - \partial\mathcal{H}/\partial x μ ˙ = ρ μ − ∂ H / ∂ x Dynamics of shadow price State equation x ˙ = ∂ H / ∂ μ = f ( x , u ) \dot{x} = \partial\mathcal{H}/\partial\mu = f(x,u) x ˙ = ∂ H / ∂ μ = f ( x , u ) Law of motion Transversality lim t → ∞ e − ρ t μ ( t ) x ( t ) = 0 \lim_{t\to\infty}e^{-\rho t}\mu(t)x(t) = 0 lim t → ∞ e − ρt μ ( t ) x ( t ) = 0 No asymptotic rents
Key costate interpretation: μ ( t ) = ∂ V / ∂ x \mu(t) = \partial V/\partial x μ ( t ) = ∂ V / ∂ x (shadow price of state = marginal value of relaxing the constraint).
Appendix F: Difference Equations Cheat Sheet ¶ F.1 First-Order Difference Equations ¶ Linear: x t + 1 = a x t + b x_{t+1} = ax_t + b x t + 1 = a x t + b .
Steady state: x ∗ = b / ( 1 − a ) x^* = b/(1-a) x ∗ = b / ( 1 − a ) (a ≠ 1 a\neq1 a = 1 ).
General solution: x t = a t ( x 0 − x ∗ ) + x ∗ x_t = a^t(x_0-x^*) + x^* x t = a t ( x 0 − x ∗ ) + x ∗ .
Stable iff ∣ a ∣ < 1 |a| < 1 ∣ a ∣ < 1 .
Stability and behavior:
Condition Behavior 0 < a < 1 0 < a < 1 0 < a < 1 Monotone convergence to x ∗ x^* x ∗ − 1 < a < 0 -1 < a < 0 − 1 < a < 0 Oscillatory (damped) convergence a > 1 a > 1 a > 1 Monotone divergence a < − 1 a < -1 a < − 1 Oscillatory divergence
Forward-looking equation: x t = a E t [ x t + 1 ] + b z t x_t = a\mathbb{E}_t[x_{t+1}] + b z_t x t = a E t [ x t + 1 ] + b z t .
If ∣ a ∣ < 1 |a|<1 ∣ a ∣ < 1 : unique bounded solution x t = b ∑ j = 0 ∞ a j E t [ z t + j ] x_t = b\sum_{j=0}^\infty a^j\mathbb{E}_t[z_{t+j}] x t = b ∑ j = 0 ∞ a j E t [ z t + j ] .
If ∣ a ∣ > 1 |a|>1 ∣ a ∣ > 1 : MSV solution x t = b / ( 1 − a ρ z ) z t x_t = b/(1-a\rho_z)z_t x t = b / ( 1 − a ρ z ) z t plus possible sunspots.
F.2 Second-Order Difference Equations ¶ Linear: x t + 2 + p x t + 1 + q x t = c x_{t+2} + px_{t+1} + qx_t = c x t + 2 + p x t + 1 + q x t = c .
Characteristic equation: λ 2 + p λ + q = 0 \lambda^2 + p\lambda + q = 0 λ 2 + p λ + q = 0 , roots λ 1 , 2 = ( − p ± p 2 − 4 q ) / 2 \lambda_{1,2} = (-p\pm\sqrt{p^2-4q})/2 λ 1 , 2 = ( − p ± p 2 − 4 q ) /2 .
Stability conditions: ∣ a ∣ < 1 + q |a| < 1+q ∣ a ∣ < 1 + q AND q < 1 q < 1 q < 1 (Schur–Cohn conditions — necessary and sufficient).
Root type Discriminant Solution form Real, distinct p 2 > 4 q p^2 > 4q p 2 > 4 q C 1 λ 1 t + C 2 λ 2 t + x ∗ C_1\lambda_1^t + C_2\lambda_2^t + x^* C 1 λ 1 t + C 2 λ 2 t + x ∗ Real, equal p 2 = 4 q p^2 = 4q p 2 = 4 q ( C 1 + C 2 t ) λ t + x ∗ (C_1+C_2t)\lambda^t + x^* ( C 1 + C 2 t ) λ t + x ∗ Complex p 2 < 4 q p^2 < 4q p 2 < 4 q , r = q r=\sqrt{q} r = q , θ = arccos ( − p / ( 2 r ) ) \theta=\arccos(-p/(2r)) θ = arccos ( − p / ( 2 r )) r t ( C 1 cos θ t + C 2 sin θ t ) + x ∗ r^t(C_1\cos\theta t+C_2\sin\theta t)+x^* r t ( C 1 cos θt + C 2 sin θt ) + x ∗
Oscillation period (complex case): T = 2 π / θ T = 2\pi/\theta T = 2 π / θ periods.
F.3 Systems of Difference Equations ¶ Linear system: x t + 1 = A x t + b \mathbf{x}_{t+1} = A\mathbf{x}_t + \mathbf{b} x t + 1 = A x t + b .
Steady state: x ∗ = ( I − A ) − 1 b \mathbf{x}^* = (I-A)^{-1}\mathbf{b} x ∗ = ( I − A ) − 1 b .
General solution: x t = A t ( x 0 − x ∗ ) + x ∗ \mathbf{x}_t = A^t(\mathbf{x}_0-\mathbf{x}^*)+\mathbf{x}^* x t = A t ( x 0 − x ∗ ) + x ∗ .
Stable iff all eigenvalues of A A A satisfy ∣ λ i ∣ < 1 |\lambda_i| < 1 ∣ λ i ∣ < 1 .
IRF at horizon h h h : A h − 1 b A^{h-1}\mathbf{b} A h − 1 b (response to unit impulse).
Companion form. Convert p p p -th order scalar system to first-order system with companion matrix:
A = ( a 1 a 2 ⋯ a p 1 0 ⋯ 0 0 1 ⋯ 0 ⋮ ⋱ ⋮ ) . A = \begin{pmatrix}a_1 & a_2 & \cdots & a_p \\ 1 & 0 & \cdots & 0 \\ 0 & 1 & \cdots & 0 \\ \vdots & & \ddots & \vdots \end{pmatrix}. A = ⎝ ⎛ a 1 1 0 ⋮ a 2 0 1 ⋯ ⋯ ⋯ ⋱ a p 0 0 ⋮ ⎠ ⎞ . Eigenvalues of A A A are the roots of the characteristic polynomial.
F.4 Blanchard–Kahn Counting Rule ¶ For the linearized DSGE Γ 0 y t = Γ 1 y t − 1 + Ψ z t + Π η t \Gamma_0\mathbf{y}_t = \Gamma_1\mathbf{y}_{t-1}+\Psi\mathbf{z}_t+\Pi\boldsymbol\eta_t Γ 0 y t = Γ 1 y t − 1 + Ψ z t + Π η t :
Unstable eigenvalues Jump variables (n f n_f n f ) Outcome = n f = n_f = n f Match Unique bounded solution ✓< n f < n_f < n f Too few Indeterminate (sunspots possible)> n f > n_f > n f Too many No bounded solution
F.5 MSV Solution Procedure Summary ¶ For y t = A E t [ y t + 1 ] + C z t \mathbf{y}_t = A\mathbb{E}_t[\mathbf{y}_{t+1}] + C\mathbf{z}_t y t = A E t [ y t + 1 ] + C z t with z t = Φ z t − 1 + ε t \mathbf{z}_t = \Phi\mathbf{z}_{t-1} + \boldsymbol\varepsilon_t z t = Φ z t − 1 + ε t :
Conjecture: y t = Ω z t \mathbf{y}_t = \Omega\mathbf{z}_t y t = Ω z t .
Substitute: Ω z t = A Ω Φ z t + C z t \Omega\mathbf{z}_t = A\Omega\Phi\mathbf{z}_t + C\mathbf{z}_t Ω z t = A ΩΦ z t + C z t .
Sylvester equation: Ω − A Ω Φ = C \Omega - A\Omega\Phi = C Ω − A ΩΦ = C .
Vectorize: vec ( Ω ) = ( I − Φ ′ ⊗ A ) − 1 vec ( C ) \text{vec}(\Omega) = (I-\Phi'\otimes A)^{-1}\text{vec}(C) vec ( Ω ) = ( I − Φ ′ ⊗ A ) − 1 vec ( C ) .
Verify: All eigenvalues of A A A outside unit circle iff unique bounded solution.
Appendix G: Time Series Concepts Summary ¶ G.1 Stationarity ¶ Strict stationarity. { y t } \{y_t\} { y t } is strictly stationary if the joint distribution of ( y t 1 , … , y t k ) (y_{t_1},\ldots,y_{t_k}) ( y t 1 , … , y t k ) equals that of ( y t 1 + h , … , y t k + h ) (y_{t_1+h},\ldots,y_{t_k+h}) ( y t 1 + h , … , y t k + h ) for all k k k , h h h , and time indices.
Covariance (weak) stationarity. E [ y t ] = μ \mathbb{E}[y_t] = \mu E [ y t ] = μ (constant), Cov ( y t , y t − j ) = γ j \text{Cov}(y_t, y_{t-j}) = \gamma_j Cov ( y t , y t − j ) = γ j (depends only on lag j j j ).
Key distinction: Strict ⇒ \Rightarrow ⇒ weak stationarity (for finite variance processes). Weak ⇏ \not\Rightarrow ⇒ strict.
Integrated processes. y t ∼ I ( d ) y_t \sim I(d) y t ∼ I ( d ) : d d d -th difference is stationary. Most macro levels: I ( 1 ) I(1) I ( 1 ) ; growth rates: I ( 0 ) I(0) I ( 0 ) .
G.2 ARMA Representations ¶ AR(p p p ): y t = ∑ j = 1 p ϕ j y t − j + ε t y_t = \sum_{j=1}^p\phi_jy_{t-j} + \varepsilon_t y t = ∑ j = 1 p ϕ j y t − j + ε t . Stationary iff all roots of 1 − ϕ 1 z − ⋯ − ϕ p z p 1-\phi_1z-\cdots-\phi_pz^p 1 − ϕ 1 z − ⋯ − ϕ p z p lie outside the unit circle.
MA(q q q ): y t = ∑ j = 0 q θ j ε t − j y_t = \sum_{j=0}^q\theta_j\varepsilon_{t-j} y t = ∑ j = 0 q θ j ε t − j . Always stationary.
ARMA(p , q p,q p , q ): Combines both. Autocovariance: γ j = Cov ( y t , y t − j ) \gamma_j = \text{Cov}(y_t, y_{t-j}) γ j = Cov ( y t , y t − j ) depends on j j j only.
Wold decomposition. Any zero-mean I ( 0 ) I(0) I ( 0 ) process: y t = ∑ j = 0 ∞ ψ j ε t − j y_t = \sum_{j=0}^\infty\psi_j\varepsilon_{t-j} y t = ∑ j = 0 ∞ ψ j ε t − j (MA(∞ \infty ∞ )) with ∑ ψ j 2 < ∞ \sum\psi_j^2<\infty ∑ ψ j 2 < ∞ . Long-run multiplier: ψ ( 1 ) = ∑ ψ j \psi(1) = \sum\psi_j ψ ( 1 ) = ∑ ψ j .
G.3 VAR Models ¶ VAR(p p p ): y t = c + ∑ j = 1 p A j y t − j + e t \mathbf{y}_t = \mathbf{c}+\sum_{j=1}^pA_j\mathbf{y}_{t-j}+\mathbf{e}_t y t = c + ∑ j = 1 p A j y t − j + e t .
OLS estimation: B ^ = ( X ′ X ) − 1 X ′ Y \hat{B} = (X'X)^{-1}X'Y B ^ = ( X ′ X ) − 1 X ′ Y — APL: B ← (⌹ X) +.× Y.
Lag selection criteria:
Criterion Formula AIC $\ln BIC $\ln HQ $\ln
BIC consistent; AIC better for forecasting.
Granger causality. x t x_t x t Granger-causes y t y_t y t iff A y x , j ≠ 0 A_{yx,j}\neq0 A y x , j = 0 for some lag j j j — test via F-test on the restricted vs. unrestricted VAR equations.
G.4 Structural VAR Identification ¶ Identification schemes (additional restrictions beyond Σ = B 0 − 1 ( B 0 − 1 ) ′ \Sigma = B_0^{-1}(B_0^{-1})' Σ = B 0 − 1 ( B 0 − 1 ) ′ ):
Method Restrictions Advantage Cholesky Lower triangular B 0 B_0 B 0 Simple; just-identified Long-run A ( 1 ) A(1) A ( 1 ) matrix restrictionsStructural economic restrictions Sign restrictions IRF signs only Robust; set-identified External instrument Proxy z t z_t z t correlated with one shock No ordering assumption
IRF: Response of variable i i i to shock j j j at horizon h h h : ( A c o m p h ⋅ B 0 − 1 ) i j (A^h_{comp}\cdot B_0^{-1})_{ij} ( A co m p h ⋅ B 0 − 1 ) ij .
FEVD: Fraction of h h h -step MSE of variable i i i due to shock j j j : ∑ k = 0 h − 1 ( Ψ k B 0 − 1 ) i j 2 / MSE i ( h ) \sum_{k=0}^{h-1}(\Psi_k B_0^{-1})_{ij}^2/\text{MSE}_i(h) ∑ k = 0 h − 1 ( Ψ k B 0 − 1 ) ij 2 / MSE i ( h ) .
G.5 Cointegration ¶ Engle–Granger two-step:
OLS: β ^ = ( X ′ X ) − 1 X ′ Y \hat\beta = (X'X)^{-1}X'Y β ^ = ( X ′ X ) − 1 X ′ Y (super-consistent, converges at rate T T T ).
ADF test on residuals u ^ t = y t − β ^ x t \hat{u}_t = y_t - \hat\beta x_t u ^ t = y t − β ^ x t .
Johansen trace statistic: Λ t r a c e ( r ) = − T ∑ i = r + 1 n ln ( 1 − λ ^ i ) \Lambda_{trace}(r) = -T\sum_{i=r+1}^n\ln(1-\hat\lambda_i) Λ t r a ce ( r ) = − T ∑ i = r + 1 n ln ( 1 − λ ^ i ) .
Error correction (VECM): Δ y t = α β ′ y t − 1 + ∑ j = 1 p − 1 Γ j Δ y t − j + ε t \Delta\mathbf{y}_t = \alpha\beta'\mathbf{y}_{t-1}+\sum_{j=1}^{p-1}\Gamma_j\Delta\mathbf{y}_{t-j}+\boldsymbol\varepsilon_t Δ y t = α β ′ y t − 1 + ∑ j = 1 p − 1 Γ j Δ y t − j + ε t , where β \beta β = cointegrating vectors, α \alpha α = adjustment speeds.
G.6 Key Test Statistics ¶ Test Statistic Distribution under H 0 H_0 H 0 Purpose ADF t γ ^ t_{\hat\gamma} t γ ^ in augmented regressionDF distribution (non-standard) Unit root Johansen trace − T ∑ ln ( 1 − λ ^ i ) -T\sum\ln(1-\hat\lambda_i) − T ∑ ln ( 1 − λ ^ i ) Non-standard Cointegration rank Diebold–Mariano d ˉ / V ^ / N \bar{d}/\sqrt{\hat V/N} d ˉ / V ^ / N N ( 0 , 1 ) \mathcal{N}(0,1) N ( 0 , 1 ) Forecast accuracy Ljung–Box T ( T + 2 ) ∑ j = 1 m ρ ^ j 2 / ( T − j ) T(T+2)\sum_{j=1}^m\hat\rho_j^2/(T-j) T ( T + 2 ) ∑ j = 1 m ρ ^ j 2 / ( T − j ) χ 2 ( m ) \chi^2(m) χ 2 ( m ) Serial correlation Granger causality F F F -statistic on excluded lagsF ( p , T − 2 p − 1 ) F(p,T-2p-1) F ( p , T − 2 p − 1 ) Granger causality