Skip to content

Split View: 공업수학 완전 정복 1편: 상미분방정식(ODE) - 기초부터 라플라스 변환까지

|

공업수학 완전 정복 1편: 상미분방정식(ODE) - 기초부터 라플라스 변환까지

공업수학 완전 정복 1편: 상미분방정식(ODE)

공학도라면 피해갈 수 없는 과목이 바로 공업수학입니다. 특히 상미분방정식(ODE, Ordinary Differential Equation)은 전자회로 분석, 제어 시스템 설계, 기계 진동 해석 등 거의 모든 공학 분야의 수학적 기반이 됩니다. 이 글에서는 ODE의 기초 개념부터 라플라스 변환까지, 공학 응용 예제를 중심으로 체계적으로 설명합니다.


1. 미분방정식 기초

미분방정식이란?

미분방정식은 미지함수와 그 도함수들 사이의 관계를 나타내는 방정식입니다. 예를 들어:

dydx=2x,y+3y+2y=0,ut=k2ux2\frac{dy}{dx} = 2x, \quad y'' + 3y' + 2y = 0, \quad \frac{\partial u}{\partial t} = k\frac{\partial^2 u}{\partial x^2}

이처럼 미분방정식은 자연 현상과 공학 시스템을 수학적으로 모델링하는 핵심 도구입니다.

분류: ODE vs PDE

상미분방정식(ODE): 하나의 독립변수에 대한 도함수만 포함합니다.

d2xdt2+2dxdt+x=0\frac{d^2x}{dt^2} + 2\frac{dx}{dt} + x = 0

편미분방정식(PDE): 두 개 이상의 독립변수에 대한 편미분을 포함합니다.

ut=c22ux2\frac{\partial u}{\partial t} = c^2\frac{\partial^2 u}{\partial x^2}

이번 글에서는 ODE에 집중합니다.

차수(Order)와 급(Degree)

차수는 방정식에 등장하는 가장 높은 도함수의 차수입니다.

  • 1차 ODE: y+y=xy' + y = x (최고 도함수가 yy')
  • 2차 ODE: y+2y+y=0y'' + 2y' + y = 0 (최고 도함수가 yy'')

**급(degree)**은 최고 차수 도함수의 지수입니다. 대부분의 공학 문제에서 급은 1입니다.

선형 vs 비선형

선형 ODE: 미지함수와 그 도함수가 1차 항으로만 나타납니다.

an(x)y(n)+an1(x)y(n1)++a1(x)y+a0(x)y=f(x)a_n(x)y^{(n)} + a_{n-1}(x)y^{(n-1)} + \cdots + a_1(x)y' + a_0(x)y = f(x)

비선형 ODE: y2y^2, yyy \cdot y', sin(y)\sin(y) 등 비선형 항이 포함됩니다.

y+sin(y)=0(진자 방정식)y'' + \sin(y) = 0 \quad \text{(진자 방정식)}

일반해, 특수해, 특이해

  • 일반해: 임의의 상수를 포함하는 완전한 해
  • 특수해: 초기조건을 적용하여 상수를 결정한 해
  • 특이해: 일반해로부터 얻을 수 없는 특별한 해

공학에서 ODE의 등장

공학 시스템은 대부분 ODE로 기술됩니다.

RC 충전 회로: RCdvdt+v=VsRC\frac{dv}{dt} + v = V_s

스프링-질량-감쇠기 시스템: mx¨+cx˙+kx=F(t)m\ddot{x} + c\dot{x} + kx = F(t)

인구 성장 모델: dPdt=kP\frac{dP}{dt} = kP

RL 회로: Ldidt+Ri=E(t)L\frac{di}{dt} + Ri = E(t)

이 모든 방정식이 ODE이며, 풀이 방법을 배우면 공학 시스템의 동적 거동을 완전히 분석할 수 있습니다.


2. 1차 상미분방정식

2.1 변수분리법 (Separation of Variables)

형태: dydx=f(x)g(y)\frac{dy}{dx} = f(x)g(y)

풀이 과정:

dyg(y)=f(x)dx\frac{dy}{g(y)} = f(x)dx

양변을 적분합니다:

dyg(y)=f(x)dx+C\int \frac{dy}{g(y)} = \int f(x)dx + C

예제: RC 충전 회로

회로 방정식: dvdt=VsvRC\frac{dv}{dt} = \frac{V_s - v}{RC}

변수분리: dvVsv=dtRC\frac{dv}{V_s - v} = \frac{dt}{RC}

적분: lnVsv=tRC+C1-\ln|V_s - v| = \frac{t}{RC} + C_1

초기조건 v(0)=0v(0) = 0 적용:

Vsv=Vset/(RC)V_s - v = V_s e^{-t/(RC)}

v(t)=Vs(1et/(RC))\boxed{v(t) = V_s\left(1 - e^{-t/(RC)}\right)}

이 결과는 RC 회로의 **과도 응답(transient response)**을 나타냅니다. 시정수 τ=RC\tau = RC로 결정되는 속도로 전압이 VsV_s로 수렴합니다.

물리적 의미:

  • t=τt = \tau일 때: v0.632Vsv \approx 0.632 V_s (63.2% 충전)
  • t=5τt = 5\tau일 때: v0.993Vsv \approx 0.993 V_s (거의 완전 충전)

2.2 적분인자법 (Integrating Factor Method)

선형 1차 ODE의 표준형: dydx+P(x)y=Q(x)\frac{dy}{dx} + P(x)y = Q(x)

적분인자: μ(x)=eP(x)dx\mu(x) = e^{\int P(x)dx}

유도 과정:

양변에 μ(x)\mu(x)를 곱합니다: μ(x)dydx+μ(x)P(x)y=μ(x)Q(x)\mu(x)\frac{dy}{dx} + \mu(x)P(x)y = \mu(x)Q(x)

좌변은 곱의 미분 규칙에 의해: ddx[μ(x)y]=μ(x)Q(x)\frac{d}{dx}[\mu(x)y] = \mu(x)Q(x)

적분하면: μ(x)y=μ(x)Q(x)dx+C\mu(x)y = \int \mu(x)Q(x)dx + C

y=1μ(x)[μ(x)Q(x)dx+C]\boxed{y = \frac{1}{\mu(x)}\left[\int \mu(x)Q(x)dx + C\right]}

예제: RL 회로

Ldidt+Ri=EL\frac{di}{dt} + Ri = E

표준형으로 변환: didt+RLi=EL\frac{di}{dt} + \frac{R}{L}i = \frac{E}{L}

적분인자: μ(t)=e(R/L)t\mu(t) = e^{(R/L)t}

ddt[e(R/L)ti]=ELe(R/L)t\frac{d}{dt}\left[e^{(R/L)t} \cdot i\right] = \frac{E}{L}e^{(R/L)t}

적분: e(R/L)ti=ERe(R/L)t+Ce^{(R/L)t} \cdot i = \frac{E}{R}e^{(R/L)t} + C

초기조건 i(0)=0i(0) = 0 적용:

i(t)=ER(1e(R/L)t)\boxed{i(t) = \frac{E}{R}\left(1 - e^{-(R/L)t}\right)}

시정수 τ=L/R\tau = L/R로 전류가 정상 상태 E/RE/R에 수렴합니다.

2.3 완전 미분방정식 (Exact ODE)

형태: M(x,y)dx+N(x,y)dy=0M(x,y)dx + N(x,y)dy = 0

완전 조건: My=Nx\frac{\partial M}{\partial y} = \frac{\partial N}{\partial x}

이 조건을 만족하면 F(x,y)=CF(x,y) = C인 퍼텐셜 함수 FF가 존재합니다.

풀이법:

  1. Fx=M\frac{\partial F}{\partial x} = M에서 FFxx에 대해 적분
  2. Fy=N\frac{\partial F}{\partial y} = N 조건으로 적분 상수 결정
  3. 일반해: F(x,y)=CF(x,y) = C

예제:

(2xy+y2)dx+(x2+2xy)dy=0(2xy + y^2)dx + (x^2 + 2xy)dy = 0

완전 여부 확인: My=2x+2y=Nx\frac{\partial M}{\partial y} = 2x + 2y = \frac{\partial N}{\partial x}

완전 방정식이므로: F=Mdx=(2xy+y2)dx=x2y+xy2+g(y)F = \int M\,dx = \int (2xy + y^2)dx = x^2y + xy^2 + g(y)

Fy=x2+2xy+g(y)=N=x2+2xy\frac{\partial F}{\partial y} = x^2 + 2xy + g'(y) = N = x^2 + 2xy이므로 g(y)=0g'(y) = 0, g(y)=Cg(y) = C

일반해: x2y+xy2=Cx^2y + xy^2 = C

2.4 베르누이 방정식 (Bernoulli Equation)

형태: dydx+P(x)y=Q(x)yn(n0,1)\frac{dy}{dx} + P(x)y = Q(x)y^n \quad (n \neq 0, 1)

치환: v=y1nv = y^{1-n}으로 놓으면 선형 ODE로 변환됩니다.

v=(1n)ynyv' = (1-n)y^{-n}y'이므로 원래 방정식을 yny^n으로 나누면:

yndydx+P(x)y1n=Q(x)y^{-n}\frac{dy}{dx} + P(x)y^{1-n} = Q(x)

11ndvdx+P(x)v=Q(x)\frac{1}{1-n}\frac{dv}{dx} + P(x)v = Q(x)

dvdx+(1n)P(x)v=(1n)Q(x)\frac{dv}{dx} + (1-n)P(x)v = (1-n)Q(x)

이는 vv에 대한 선형 1차 ODE로, 적분인자법으로 풀 수 있습니다.

응용: 물류 성장 모델 dPdt=rP(1PK)\frac{dP}{dt} = rP\left(1 - \frac{P}{K}\right)n=2n=2인 베르누이 방정식입니다.


3. 2차 선형 상미분방정식

3.1 제차 방정식 (Homogeneous)

표준형: ay+by+cy=0ay'' + by' + cy = 0

특성방정식 유도: y=erxy = e^{rx}를 대입합니다.

ar2erx+brerx+cerx=0a r^2 e^{rx} + b r e^{rx} + c e^{rx} = 0

ar2+br+c=0\boxed{ar^2 + br + c = 0}

판별식 Δ=b24ac\Delta = b^2 - 4ac의 부호에 따라 세 가지 경우가 생깁니다.

경우 1: 서로 다른 두 실근 (Δ>0\Delta > 0)

r1r2r_1 \neq r_2이면: y=C1er1x+C2er2xy = C_1 e^{r_1 x} + C_2 e^{r_2 x}

경우 2: 중복 실근 (Δ=0\Delta = 0)

r1=r2=r=b/(2a)r_1 = r_2 = r = -b/(2a)이면: y=(C1+C2x)erxy = (C_1 + C_2 x)e^{rx}

C2xerxC_2 x e^{rx}를 추가해야 하는 이유는 **론스키안(Wronskian)**이 0이 되지 않도록 독립적인 두 번째 해를 구성해야 하기 때문입니다.

경우 3: 켤레 복소근 (Δ<0\Delta < 0)

r=α±iβr = \alpha \pm i\beta (단, α=b/(2a)\alpha = -b/(2a), β=4acb2/(2a)\beta = \sqrt{4ac - b^2}/(2a))이면: y=eαx(C1cosβx+C2sinβx)y = e^{\alpha x}(C_1\cos\beta x + C_2\sin\beta x)

오일러 공식 eiβx=cosβx+isinβxe^{i\beta x} = \cos\beta x + i\sin\beta x를 이용해 실수해로 변환한 형태입니다.

3.2 RLC 회로 완전 분석

회로 방정식 (전하 q(t)q(t) 기준): Ld2qdt2+Rdqdt+qC=0L\frac{d^2q}{dt^2} + R\frac{dq}{dt} + \frac{q}{C} = 0

표준형으로 정리: q+RLq+1LCq=0q'' + \frac{R}{L}q' + \frac{1}{LC}q = 0

특성방정식: r2+RLr+1LC=0r^2 + \frac{R}{L}r + \frac{1}{LC} = 0

r=R2L±(R2L)21LCr = -\frac{R}{2L} \pm \sqrt{\left(\frac{R}{2L}\right)^2 - \frac{1}{LC}}

감쇠 계수 α=R/(2L)\alpha = R/(2L), 공진 주파수 ω0=1/LC\omega_0 = 1/\sqrt{LC}로 정의하면:

r=α±α2ω02r = -\alpha \pm \sqrt{\alpha^2 - \omega_0^2}

과감쇠 (Overdamped): α>ω0\alpha > \omega_0 (R>2L/CR > 2\sqrt{L/C})

q(t)=C1er1t+C2er2t(r1,r2<0)q(t) = C_1 e^{r_1 t} + C_2 e^{r_2 t} \quad (r_1, r_2 < 0)

두 지수항의 합으로, 진동 없이 단조 감소합니다.

임계감쇠 (Critically Damped): α=ω0\alpha = \omega_0 (R=2L/CR = 2\sqrt{L/C})

q(t)=(C1+C2t)eαtq(t) = (C_1 + C_2 t)e^{-\alpha t}

진동 없이 가장 빠르게 평형 상태로 복귀합니다. 제어 시스템 설계에서 매우 중요합니다.

부족감쇠 (Underdamped): α<ω0\alpha < \omega_0 (R<2L/CR < 2\sqrt{L/C})

감쇠 진동 주파수 ωd=ω02α2\omega_d = \sqrt{\omega_0^2 - \alpha^2}로 정의하면:

q(t)=eαt(C1cosωdt+C2sinωdt)q(t) = e^{-\alpha t}(C_1\cos\omega_d t + C_2\sin\omega_d t)

진동하면서 감쇠합니다. 통신 회로, 진동 시스템에서 흔히 나타납니다.

물리적 의미 요약:

조건명칭응답 특성
R>2L/CR > 2\sqrt{L/C}과감쇠진동 없이 느리게 감쇠
R=2L/CR = 2\sqrt{L/C}임계감쇠진동 없이 가장 빠른 감쇠
R<2L/CR < 2\sqrt{L/C}부족감쇠진동하며 감쇠
R=0R = 0무감쇠지속 진동

3.3 비제차 방정식 (Non-homogeneous)

형태: ay+by+cy=f(x)ay'' + by' + cy = f(x)

완전 해: y=yh+ypy = y_h + y_p

  • yhy_h: 제차 방정식의 일반해 (여함수, complementary function)
  • ypy_p: 특수해 (particular solution)

미결정계수법 (Method of Undetermined Coefficients)

f(x)f(x)의 형태에 따라 ypy_p의 형태를 추측합니다.

f(x)f(x)의 형태ypy_p의 추측 형태
keaxke^{ax}AeaxAe^{ax}
kxnkx^nAnxn++A1x+A0A_n x^n + \cdots + A_1 x + A_0
kcosωxk\cos\omega x 또는 ksinωxk\sin\omega xAcosωx+BsinωxA\cos\omega x + B\sin\omega x
keaxcosωxke^{ax}\cos\omega xeax(Acosωx+Bsinωx)e^{ax}(A\cos\omega x + B\sin\omega x)

주의: ypy_p의 형태가 yhy_h의 항과 겹치면 xx를 곱해서 수정합니다.

예제: y+4y=3cos2xy'' + 4y = 3\cos 2x

제차해: yh=C1cos2x+C2sin2xy_h = C_1\cos 2x + C_2\sin 2x

ypy_p의 추측형이 yhy_h와 겹치므로 수정: yp=x(Acos2x+Bsin2x)y_p = x(A\cos 2x + B\sin 2x)

대입 후 계산하면: A=0A = 0, B=3/4B = 3/4

yp=34xsin2xy_p = \frac{3}{4}x\sin 2x

이는 공진(resonance) 현상으로, 진폭이 시간에 비례하여 증가합니다.

강제 진동 응답:

mx¨+cx˙+kx=F0cosωtm\ddot{x} + c\dot{x} + kx = F_0\cos\omega t

정상 상태 특수해: xp(t)=F0/k(1r2)2+(2ζr)2cos(ωtϕ)x_p(t) = \frac{F_0/k}{\sqrt{(1-r^2)^2 + (2\zeta r)^2}}\cos(\omega t - \phi)

여기서 진동수비 r=ω/ωnr = \omega/\omega_n, 감쇠비 ζ=c/(2mk)\zeta = c/(2\sqrt{mk}).

r=1r = 1 (공진 조건)에서 진폭이 최대가 됩니다.

매개변수 변환법 (Variation of Parameters)

미결정계수법을 적용할 수 없는 일반적인 f(x)f(x)에 사용합니다.

yh=C1y1+C2y2y_h = C_1 y_1 + C_2 y_2가 주어질 때:

yp=y1y2fWdx+y2y1fWdxy_p = -y_1 \int \frac{y_2 f}{W}dx + y_2 \int \frac{y_1 f}{W}dx

론스키안(Wronskian): W=y1y2y1y2W = y_1 y_2' - y_1' y_2

이 공식은 모든 연속 함수 f(x)f(x)에 대해 적용 가능합니다.


4. 연립 미분방정식

4.1 행렬 표현

nn개의 1차 ODE로 이루어진 연립 방정식:

dXdt=AX\frac{d\mathbf{X}}{dt} = A\mathbf{X}

여기서 X=[x1,x2,,xn]T\mathbf{X} = [x_1, x_2, \ldots, x_n]^T, AAn×nn \times n 계수 행렬.

4.2 고유값/고유벡터 풀이

해의 형태: X=veλt\mathbf{X} = \mathbf{v}e^{\lambda t}

대입하면: λv=Av\lambda \mathbf{v} = A\mathbf{v}

즉, λ\lambdaAA고유값, v\mathbf{v}는 대응하는 고유벡터입니다.

특성방정식: det(AλI)=0\det(A - \lambda I) = 0

예제: 두 개의 연결된 탱크 시스템

ddt(x1x2)=(2112)(x1x2)\frac{d}{dt}\begin{pmatrix} x_1 \\ x_2 \end{pmatrix} = \begin{pmatrix} -2 & 1 \\ 1 & -2 \end{pmatrix}\begin{pmatrix} x_1 \\ x_2 \end{pmatrix}

특성방정식: (λ+2)21=0(\lambda+2)^2 - 1 = 0

λ1=1,λ2=3\lambda_1 = -1, \quad \lambda_2 = -3

고유벡터: v1=[1,1]T\mathbf{v}_1 = [1, 1]^T, v2=[1,1]T\mathbf{v}_2 = [1, -1]^T

일반해: X=C1(11)et+C2(11)e3t\mathbf{X} = C_1 \begin{pmatrix} 1 \\ 1 \end{pmatrix} e^{-t} + C_2 \begin{pmatrix} 1 \\ -1 \end{pmatrix} e^{-3t}

4.3 회로망 해석 적용

두 루프가 있는 회로 (키르히호프 전압 법칙):

L1di1dt+R1i1Mdi2dt=E1(t)L_1\frac{di_1}{dt} + R_1 i_1 - M\frac{di_2}{dt} = E_1(t) L2di2dt+R2i2Mdi1dt=E2(t)L_2\frac{di_2}{dt} + R_2 i_2 - M\frac{di_1}{dt} = E_2(t)

여기서 MM은 상호 인덕턴스. 이를 행렬 형태로 정리하여 고유값법 또는 라플라스 변환으로 풀 수 있습니다.


5. 라플라스 변환 (Laplace Transform)

5.1 정의와 수렴

정의: L{f(t)}=F(s)=0f(t)estdt\mathcal{L}\{f(t)\} = F(s) = \int_0^\infty f(t)e^{-st}dt

s=σ+jωs = \sigma + j\omega는 복소 변수이며, 적분이 수렴하려면 Re(s)>σc\text{Re}(s) > \sigma_c (수렴 좌평면)를 만족해야 합니다.

왜 라플라스 변환을 쓰는가?

  • 미분 연산이 대수 연산으로 변환됩니다
  • 초기조건을 자동으로 처리합니다
  • 복잡한 ODE를 쉬운 대수 방정식으로 풀 수 있습니다
  • 전달 함수(Transfer Function) 개념의 기반입니다

5.2 주요 변환쌍

f(t)f(t)F(s)=L{f(t)}F(s) = \mathcal{L}\{f(t)\}
11 (단위 계단)1s\dfrac{1}{s}
tt1s2\dfrac{1}{s^2}
tnt^nn!sn+1\dfrac{n!}{s^{n+1}}
eate^{at}1sa\dfrac{1}{s-a}
sinωt\sin\omega tωs2+ω2\dfrac{\omega}{s^2+\omega^2}
cosωt\cos\omega tss2+ω2\dfrac{s}{s^2+\omega^2}
eatsinωte^{at}\sin\omega tω(sa)2+ω2\dfrac{\omega}{(s-a)^2+\omega^2}
eatcosωte^{at}\cos\omega tsa(sa)2+ω2\dfrac{s-a}{(s-a)^2+\omega^2}
δ(t)\delta(t) (임펄스)11
u(ta)u(t-a) (지연 계단)eass\dfrac{e^{-as}}{s}

유도 예시: L{eat}\mathcal{L}\{e^{at}\}

L{eat}=0eatestdt=0e(sa)tdt=[e(sa)t(sa)]0=1sa\mathcal{L}\{e^{at}\} = \int_0^\infty e^{at} e^{-st} dt = \int_0^\infty e^{-(s-a)t} dt = \left[\frac{e^{-(s-a)t}}{-(s-a)}\right]_0^\infty = \frac{1}{s-a}

s>as > a일 때 수렴합니다.

5.3 주요 성질

선형성: L{af(t)+bg(t)}=aF(s)+bG(s)\mathcal{L}\{af(t) + bg(t)\} = aF(s) + bG(s)

시간 이동 (제1 이동 정리): L{eatf(t)}=F(sa)\mathcal{L}\{e^{at}f(t)\} = F(s-a)

주파수 이동 (제2 이동 정리): L{f(ta)u(ta)}=easF(s)\mathcal{L}\{f(t-a)u(t-a)\} = e^{-as}F(s)

미분 변환 (가장 중요한 성질): L{f(t)}=sF(s)f(0)\mathcal{L}\{f'(t)\} = sF(s) - f(0) L{f(t)}=s2F(s)sf(0)f(0)\mathcal{L}\{f''(t)\} = s^2F(s) - sf(0) - f'(0) L{f(n)(t)}=snF(s)sn1f(0)sn2f(0)f(n1)(0)\mathcal{L}\{f^{(n)}(t)\} = s^nF(s) - s^{n-1}f(0) - s^{n-2}f'(0) - \cdots - f^{(n-1)}(0)

초기조건이 ss-도메인에서 자동으로 포함됩니다.

적분 변환: L{0tf(τ)dτ}=F(s)s\mathcal{L}\left\{\int_0^t f(\tau)d\tau\right\} = \frac{F(s)}{s}

합성곱 정리(Convolution Theorem): L{(fg)(t)}=F(s)G(s)\mathcal{L}\{(f*g)(t)\} = F(s)G(s)

여기서 (fg)(t)=0tf(τ)g(tτ)dτ(f*g)(t) = \int_0^t f(\tau)g(t-\tau)d\tau

이 정리는 시스템의 임펄스 응답과 입력 신호의 합성곱이 출력임을 수학적으로 증명합니다.

최종값 정리: limtf(t)=lims0sF(s)\lim_{t\to\infty} f(t) = \lim_{s\to 0} sF(s)

정상 상태 값을 tt-도메인 풀이 없이 구할 수 있습니다.

초기값 정리: limt0+f(t)=limssF(s)\lim_{t\to 0^+} f(t) = \lim_{s\to\infty} sF(s)

5.4 역 라플라스 변환

부분 분수 분해(Partial Fraction Decomposition):

F(s)=P(s)/Q(s)F(s) = P(s)/Q(s)에서 분모를 인수분해하여 표 변환쌍의 합으로 분해합니다.

경우 1: 서로 다른 실수 극점

F(s)=N(s)(sp1)(sp2)(spn)=A1sp1+A2sp2+F(s) = \frac{N(s)}{(s-p_1)(s-p_2)\cdots(s-p_n)} = \frac{A_1}{s-p_1} + \frac{A_2}{s-p_2} + \cdots

Ak=limspk(spk)F(s)A_k = \lim_{s\to p_k}(s-p_k)F(s)

경우 2: 중복 극점 (s=ps = pmm중근)

F(s)=+Am(sp)m+Am1(sp)m1++A1spF(s) = \cdots + \frac{A_m}{(s-p)^m} + \frac{A_{m-1}}{(s-p)^{m-1}} + \cdots + \frac{A_1}{s-p}

Ak=1(mk)![dmkdsmk(sp)mF(s)]s=pA_k = \frac{1}{(m-k)!}\left[\frac{d^{m-k}}{ds^{m-k}}(s-p)^m F(s)\right]_{s=p}

경우 3: 켤레 복소 극점

As+Bs2+2αs+(α2+β2)eαt(C1cosβt+C2sinβt)\frac{As + B}{s^2 + 2\alpha s + (\alpha^2 + \beta^2)} \Rightarrow e^{-\alpha t}(C_1\cos\beta t + C_2\sin\beta t)

헤비사이드 전개 정리(Heaviside Expansion):

분모가 서로 다른 1차 인수의 곱일 때: F(s)=k=1nN(pk)Q(pk)1spkF(s) = \sum_{k=1}^n \frac{N(p_k)}{Q'(p_k)} \cdot \frac{1}{s - p_k}

5.5 라플라스 변환으로 ODE 풀기

예제: RLC 직렬 회로 과도 응답

Ld2idt2+Rdidt+iC=E0δ(t)L\frac{d^2i}{dt^2} + R\frac{di}{dt} + \frac{i}{C} = E_0\delta(t)

초기조건: i(0)=0i(0) = 0, i(0)=E0/Li'(0) = E_0/L

풀이:

양변에 라플라스 변환 적용:

L[s2I(s)si(0)i(0)]+R[sI(s)i(0)]+I(s)C=E0L[s^2I(s) - si(0) - i'(0)] + R[sI(s) - i(0)] + \frac{I(s)}{C} = E_0

초기조건 대입:

Ls2I(s)LE0/L+RsI(s)+I(s)C=E0Ls^2 I(s) - LE_0/L + RsI(s) + \frac{I(s)}{C} = E_0

I(s)(Ls2+Rs+1C)=2E0E0=E0I(s)\left(Ls^2 + Rs + \frac{1}{C}\right) = 2E_0 - E_0 = E_0

잠깐, 초기조건 수정: i(0)=0i(0) = 0, i(0)=0i'(0) = 0 (캐패시터에 전하 없음)이면 임펄스 입력으로 인해:

I(s)=E0Ls2+Rs+1/C=E0/Ls2+(R/L)s+1/(LC)I(s) = \frac{E_0}{Ls^2 + Rs + 1/C} = \frac{E_0/L}{s^2 + (R/L)s + 1/(LC)}

α=R/(2L)\alpha = R/(2L), ω0=1/LC\omega_0 = 1/\sqrt{LC}, ωd=ω02α2\omega_d = \sqrt{\omega_0^2 - \alpha^2} (부족감쇠 경우)로 정의하면:

I(s)=E0/L(s+α)2+ωd2I(s) = \frac{E_0/L}{(s+\alpha)^2 + \omega_d^2}

역 라플라스 변환 (표에서 L{eαtsinωdt}=ωd/[(s+α)2+ωd2]\mathcal{L}\{e^{-\alpha t}\sin\omega_d t\} = \omega_d/[(s+\alpha)^2+\omega_d^2]):

i(t)=E0Lωdeαtsinωdti(t) = \frac{E_0}{L\omega_d}e^{-\alpha t}\sin\omega_d t

이것이 RLC 회로의 임펄스 응답이며, 동시에 그린 함수이기도 합니다.


6. Python으로 ODE 수치 풀기

6.1 scipy.integrate.solve_ivp 활용

import numpy as np
from scipy.integrate import solve_ivp
import matplotlib.pyplot as plt

# RLC 회로 시뮬레이션 (2차 ODE -> 연립 1차 ODE)
# L * q'' + R * q' + q/C = Vs (계단 입력)
# 상태 변수: y[0] = q (전하), y[1] = i = dq/dt (전류)

def rlc_circuit(t, y, R, L, C, Vs):
    q, dq_dt = y
    # q'' = (Vs - R*i - q/C) / L
    d2q_dt2 = (Vs - R * dq_dt - q / C) / L
    return [dq_dt, d2q_dt2]

# 회로 파라미터
R = 100      # 저항 (Ohm)
L = 0.1      # 인덕턴스 (H)
C = 1e-6     # 캐패시턴스 (F)
Vs = 10.0    # 전원 전압 (V)

# 공진 주파수와 감쇠비 계산
omega_0 = 1.0 / np.sqrt(L * C)
alpha = R / (2 * L)
zeta = alpha / omega_0
print(f"공진 주파수: {omega_0/(2*np.pi):.1f} Hz")
print(f"감쇠비 zeta: {zeta:.3f}")
if zeta > 1:
    print("-> 과감쇠")
elif zeta == 1:
    print("-> 임계감쇠")
else:
    print("-> 부족감쇠")

# 수치 풀이
y0 = [0.0, 0.0]  # 초기조건: q(0) = 0, i(0) = 0
t_span = (0, 0.01)
t_eval = np.linspace(0, 0.01, 2000)

sol = solve_ivp(
    rlc_circuit, t_span, y0,
    t_eval=t_eval,
    args=(R, L, C, Vs),
    method='RK45',
    rtol=1e-8,
    atol=1e-10
)

# 전압 계산: v_C = q/C
v_C = sol.y[0] / C
i = sol.y[1]

# 시각화
fig, axes = plt.subplots(2, 1, figsize=(10, 8))

axes[0].plot(sol.t * 1e3, v_C, 'b-', linewidth=2, label='커패시터 전압')
axes[0].axhline(y=Vs, color='r', linestyle='--', label=f'정상 상태 {Vs}V')
axes[0].set_xlabel('시간 (ms)')
axes[0].set_ylabel('전압 (V)')
axes[0].set_title('RLC 직렬 회로 - 계단 응답')
axes[0].legend()
axes[0].grid(True, alpha=0.3)

axes[1].plot(sol.t * 1e3, i * 1e3, 'g-', linewidth=2, label='전류')
axes[1].set_xlabel('시간 (ms)')
axes[1].set_ylabel('전류 (mA)')
axes[1].set_title('RLC 회로 전류')
axes[1].legend()
axes[1].grid(True, alpha=0.3)

plt.tight_layout()
plt.savefig('rlc_response.png', dpi=150)
plt.show()

6.2 sympy로 해석해 구하기

import sympy as sp

# 기호 정의
t, s = sp.symbols('t s')
R_sym, L_sym, C_sym = sp.symbols('R L C', positive=True)
Vs_sym = sp.Symbol('Vs')

# RC 회로 해석해 (sympy로 미분방정식 풀기)
v = sp.Function('v')
tau = sp.Symbol('tau', positive=True)

# dv/dt = (Vs - v) / (R*C)
ode = sp.Eq(v(t).diff(t), (Vs_sym - v(t)) / (R_sym * C_sym))

# 초기조건 v(0) = 0
solution = sp.dsolve(ode, v(t), ics={v(0): 0})
print("RC 회로 해:")
print(solution)
sp.pprint(solution)

# 라플라스 변환 계산
f = sp.exp(-t) * sp.sin(2*t)
F = sp.laplace_transform(f, t, s, noconds=True)
print(f"\nL{{e^(-t) sin(2t)}} = {F}")

# 역 라플라스 변환
F_inv = sp.inverse_laplace_transform(
    1 / (s**2 + 2*s + 5), s, t
)
print(f"L^(-1){{1/(s^2+2s+5)}} = {F_inv}")

6.3 다양한 적분기 비교

import numpy as np
import matplotlib.pyplot as plt

# 오일러법 vs RK4 비교
# 예제: y' = -y, y(0) = 1, 정확해 y = e^(-t)

def f(t, y):
    return -y

def euler_method(f, t0, y0, h, n):
    t = np.zeros(n+1)
    y = np.zeros(n+1)
    t[0], y[0] = t0, y0
    for i in range(n):
        y[i+1] = y[i] + h * f(t[i], y[i])
        t[i+1] = t[i] + h
    return t, y

def rk4_method(f, t0, y0, h, n):
    t = np.zeros(n+1)
    y = np.zeros(n+1)
    t[0], y[0] = t0, y0
    for i in range(n):
        k1 = h * f(t[i], y[i])
        k2 = h * f(t[i] + h/2, y[i] + k1/2)
        k3 = h * f(t[i] + h/2, y[i] + k2/2)
        k4 = h * f(t[i] + h, y[i] + k3)
        y[i+1] = y[i] + (k1 + 2*k2 + 2*k3 + k4) / 6
        t[i+1] = t[i] + h
    return t, y

h = 0.5
n = 10
t0, y0 = 0.0, 1.0

t_euler, y_euler = euler_method(f, t0, y0, h, n)
t_rk4, y_rk4 = rk4_method(f, t0, y0, h, n)
t_exact = np.linspace(0, n*h, 200)
y_exact = np.exp(-t_exact)

plt.figure(figsize=(10, 5))
plt.plot(t_exact, y_exact, 'k-', linewidth=2, label='정확해')
plt.plot(t_euler, y_euler, 'r--o', label=f'오일러법 (h={h})')
plt.plot(t_rk4, y_rk4, 'b--s', label=f'RK4 (h={h})')
plt.xlabel('t')
plt.ylabel("y(t)")
plt.title("오일러법 vs RK4 비교: y' = -y")
plt.legend()
plt.grid(True, alpha=0.3)
plt.tight_layout()
plt.show()

# 오차 비교
print(f"t=5에서 오일러법 오차: {abs(y_euler[-1] - np.exp(-5)):.6f}")
print(f"t=5에서 RK4 오차: {abs(y_rk4[-1] - np.exp(-5)):.6f}")

6.4 라플라스 변환을 Python으로 자동화

import sympy as sp

s, t = sp.symbols('s t', real=True)
a, omega = sp.symbols('a omega', positive=True)

# 라플라스 변환 표 자동 생성
functions = {
    '1': sp.Integer(1),
    't': t,
    't^2': t**2,
    't^n': t**3,
    'e^(at)': sp.exp(a*t),
    'sin(wt)': sp.sin(omega*t),
    'cos(wt)': sp.cos(omega*t),
    't*e^(at)': t * sp.exp(a*t),
    'e^(at)*sin(wt)': sp.exp(a*t) * sp.sin(omega*t),
}

print("라플라스 변환표:")
print("-" * 50)
for name, func in functions.items():
    F = sp.laplace_transform(func, t, s, noconds=True)
    print(f"L{{{name}}} = {sp.simplify(F)}")

7. 공학 응용 종합 예제

7.1 전원이 있는 RLC 회로 과도 분석

문제: R=50ΩR = 50\,\Omega, L=0.2HL = 0.2\,\text{H}, C=100μFC = 100\,\mu\text{F}인 직렬 RLC 회로에 t=0t=0에서 Vs=100VV_s = 100\,\text{V} DC 전원이 연결된다. 초기조건은 vC(0)=0v_C(0) = 0, i(0)=0i(0) = 0이다.

라플라스 변환으로 풀기:

키르히호프 전압 법칙: Ldidt+Ri+1Cidt=Vsu(t)L\frac{di}{dt} + Ri + \frac{1}{C}\int i\,dt = V_s u(t)

i=CdvC/dti = C dv_C/dt로 치환하여 전하 qq로 정리: Lq¨+Rq˙+qC=VsL\ddot{q} + R\dot{q} + \frac{q}{C} = V_s

라플라스 변환: (Ls2+Rs+1C)Q(s)=Vss\left(Ls^2 + Rs + \frac{1}{C}\right)Q(s) = \frac{V_s}{s}

Q(s)=Vss(Ls2+Rs+1C)=Vs/Ls(s2+RLs+1LC)Q(s) = \frac{V_s}{s\left(Ls^2 + Rs + \frac{1}{C}\right)} = \frac{V_s/L}{s\left(s^2 + \frac{R}{L}s + \frac{1}{LC}\right)}

수치 대입: α=R/(2L)=125s1\alpha = R/(2L) = 125\,\text{s}^{-1}, ω0=1/LC223.6s1\omega_0 = 1/\sqrt{LC} \approx 223.6\,\text{s}^{-1}

ω0>α\omega_0 > \alpha이므로 부족감쇠입니다.

ωd=ω02α2185.0s1\omega_d = \sqrt{\omega_0^2 - \alpha^2} \approx 185.0\,\text{s}^{-1}

부분 분수 분해 후 역 라플라스 변환:

vC(t)=Vs[1eαt(cosωdt+αωdsinωdt)]v_C(t) = V_s\left[1 - e^{-\alpha t}\left(\cos\omega_d t + \frac{\alpha}{\omega_d}\sin\omega_d t\right)\right]

=100[1e125t(cos185t+0.676sin185t)]V= 100\left[1 - e^{-125t}\left(\cos 185t + 0.676\sin 185t\right)\right]\,\text{V}

7.2 스프링-질량-감쇠기 공진 분석

문제: m=1kgm = 1\,\text{kg}, k=100N/mk = 100\,\mathrm{N/m}, c=4Ns/mc = 4\,\mathrm{N \cdot s/m}, F(t)=10cosωtNF(t) = 10\cos\omega t\,\mathrm{N}

고유 진동수: ωn=k/m=10rad/s\omega_n = \sqrt{k/m} = 10\,\text{rad/s}

감쇠비: ζ=c/(2mk)=0.2\zeta = c/(2\sqrt{mk}) = 0.2 (부족감쇠)

정상 상태 응답 진폭: X=F0/k(1r2)2+(2ζr)2X = \frac{F_0/k}{\sqrt{(1-r^2)^2 + (2\zeta r)^2}}

r=ω/ωn=1r = \omega/\omega_n = 1 (공진)일 때: Xres=F0/k2ζ=10/1002×0.2=0.25mX_{\mathrm{res}} = \frac{F_0/k}{2\zeta} = \frac{10/100}{2 \times 0.2} = 0.25\,\text{m}

공진 없을 때 정적 처짐 F0/k=0.1mF_0/k = 0.1\,\text{m}2.5배입니다. 이것이 공진의 위험성입니다.


정리 및 다음 단계

이번 글에서 다룬 내용:

  1. 미분방정식 기초: 분류, 차수, 선형성, 해의 종류
  2. 1차 ODE 풀이법: 변수분리법, 적분인자법, 완전 ODE, 베르누이 방정식
  3. 2차 선형 ODE: 특성방정식, 세 가지 경우, RLC 회로 완전 분석
  4. 비제차 방정식: 미결정계수법, 매개변수 변환법, 강제 진동
  5. 연립 ODE: 행렬 표현, 고유값/고유벡터 풀이
  6. 라플라스 변환: 정의, 변환쌍, 성질, 역변환, ODE 풀이
  7. Python 구현: scipy, sympy로 수치/기호 풀이

다음 편에서는 **푸리에 급수/변환과 편미분방정식(PDE)**을 다룰 예정입니다. 신호처리와 전자기학의 핵심 수학 도구입니다.


참고 자료

Engineering Mathematics 1: Ordinary Differential Equations & Laplace Transform - Complete Guide

Engineering Mathematics 1: Ordinary Differential Equations (ODE)

Engineering mathematics is an unavoidable subject for any engineering student. In particular, Ordinary Differential Equations (ODEs) form the mathematical foundation of virtually every engineering discipline — from circuit analysis and control system design to mechanical vibration analysis. This article systematically explains ODEs from the basics to Laplace transforms, centered on engineering application examples.


1. Fundamentals of Differential Equations

What is a Differential Equation?

A differential equation is an equation that expresses a relationship between an unknown function and its derivatives. For example:

dydx=2x,y+3y+2y=0,ut=k2ux2\frac{dy}{dx} = 2x, \quad y'' + 3y' + 2y = 0, \quad \frac{\partial u}{\partial t} = k\frac{\partial^2 u}{\partial x^2}

Differential equations are a core tool for mathematically modeling natural phenomena and engineering systems.

Classification: ODE vs PDE

Ordinary Differential Equation (ODE): Contains derivatives with respect to only one independent variable.

d2xdt2+2dxdt+x=0\frac{d^2x}{dt^2} + 2\frac{dx}{dt} + x = 0

Partial Differential Equation (PDE): Contains partial derivatives with respect to two or more independent variables.

ut=c22ux2\frac{\partial u}{\partial t} = c^2\frac{\partial^2 u}{\partial x^2}

This article focuses on ODEs.

Order and Degree

The order is the highest derivative appearing in the equation.

  • First-order ODE: y+y=xy' + y = x (highest derivative is yy')
  • Second-order ODE: y+2y+y=0y'' + 2y' + y = 0 (highest derivative is yy'')

The degree is the exponent of the highest-order derivative. In most engineering problems, the degree is 1.

Linear vs Nonlinear

Linear ODE: The unknown function and its derivatives appear only as first-degree terms.

an(x)y(n)+an1(x)y(n1)++a1(x)y+a0(x)y=f(x)a_n(x)y^{(n)} + a_{n-1}(x)y^{(n-1)} + \cdots + a_1(x)y' + a_0(x)y = f(x)

Nonlinear ODE: Contains nonlinear terms such as y2y^2, yyy \cdot y', sin(y)\sin(y), etc.

y+sin(y)=0(pendulum equation)y'' + \sin(y) = 0 \quad \text{(pendulum equation)}

General Solution, Particular Solution, Singular Solution

  • General solution: A complete solution containing arbitrary constants
  • Particular solution: A solution obtained by applying initial conditions to determine the constants
  • Singular solution: A special solution that cannot be obtained from the general solution

ODEs in Engineering

Most engineering systems are described by ODEs.

RC charging circuit: RCdvdt+v=VsRC\frac{dv}{dt} + v = V_s

Spring-mass-damper system: mx¨+cx˙+kx=F(t)m\ddot{x} + c\dot{x} + kx = F(t)

Population growth model: dPdt=kP\frac{dP}{dt} = kP

RL circuit: Ldidt+Ri=E(t)L\frac{di}{dt} + Ri = E(t)

All of these are ODEs. Learning how to solve them allows you to fully analyze the dynamic behavior of engineering systems.


2. First-Order Ordinary Differential Equations

2.1 Separation of Variables

Form: dydx=f(x)g(y)\frac{dy}{dx} = f(x)g(y)

Solution procedure:

dyg(y)=f(x)dx\frac{dy}{g(y)} = f(x)dx

Integrate both sides:

dyg(y)=f(x)dx+C\int \frac{dy}{g(y)} = \int f(x)dx + C

Example: RC Charging Circuit

Circuit equation: dvdt=VsvRC\frac{dv}{dt} = \frac{V_s - v}{RC}

Separation of variables: dvVsv=dtRC\frac{dv}{V_s - v} = \frac{dt}{RC}

Integration: lnVsv=tRC+C1-\ln|V_s - v| = \frac{t}{RC} + C_1

Applying initial condition v(0)=0v(0) = 0:

Vsv=Vset/(RC)V_s - v = V_s e^{-t/(RC)}

v(t)=Vs(1et/(RC))\boxed{v(t) = V_s\left(1 - e^{-t/(RC)}\right)}

This result represents the transient response of an RC circuit. The voltage converges to VsV_s at a rate determined by the time constant τ=RC\tau = RC.

Physical interpretation:

  • At t=τt = \tau: v0.632Vsv \approx 0.632 V_s (63.2% charged)
  • At t=5τt = 5\tau: v0.993Vsv \approx 0.993 V_s (almost fully charged)

2.2 Integrating Factor Method

Standard form of a first-order linear ODE: dydx+P(x)y=Q(x)\frac{dy}{dx} + P(x)y = Q(x)

Integrating factor: μ(x)=eP(x)dx\mu(x) = e^{\int P(x)dx}

Derivation:

Multiply both sides by μ(x)\mu(x): μ(x)dydx+μ(x)P(x)y=μ(x)Q(x)\mu(x)\frac{dy}{dx} + \mu(x)P(x)y = \mu(x)Q(x)

The left side, by the product rule: ddx[μ(x)y]=μ(x)Q(x)\frac{d}{dx}[\mu(x)y] = \mu(x)Q(x)

Integrating: μ(x)y=μ(x)Q(x)dx+C\mu(x)y = \int \mu(x)Q(x)dx + C

y=1μ(x)[μ(x)Q(x)dx+C]\boxed{y = \frac{1}{\mu(x)}\left[\int \mu(x)Q(x)dx + C\right]}

Example: RL Circuit

Ldidt+Ri=EL\frac{di}{dt} + Ri = E

Converting to standard form: didt+RLi=EL\frac{di}{dt} + \frac{R}{L}i = \frac{E}{L}

Integrating factor: μ(t)=e(R/L)t\mu(t) = e^{(R/L)t}

ddt[e(R/L)ti]=ELe(R/L)t\frac{d}{dt}\left[e^{(R/L)t} \cdot i\right] = \frac{E}{L}e^{(R/L)t}

Integrating: e(R/L)ti=ERe(R/L)t+Ce^{(R/L)t} \cdot i = \frac{E}{R}e^{(R/L)t} + C

Applying initial condition i(0)=0i(0) = 0:

i(t)=ER(1e(R/L)t)\boxed{i(t) = \frac{E}{R}\left(1 - e^{-(R/L)t}\right)}

The current converges to steady state E/RE/R with time constant τ=L/R\tau = L/R.

2.3 Exact ODEs

Form: M(x,y)dx+N(x,y)dy=0M(x,y)dx + N(x,y)dy = 0

Exactness condition: My=Nx\frac{\partial M}{\partial y} = \frac{\partial N}{\partial x}

When this condition is satisfied, there exists a potential function FF such that F(x,y)=CF(x,y) = C.

Solution procedure:

  1. Integrate Fx=M\frac{\partial F}{\partial x} = M with respect to xx to find FF
  2. Use the condition Fy=N\frac{\partial F}{\partial y} = N to determine the integration constant
  3. General solution: F(x,y)=CF(x,y) = C

Example:

(2xy+y2)dx+(x2+2xy)dy=0(2xy + y^2)dx + (x^2 + 2xy)dy = 0

Checking exactness: My=2x+2y=Nx\frac{\partial M}{\partial y} = 2x + 2y = \frac{\partial N}{\partial x}

Since it is exact: F=Mdx=(2xy+y2)dx=x2y+xy2+g(y)F = \int M\,dx = \int (2xy + y^2)dx = x^2y + xy^2 + g(y)

Since Fy=x2+2xy+g(y)=N=x2+2xy\frac{\partial F}{\partial y} = x^2 + 2xy + g'(y) = N = x^2 + 2xy, we have g(y)=0g'(y) = 0, g(y)=Cg(y) = C

General solution: x2y+xy2=Cx^2y + xy^2 = C

2.4 Bernoulli Equation

Form: dydx+P(x)y=Q(x)yn(n0,1)\frac{dy}{dx} + P(x)y = Q(x)y^n \quad (n \neq 0, 1)

Substitution: Setting v=y1nv = y^{1-n} transforms this into a linear ODE.

Since v=(1n)ynyv' = (1-n)y^{-n}y', dividing the original equation by yny^n:

yndydx+P(x)y1n=Q(x)y^{-n}\frac{dy}{dx} + P(x)y^{1-n} = Q(x)

11ndvdx+P(x)v=Q(x)\frac{1}{1-n}\frac{dv}{dx} + P(x)v = Q(x)

dvdx+(1n)P(x)v=(1n)Q(x)\frac{dv}{dx} + (1-n)P(x)v = (1-n)Q(x)

This is a first-order linear ODE in vv, solvable by the integrating factor method.

Application: The logistic growth model dPdt=rP(1PK)\frac{dP}{dt} = rP\left(1 - \frac{P}{K}\right) is a Bernoulli equation with n=2n=2.


3. Second-Order Linear Ordinary Differential Equations

3.1 Homogeneous Equations

Standard form: ay+by+cy=0ay'' + by' + cy = 0

Characteristic equation derivation: Substitute y=erxy = e^{rx}.

ar2erx+brerx+cerx=0a r^2 e^{rx} + b r e^{rx} + c e^{rx} = 0

ar2+br+c=0\boxed{ar^2 + br + c = 0}

Three cases arise depending on the sign of the discriminant Δ=b24ac\Delta = b^2 - 4ac.

Case 1: Two distinct real roots (Δ>0\Delta > 0)

For r1r2r_1 \neq r_2: y=C1er1x+C2er2xy = C_1 e^{r_1 x} + C_2 e^{r_2 x}

Case 2: Repeated real root (Δ=0\Delta = 0)

For r1=r2=r=b/(2a)r_1 = r_2 = r = -b/(2a): y=(C1+C2x)erxy = (C_1 + C_2 x)e^{rx}

The term C2xerxC_2 x e^{rx} must be added so that the Wronskian is nonzero, constructing an independent second solution.

Case 3: Complex conjugate roots (Δ<0\Delta < 0)

For r=α±iβr = \alpha \pm i\beta (where α=b/(2a)\alpha = -b/(2a), β=4acb2/(2a)\beta = \sqrt{4ac - b^2}/(2a)): y=eαx(C1cosβx+C2sinβx)y = e^{\alpha x}(C_1\cos\beta x + C_2\sin\beta x)

This form is converted to real solutions using Euler's formula eiβx=cosβx+isinβxe^{i\beta x} = \cos\beta x + i\sin\beta x.

3.2 Complete Analysis of RLC Circuits

Circuit equation (in terms of charge q(t)q(t)): Ld2qdt2+Rdqdt+qC=0L\frac{d^2q}{dt^2} + R\frac{dq}{dt} + \frac{q}{C} = 0

In standard form: q+RLq+1LCq=0q'' + \frac{R}{L}q' + \frac{1}{LC}q = 0

Characteristic equation: r2+RLr+1LC=0r^2 + \frac{R}{L}r + \frac{1}{LC} = 0

r=R2L±(R2L)21LCr = -\frac{R}{2L} \pm \sqrt{\left(\frac{R}{2L}\right)^2 - \frac{1}{LC}}

Defining the damping coefficient α=R/(2L)\alpha = R/(2L) and resonant frequency ω0=1/LC\omega_0 = 1/\sqrt{LC}:

r=α±α2ω02r = -\alpha \pm \sqrt{\alpha^2 - \omega_0^2}

Overdamped: α>ω0\alpha > \omega_0 (R>2L/CR > 2\sqrt{L/C})

q(t)=C1er1t+C2er2t(r1,r2<0)q(t) = C_1 e^{r_1 t} + C_2 e^{r_2 t} \quad (r_1, r_2 < 0)

A sum of two exponential terms — decays monotonically without oscillation.

Critically Damped: α=ω0\alpha = \omega_0 (R=2L/CR = 2\sqrt{L/C})

q(t)=(C1+C2t)eαtq(t) = (C_1 + C_2 t)e^{-\alpha t}

Returns to equilibrium most rapidly without oscillation. Very important in control system design.

Underdamped: α<ω0\alpha < \omega_0 (R<2L/CR < 2\sqrt{L/C})

Defining the damped oscillation frequency ωd=ω02α2\omega_d = \sqrt{\omega_0^2 - \alpha^2}:

q(t)=eαt(C1cosωdt+C2sinωdt)q(t) = e^{-\alpha t}(C_1\cos\omega_d t + C_2\sin\omega_d t)

Oscillates while decaying. Commonly seen in communication circuits and vibration systems.

Summary of physical interpretation:

ConditionNameResponse Characteristics
R>2L/CR > 2\sqrt{L/C}OverdampedSlow decay without oscillation
R=2L/CR = 2\sqrt{L/C}Critically dampedFastest decay without oscillation
R<2L/CR < 2\sqrt{L/C}UnderdampedOscillates and decays
R=0R = 0UndampedContinuous oscillation

3.3 Non-homogeneous Equations

Form: ay+by+cy=f(x)ay'' + by' + cy = f(x)

Complete solution: y=yh+ypy = y_h + y_p

  • yhy_h: General solution of the homogeneous equation (complementary function)
  • ypy_p: Particular solution

Method of Undetermined Coefficients

Guess the form of ypy_p based on the form of f(x)f(x).

Form of f(x)f(x)Guessed form of ypy_p
keaxke^{ax}AeaxAe^{ax}
kxnkx^nAnxn++A1x+A0A_n x^n + \cdots + A_1 x + A_0
kcosωxk\cos\omega x or ksinωxk\sin\omega xAcosωx+BsinωxA\cos\omega x + B\sin\omega x
keaxcosωxke^{ax}\cos\omega xeax(Acosωx+Bsinωx)e^{ax}(A\cos\omega x + B\sin\omega x)

Note: If the guessed form of ypy_p overlaps with a term in yhy_h, multiply by xx.

Example: y+4y=3cos2xy'' + 4y = 3\cos 2x

Homogeneous solution: yh=C1cos2x+C2sin2xy_h = C_1\cos 2x + C_2\sin 2x

Since the guessed form of ypy_p overlaps with yhy_h, modify: yp=x(Acos2x+Bsin2x)y_p = x(A\cos 2x + B\sin 2x)

After substitution: A=0A = 0, B=3/4B = 3/4

yp=34xsin2xy_p = \frac{3}{4}x\sin 2x

This is resonance, where the amplitude increases proportionally with time.

Forced vibration response:

mx¨+cx˙+kx=F0cosωtm\ddot{x} + c\dot{x} + kx = F_0\cos\omega t

Steady-state particular solution: xp(t)=F0/k(1r2)2+(2ζr)2cos(ωtϕ)x_p(t) = \frac{F_0/k}{\sqrt{(1-r^2)^2 + (2\zeta r)^2}}\cos(\omega t - \phi)

Where frequency ratio r=ω/ωnr = \omega/\omega_n and damping ratio ζ=c/(2mk)\zeta = c/(2\sqrt{mk}).

The amplitude is maximum at r=1r = 1 (resonance condition).

Variation of Parameters

Used for general f(x)f(x) where the method of undetermined coefficients cannot be applied.

Given yh=C1y1+C2y2y_h = C_1 y_1 + C_2 y_2:

yp=y1y2fWdx+y2y1fWdxy_p = -y_1 \int \frac{y_2 f}{W}dx + y_2 \int \frac{y_1 f}{W}dx

Wronskian: W=y1y2y1y2W = y_1 y_2' - y_1' y_2

This formula applies to any continuous function f(x)f(x).


4. Systems of Differential Equations

4.1 Matrix Representation

A system of nn first-order ODEs:

dXdt=AX\frac{d\mathbf{X}}{dt} = A\mathbf{X}

Where X=[x1,x2,,xn]T\mathbf{X} = [x_1, x_2, \ldots, x_n]^T and AA is an n×nn \times n coefficient matrix.

4.2 Eigenvalue/Eigenvector Solution

Form of solution: X=veλt\mathbf{X} = \mathbf{v}e^{\lambda t}

Substituting: λv=Av\lambda \mathbf{v} = A\mathbf{v}

So λ\lambda is an eigenvalue of AA, and v\mathbf{v} is the corresponding eigenvector.

Characteristic equation: det(AλI)=0\det(A - \lambda I) = 0

Example: Two connected tanks system

ddt(x1x2)=(2112)(x1x2)\frac{d}{dt}\begin{pmatrix} x_1 \\ x_2 \end{pmatrix} = \begin{pmatrix} -2 & 1 \\ 1 & -2 \end{pmatrix}\begin{pmatrix} x_1 \\ x_2 \end{pmatrix}

Characteristic equation: (λ+2)21=0(\lambda+2)^2 - 1 = 0

λ1=1,λ2=3\lambda_1 = -1, \quad \lambda_2 = -3

Eigenvectors: v1=[1,1]T\mathbf{v}_1 = [1, 1]^T, v2=[1,1]T\mathbf{v}_2 = [1, -1]^T

General solution: X=C1(11)et+C2(11)e3t\mathbf{X} = C_1 \begin{pmatrix} 1 \\ 1 \end{pmatrix} e^{-t} + C_2 \begin{pmatrix} 1 \\ -1 \end{pmatrix} e^{-3t}

4.3 Application to Circuit Network Analysis

Circuit with two loops (Kirchhoff's voltage law):

L1di1dt+R1i1Mdi2dt=E1(t)L_1\frac{di_1}{dt} + R_1 i_1 - M\frac{di_2}{dt} = E_1(t) L2di2dt+R2i2Mdi1dt=E2(t)L_2\frac{di_2}{dt} + R_2 i_2 - M\frac{di_1}{dt} = E_2(t)

Where MM is the mutual inductance. This can be written in matrix form and solved using the eigenvalue method or Laplace transform.


5. Laplace Transform

5.1 Definition and Convergence

Definition: L{f(t)}=F(s)=0f(t)estdt\mathcal{L}\{f(t)\} = F(s) = \int_0^\infty f(t)e^{-st}dt

s=σ+jωs = \sigma + j\omega is a complex variable. For convergence, Re(s)>σc\text{Re}(s) > \sigma_c (half-plane of convergence) must be satisfied.

Why use the Laplace transform?

  • Differential operations are converted to algebraic operations
  • Initial conditions are automatically incorporated
  • Complex ODEs can be solved as simple algebraic equations
  • It forms the basis of the transfer function concept

5.2 Key Transform Pairs

f(t)f(t)F(s)=L{f(t)}F(s) = \mathcal{L}\{f(t)\}
11 (unit step)1s\dfrac{1}{s}
tt1s2\dfrac{1}{s^2}
tnt^nn!sn+1\dfrac{n!}{s^{n+1}}
eate^{at}1sa\dfrac{1}{s-a}
sinωt\sin\omega tωs2+ω2\dfrac{\omega}{s^2+\omega^2}
cosωt\cos\omega tss2+ω2\dfrac{s}{s^2+\omega^2}
eatsinωte^{at}\sin\omega tω(sa)2+ω2\dfrac{\omega}{(s-a)^2+\omega^2}
eatcosωte^{at}\cos\omega tsa(sa)2+ω2\dfrac{s-a}{(s-a)^2+\omega^2}
δ(t)\delta(t) (impulse)11
u(ta)u(t-a) (delayed step)eass\dfrac{e^{-as}}{s}

Derivation example: L{eat}\mathcal{L}\{e^{at}\}

L{eat}=0eatestdt=0e(sa)tdt=[e(sa)t(sa)]0=1sa\mathcal{L}\{e^{at}\} = \int_0^\infty e^{at} e^{-st} dt = \int_0^\infty e^{-(s-a)t} dt = \left[\frac{e^{-(s-a)t}}{-(s-a)}\right]_0^\infty = \frac{1}{s-a}

Converges when s>as > a.

5.3 Key Properties

Linearity: L{af(t)+bg(t)}=aF(s)+bG(s)\mathcal{L}\{af(t) + bg(t)\} = aF(s) + bG(s)

Time shift (First shifting theorem): L{eatf(t)}=F(sa)\mathcal{L}\{e^{at}f(t)\} = F(s-a)

Frequency shift (Second shifting theorem): L{f(ta)u(ta)}=easF(s)\mathcal{L}\{f(t-a)u(t-a)\} = e^{-as}F(s)

Differentiation transform (most important property): L{f(t)}=sF(s)f(0)\mathcal{L}\{f'(t)\} = sF(s) - f(0) L{f(t)}=s2F(s)sf(0)f(0)\mathcal{L}\{f''(t)\} = s^2F(s) - sf(0) - f'(0) L{f(n)(t)}=snF(s)sn1f(0)sn2f(0)f(n1)(0)\mathcal{L}\{f^{(n)}(t)\} = s^nF(s) - s^{n-1}f(0) - s^{n-2}f'(0) - \cdots - f^{(n-1)}(0)

Initial conditions are automatically included in the s-domain.

Integration transform: L{0tf(τ)dτ}=F(s)s\mathcal{L}\left\{\int_0^t f(\tau)d\tau\right\} = \frac{F(s)}{s}

Convolution theorem: L{(fg)(t)}=F(s)G(s)\mathcal{L}\{(f*g)(t)\} = F(s)G(s)

Where (fg)(t)=0tf(τ)g(tτ)dτ(f*g)(t) = \int_0^t f(\tau)g(t-\tau)d\tau

This theorem mathematically proves that the output of a system is the convolution of the impulse response and the input signal.

Final value theorem: limtf(t)=lims0sF(s)\lim_{t\to\infty} f(t) = \lim_{s\to 0} sF(s)

Allows determination of the steady-state value without solving in the t-domain.

Initial value theorem: limt0+f(t)=limssF(s)\lim_{t\to 0^+} f(t) = \lim_{s\to\infty} sF(s)

5.4 Inverse Laplace Transform

Partial Fraction Decomposition:

For F(s)=P(s)/Q(s)F(s) = P(s)/Q(s), factor the denominator and decompose into a sum of table transform pairs.

Case 1: Distinct real poles

F(s)=N(s)(sp1)(sp2)(spn)=A1sp1+A2sp2+F(s) = \frac{N(s)}{(s-p_1)(s-p_2)\cdots(s-p_n)} = \frac{A_1}{s-p_1} + \frac{A_2}{s-p_2} + \cdots

Ak=limspk(spk)F(s)A_k = \lim_{s\to p_k}(s-p_k)F(s)

Case 2: Repeated poles (s=ps = p is an mm-fold root)

F(s)=+Am(sp)m+Am1(sp)m1++A1spF(s) = \cdots + \frac{A_m}{(s-p)^m} + \frac{A_{m-1}}{(s-p)^{m-1}} + \cdots + \frac{A_1}{s-p}

Ak=1(mk)![dmkdsmk(sp)mF(s)]s=pA_k = \frac{1}{(m-k)!}\left[\frac{d^{m-k}}{ds^{m-k}}(s-p)^m F(s)\right]_{s=p}

Case 3: Complex conjugate poles

As+Bs2+2αs+(α2+β2)eαt(C1cosβt+C2sinβt)\frac{As + B}{s^2 + 2\alpha s + (\alpha^2 + \beta^2)} \Rightarrow e^{-\alpha t}(C_1\cos\beta t + C_2\sin\beta t)

Heaviside Expansion Theorem:

When the denominator is a product of distinct linear factors: F(s)=k=1nN(pk)Q(pk)1spkF(s) = \sum_{k=1}^n \frac{N(p_k)}{Q'(p_k)} \cdot \frac{1}{s - p_k}

5.5 Solving ODEs with the Laplace Transform

Example: RLC Series Circuit Transient Response

Ld2idt2+Rdidt+iC=E0δ(t)L\frac{d^2i}{dt^2} + R\frac{di}{dt} + \frac{i}{C} = E_0\delta(t)

Initial conditions: i(0)=0i(0) = 0, i(0)=0i'(0) = 0 (no charge on capacitor)

Solution:

Applying the Laplace transform to both sides:

I(s)=E0/Ls2+(R/L)s+1/(LC)I(s) = \frac{E_0/L}{s^2 + (R/L)s + 1/(LC)}

Defining α=R/(2L)\alpha = R/(2L), ω0=1/LC\omega_0 = 1/\sqrt{LC}, ωd=ω02α2\omega_d = \sqrt{\omega_0^2 - \alpha^2} (underdamped case):

I(s)=E0/L(s+α)2+ωd2I(s) = \frac{E_0/L}{(s+\alpha)^2 + \omega_d^2}

Inverse Laplace transform (from table: L{eαtsinωdt}=ωd/[(s+α)2+ωd2]\mathcal{L}\{e^{-\alpha t}\sin\omega_d t\} = \omega_d/[(s+\alpha)^2+\omega_d^2]):

i(t)=E0Lωdeαtsinωdti(t) = \frac{E_0}{L\omega_d}e^{-\alpha t}\sin\omega_d t

This is the impulse response of the RLC circuit, which is also its Green's function.


6. Numerical ODE Solutions with Python

6.1 Using scipy.integrate.solve_ivp

import numpy as np
from scipy.integrate import solve_ivp
import matplotlib.pyplot as plt

# RLC circuit simulation (2nd order ODE -> system of 1st order ODEs)
# L * q'' + R * q' + q/C = Vs (step input)
# State variables: y[0] = q (charge), y[1] = i = dq/dt (current)

def rlc_circuit(t, y, R, L, C, Vs):
    q, dq_dt = y
    # q'' = (Vs - R*i - q/C) / L
    d2q_dt2 = (Vs - R * dq_dt - q / C) / L
    return [dq_dt, d2q_dt2]

# Circuit parameters
R = 100      # Resistance (Ohm)
L = 0.1      # Inductance (H)
C = 1e-6     # Capacitance (F)
Vs = 10.0    # Supply voltage (V)

# Calculate resonant frequency and damping ratio
omega_0 = 1.0 / np.sqrt(L * C)
alpha = R / (2 * L)
zeta = alpha / omega_0
print(f"Resonant frequency: {omega_0/(2*np.pi):.1f} Hz")
print(f"Damping ratio zeta: {zeta:.3f}")
if zeta > 1:
    print("-> Overdamped")
elif zeta == 1:
    print("-> Critically damped")
else:
    print("-> Underdamped")

# Numerical solution
y0 = [0.0, 0.0]  # Initial conditions: q(0) = 0, i(0) = 0
t_span = (0, 0.01)
t_eval = np.linspace(0, 0.01, 2000)

sol = solve_ivp(
    rlc_circuit, t_span, y0,
    t_eval=t_eval,
    args=(R, L, C, Vs),
    method='RK45',
    rtol=1e-8,
    atol=1e-10
)

# Voltage calculation: v_C = q/C
v_C = sol.y[0] / C
i = sol.y[1]

# Visualization
fig, axes = plt.subplots(2, 1, figsize=(10, 8))

axes[0].plot(sol.t * 1e3, v_C, 'b-', linewidth=2, label='Capacitor voltage')
axes[0].axhline(y=Vs, color='r', linestyle='--', label=f'Steady state {Vs}V')
axes[0].set_xlabel('Time (ms)')
axes[0].set_ylabel('Voltage (V)')
axes[0].set_title('RLC Series Circuit - Step Response')
axes[0].legend()
axes[0].grid(True, alpha=0.3)

axes[1].plot(sol.t * 1e3, i * 1e3, 'g-', linewidth=2, label='Current')
axes[1].set_xlabel('Time (ms)')
axes[1].set_ylabel('Current (mA)')
axes[1].set_title('RLC Circuit Current')
axes[1].legend()
axes[1].grid(True, alpha=0.3)

plt.tight_layout()
plt.savefig('rlc_response.png', dpi=150)
plt.show()

6.2 Analytical Solutions with SymPy

import sympy as sp

# Symbol definitions
t, s = sp.symbols('t s')
R_sym, L_sym, C_sym = sp.symbols('R L C', positive=True)
Vs_sym = sp.Symbol('Vs')

# RC circuit analytical solution (solving ODE with sympy)
v = sp.Function('v')
tau = sp.Symbol('tau', positive=True)

# dv/dt = (Vs - v) / (R*C)
ode = sp.Eq(v(t).diff(t), (Vs_sym - v(t)) / (R_sym * C_sym))

# Initial condition v(0) = 0
solution = sp.dsolve(ode, v(t), ics={v(0): 0})
print("RC circuit solution:")
print(solution)
sp.pprint(solution)

# Laplace transform calculation
f = sp.exp(-t) * sp.sin(2*t)
F = sp.laplace_transform(f, t, s, noconds=True)
print(f"\nL{{e^(-t) sin(2t)}} = {F}")

# Inverse Laplace transform
F_inv = sp.inverse_laplace_transform(
    1 / (s**2 + 2*s + 5), s, t
)
print(f"L^(-1){{1/(s^2+2s+5)}} = {F_inv}")

6.3 Comparing Different Integrators

import numpy as np
import matplotlib.pyplot as plt

# Euler method vs RK4 comparison
# Example: y' = -y, y(0) = 1, exact solution y = e^(-t)

def f(t, y):
    return -y

def euler_method(f, t0, y0, h, n):
    t = np.zeros(n+1)
    y = np.zeros(n+1)
    t[0], y[0] = t0, y0
    for i in range(n):
        y[i+1] = y[i] + h * f(t[i], y[i])
        t[i+1] = t[i] + h
    return t, y

def rk4_method(f, t0, y0, h, n):
    t = np.zeros(n+1)
    y = np.zeros(n+1)
    t[0], y[0] = t0, y0
    for i in range(n):
        k1 = h * f(t[i], y[i])
        k2 = h * f(t[i] + h/2, y[i] + k1/2)
        k3 = h * f(t[i] + h/2, y[i] + k2/2)
        k4 = h * f(t[i] + h, y[i] + k3)
        y[i+1] = y[i] + (k1 + 2*k2 + 2*k3 + k4) / 6
        t[i+1] = t[i] + h
    return t, y

h = 0.5
n = 10
t0, y0 = 0.0, 1.0

t_euler, y_euler = euler_method(f, t0, y0, h, n)
t_rk4, y_rk4 = rk4_method(f, t0, y0, h, n)
t_exact = np.linspace(0, n*h, 200)
y_exact = np.exp(-t_exact)

plt.figure(figsize=(10, 5))
plt.plot(t_exact, y_exact, 'k-', linewidth=2, label='Exact solution')
plt.plot(t_euler, y_euler, 'r--o', label=f'Euler method (h={h})')
plt.plot(t_rk4, y_rk4, 'b--s', label=f'RK4 (h={h})')
plt.xlabel('t')
plt.ylabel("y(t)")
plt.title("Euler vs RK4 Comparison: y' = -y")
plt.legend()
plt.grid(True, alpha=0.3)
plt.tight_layout()
plt.show()

# Error comparison
print(f"Euler method error at t=5: {abs(y_euler[-1] - np.exp(-5)):.6f}")
print(f"RK4 error at t=5: {abs(y_rk4[-1] - np.exp(-5)):.6f}")

6.4 Automating Laplace Transforms with Python

import sympy as sp

s, t = sp.symbols('s t', real=True)
a, omega = sp.symbols('a omega', positive=True)

# Auto-generate Laplace transform table
functions = {
    '1': sp.Integer(1),
    't': t,
    't^2': t**2,
    't^n': t**3,
    'e^(at)': sp.exp(a*t),
    'sin(wt)': sp.sin(omega*t),
    'cos(wt)': sp.cos(omega*t),
    't*e^(at)': t * sp.exp(a*t),
    'e^(at)*sin(wt)': sp.exp(a*t) * sp.sin(omega*t),
}

print("Laplace Transform Table:")
print("-" * 50)
for name, func in functions.items():
    F = sp.laplace_transform(func, t, s, noconds=True)
    print(f"L{{{name}}} = {sp.simplify(F)}")

7. Comprehensive Engineering Application Examples

7.1 Transient Analysis of RLC Circuit with Power Source

Problem: A series RLC circuit with R=50ΩR = 50\,\Omega, L=0.2HL = 0.2\,\text{H}, C=100μFC = 100\,\mu\text{F} is connected to a Vs=100VV_s = 100\,\text{V} DC source at t=0t=0. Initial conditions are vC(0)=0v_C(0) = 0, i(0)=0i(0) = 0.

Solving with the Laplace Transform:

Kirchhoff's voltage law: Ldidt+Ri+1Cidt=Vsu(t)L\frac{di}{dt} + Ri + \frac{1}{C}\int i\,dt = V_s u(t)

Substituting i=CdvC/dti = C dv_C/dt and writing in terms of charge qq: Lq¨+Rq˙+qC=VsL\ddot{q} + R\dot{q} + \frac{q}{C} = V_s

Laplace transform: (Ls2+Rs+1C)Q(s)=Vss\left(Ls^2 + Rs + \frac{1}{C}\right)Q(s) = \frac{V_s}{s}

Q(s)=Vss(Ls2+Rs+1C)=Vs/Ls(s2+RLs+1LC)Q(s) = \frac{V_s}{s\left(Ls^2 + Rs + \frac{1}{C}\right)} = \frac{V_s/L}{s\left(s^2 + \frac{R}{L}s + \frac{1}{LC}\right)}

Substituting values: α=R/(2L)=125s1\alpha = R/(2L) = 125\,\text{s}^{-1}, ω0=1/LC223.6s1\omega_0 = 1/\sqrt{LC} \approx 223.6\,\text{s}^{-1}

Since ω0>α\omega_0 > \alpha, this is underdamped.

ωd=ω02α2185.0s1\omega_d = \sqrt{\omega_0^2 - \alpha^2} \approx 185.0\,\text{s}^{-1}

After partial fraction decomposition and inverse Laplace transform:

vC(t)=Vs[1eαt(cosωdt+αωdsinωdt)]v_C(t) = V_s\left[1 - e^{-\alpha t}\left(\cos\omega_d t + \frac{\alpha}{\omega_d}\sin\omega_d t\right)\right]

=100[1e125t(cos185t+0.676sin185t)]V= 100\left[1 - e^{-125t}\left(\cos 185t + 0.676\sin 185t\right)\right]\,\text{V}

7.2 Resonance Analysis of Spring-Mass-Damper System

Problem: m=1kgm = 1\,\text{kg}, k=100N/mk = 100\,\mathrm{N/m}, c=4Ns/mc = 4\,\mathrm{N \cdot s/m}, F(t)=10cosωtNF(t) = 10\cos\omega t\,\mathrm{N}

Natural frequency: ωn=k/m=10rad/s\omega_n = \sqrt{k/m} = 10\,\text{rad/s}

Damping ratio: ζ=c/(2mk)=0.2\zeta = c/(2\sqrt{mk}) = 0.2 (underdamped)

Steady-state response amplitude: X=F0/k(1r2)2+(2ζr)2X = \frac{F_0/k}{\sqrt{(1-r^2)^2 + (2\zeta r)^2}}

At r=ω/ωn=1r = \omega/\omega_n = 1 (resonance): Xresonance=F0/k2ζ=10/1002×0.2=0.25mX_{resonance} = \frac{F_0/k}{2\zeta} = \frac{10/100}{2 \times 0.2} = 0.25\,\text{m}

This is 2.5 times the static deflection F0/k=0.1mF_0/k = 0.1\,\text{m} without resonance. This is the danger of resonance.


Summary and Next Steps

Topics covered in this article:

  1. Differential equation basics: Classification, order, linearity, types of solutions
  2. First-order ODE methods: Separation of variables, integrating factor, exact ODE, Bernoulli equation
  3. Second-order linear ODE: Characteristic equation, three cases, complete RLC circuit analysis
  4. Non-homogeneous equations: Undetermined coefficients, variation of parameters, forced vibration
  5. Systems of ODEs: Matrix representation, eigenvalue/eigenvector solution
  6. Laplace transform: Definition, transform pairs, properties, inverse transform, ODE solving
  7. Python implementation: Numerical and symbolic solutions with scipy and sympy

The next article will cover Fourier series/transform and partial differential equations (PDEs) — the core mathematical tools for signal processing and electromagnetics.


References


Quiz

Q1. What is the integrating factor method used for, and what is the integrating factor for dy/dx + P(x)y = Q(x)?

Answer: The integrating factor method is used to solve first-order linear ODEs of the standard form dy/dx + P(x)y = Q(x). The integrating factor is mu(x) = exp(integral of P(x) dx).

Explanation: Multiplying both sides by mu(x) transforms the left side into the derivative of mu(x)*y, allowing direct integration. This is a systematic technique applicable to any first-order linear ODE.

Q2. In the RLC series circuit, what are the three damping cases and their conditions?

Answer: The three cases depend on the damping coefficient alpha = R/(2L) and resonant frequency omega_0 = 1/sqrt(LC):

  • Overdamped: alpha greater than omega_0, i.e., R greater than 2*sqrt(L/C) — slow decay without oscillation
  • Critically damped: alpha equals omega_0, i.e., R equals 2*sqrt(L/C) — fastest decay without oscillation
  • Underdamped: alpha less than omega_0, i.e., R less than 2*sqrt(L/C) — oscillates and decays

Explanation: The characteristic equation r^2 + (R/L)r + 1/(LC) = 0 has roots r = -alpha plus/minus sqrt(alpha^2 - omega_0^2). The sign of the discriminant determines whether roots are real or complex.

Q3. What is the convolution theorem in the Laplace transform and why is it important?

Answer: The convolution theorem states that the Laplace transform of the convolution of two functions equals the product of their individual Laplace transforms: L{(f*g)(t)} = F(s)*G(s).

Explanation: This theorem is fundamental to engineering because it proves that the output of a linear time-invariant system equals the convolution of the input signal with the system's impulse response. In the s-domain, this becomes simple multiplication, making system analysis much easier.

Q4. What is resonance in a forced vibration system and what conditions cause it?

Answer: Resonance occurs when the frequency ratio r = omega/omega_n equals 1, meaning the driving frequency equals the natural frequency of the system. Under resonance conditions, the steady-state amplitude is X = (F_0/k) / (2*zeta), which can be many times larger than the static deflection.

Explanation: In the method of undetermined coefficients for y'' + 4y = 3*cos(2x), the forcing frequency matches the natural frequency, causing the particular solution to include a factor of x (secular growth). In real systems with damping, amplitude does not grow to infinity but reaches a finite maximum at resonance. Avoiding resonance is critical in structural and mechanical engineering.

Q5. How are eigenvalues and eigenvectors used to solve systems of first-order ODEs?

Answer: For a system dX/dt = AX, we assume solutions of the form X = vexp(lambdat). Substituting gives lambdav = Av, so lambda are eigenvalues and v are eigenvectors of matrix A. The general solution is a linear combination of all eigenvalue-eigenvector pairs: X = sum of Ck * vk * exp(lambda_k * t).

Explanation: Eigenvalues determine the stability and time constants of each mode. If all eigenvalues have negative real parts, the system is stable. The eigenvectors define the directions of each natural mode of the system.