# Difference Equations Solution Steps

By: Engr. Rikki Q. Macolor

Homogeneous Solution:
1. Set all x(n) = 0 2. Replace all y(n) = λⁿ 3. Solve for values of λ 4. Determine case (Distinct vs. Non-Distinct)
Distinct roots: C1λ1ⁿ + C2λ2ⁿ + C3λ3ⁿ Repeated Roots: C1λⁿ + nC2λⁿ + n²C3λⁿ

5. Formulate Equation

Particular Solution:
1. Replace all y(n) = ku(n) and x(n) = u(n) (Depending on conditions) 2. Substitute lowest possible value of n to avoid u(n)=0 3. Solve for k 4. Formulate Particular solution: ku(n) 5. Add to yh(n) to get General Solution

Zero-Input Response:
1. Equate yh(n) with original equation y(n) = yh(n) 2. Set all x(n) = 0 3. Substitute values of n starting from 0. Where the number of substitutions depend on the number of unknown constants (C1, C2...) 4. Solve for the values of C 5. Formulate Equation: yzi(n) = 2Cλⁿcos(αn+β)u(n)
Where: C = constant value obtained from 4 λ = constant from yh(n) α = angle (in radians) from λ (without the sign) β = angle from C1 (with sign)

Zero-State Response:
1. Equate GS with original equation y(n) = yh(n) + yp(n) 2. Replace x(n) = u(n) (Depending on conditions) 3. Set all past values y(-1) = y(-2) = 0 4. Substitute values of n starting from 0. Where the number of substitutions depend on the number of unknown constants (C1, C2...) 5. Solve for the values of C 6. Formulate Equation: yzs(n) = 2Cλⁿcos(αn+β)u(n) + yp(n)
Where: C = constant value obtained from 5 λ = constant from yh(n) α = angle (in radians) from λ (without the sign) β = angle from C1 (with sign)

Total Response:
1. Equate GS with original equation y(n) = yh(n) + yp(n) 2. Replace x(n) = u(n) (Depending on conditions) 3. Substitute values of n starting from 0. Where the number of substitutions depend on the number of unknown constants (C1, C2...) 4. Solve for the values of C 5. Formulate Equation: y(n) = 2Cλⁿcos(αn+β)u(n) + yp(n).
Where: C = constant value obtained from 4 λ = constant from yh(n) α = angle (in radians) from λ (without the sign) β = angle from C1 (with sign)

Impulse Response:
1. Equate GS with original equation y(n) = yh(n) + yp(n) 2. Set all past values y(-1) = y(-2) = 0 3. Replace x(n) = ∂(n) 4. Set yp(n) = 0 5. Substitute values of n starting from 0. Where the number of substitutions depend on the number of unknown constants (C1, C2...) 6. Solve for the values of C 7. Formulate Equation: h(n) = 2Cλ ⁿcos(αn+β)u(n)
Where: C = constant value obtained from 6 λ = constant from yh(n) α = angle (in radians) from λ (without the sign) β = angle from C1 (with sign)