---
title: "Backward difference equation with step input"
subject: "Digital Control System"
chapter: 2
key: "semester_6/digital_control_system:difference-equation-backward-step"
source: https://www.bctengineer.com/q/semester_6/digital_control_system/difference-equation-backward-step
site: BCT Engineering
---

# Backward difference equation with step input

Digital Control System · Chapter 2: The Z-Transform

- Asked in: 2071 Bhadra, 6 marks
- Video: [SOLUTION OF DIFFERENCE EQUATION](https://www.youtube.com/watch?v=1KuWLNN2SKw) — Department of EC SIRT Bhopal
- Answer checked by Claude Opus 5.5 (high effort) on 2026-10-14
- Page: https://www.bctengineer.com/q/semester_6/digital_control_system/difference-equation-backward-step
- Whole chapter: https://www.bctengineer.com/md/semester_6/digital_control_system/chapter-2

## Question

Solve the following difference equation: 2x(k)-2x(k-1)+x(k-2)=u(k); where x(k)=0 for k<0 and u(k) is unit step function.

## Short answer

Take z-transform, solve for X(z). Poles at z=1 and 0.5±j0.5. Solution: x(k) = 1 + (1/√2)^{k+1} sin((k−1)π/4), k ≥ 0; overshoot 1.25, settles to 1.

## Answer

Solve by z-transform with $x(k) = 0$ for $k < 0$ and $U(z) = \dfrac{1}{1-z^{-1}}$.

#### Step 1: Z-transform

Since $x(-1) = x(-2) = 0$, the delay theorem gives $\mathcal{Z}[x(k-n)] = z^{-n}X(z)$:

$$
(2 - 2z^{-1} + z^{-2})X(z) = \frac{1}{1 - z^{-1}}
$$

$$
X(z) = \frac{1}{(1-z^{-1})(2 - 2z^{-1} + z^{-2})} = \frac{z^3}{(z-1)(2z^2 - 2z + 1)}
$$

#### Step 2: Poles

$$
2z^2 - 2z + 1 = 0 \;\Rightarrow\; z = \frac{2 \pm \sqrt{4 - 8}}{4} = 0.5 \pm j0.5 = \frac{1}{\sqrt2}e^{\pm j\pi/4}
$$

So $r = \dfrac{1}{\sqrt2} = 0.7071$ and $\Omega = \dfrac{\pi}{4}$. Both complex poles are inside the unit circle.

#### Step 3: Form of the solution

The pole at $z = 1$ gives a constant, and the complex pair gives a damped sinusoid:

$$
x(k) = A_0 + r^k\left(A\cos\frac{k\pi}{4} + B\sin\frac{k\pi}{4}\right)
$$

- **Steady state:** $A_0 = \lim_{z\to1}(1-z^{-1})X(z) = \dfrac{1}{2 - 2 + 1} = 1$
- **Initial values** from the equation: $k = 0$ gives $2x(0) = 1$, so $x(0) = 0.5$. $k = 1$ gives $2x(1) - 2(0.5) = 1$, so $x(1) = 1$.

$$
\begin{aligned}
k = 0:&\quad 1 + A = 0.5 \;\Rightarrow\; A = -0.5 \\
k = 1:&\quad 1 + 0.7071\left(-0.5\times0.7071 + B\times0.7071\right) = 1 \;\Rightarrow\; B = 0.5
\end{aligned}
$$

#### Step 4: Closed-form solution

$$
x(k) = 1 + \left(\frac{1}{\sqrt2}\right)^k\left[-0.5\cos\frac{k\pi}{4} + 0.5\sin\frac{k\pi}{4}\right], \quad k \ge 0
$$

Since $-0.5\cos\theta + 0.5\sin\theta = \frac{1}{\sqrt2}\sin\left(\theta - \frac{\pi}{4}\right)$, this simplifies to

$$
x(k) = 1 + \left(\frac{1}{\sqrt2}\right)^{k+1}\sin\frac{(k-1)\pi}{4}
$$

#### Step 5: Check with the recursion $x(k) = \frac12\left[1 + 2x(k-1) - x(k-2)\right]$

| $k$ | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 |
|---|---|---|---|---|---|---|---|---|---|---|
| $x(k)$ | 0.5 | 1 | 1.25 | 1.25 | 1.125 | 1 | 0.9375 | 0.9375 | 0.9688 | 1 |

The formula gives the same values. For example, $k = 2$: $1 + (0.7071)^3\sin(\pi/4) = 1 + 0.3536\times0.7071 = 1.25$.

The output overshoots to 1.25 and settles at 1 with a decaying oscillation.

**Answer:** $x(k) = 1 + \left(\dfrac{1}{\sqrt2}\right)^{k+1}\sin\dfrac{(k-1)\pi}{4}$, with $x(\infty) = 1$.

## Check yourself

The answer's key points as multiple-choice questions, with the correct option and why.

1. With x(k)=0 for k<0, Z[x(k-n)] equals:
   A. z^{-n}X(z)
   B. z^{n}X(z)
   C. z^{-n}X(z) - x(0)
   D. X(z)/n
   Answer: A. No initial terms remain, so a delay is simply multiplication by z^{-n}. (Key point: Delay theorem)

2. The roots of 2z^2 - 2z + 1 = 0 are:
   A. 0.5 ± j0.5
   B. 1 ± j1
   C. 0.5 and 1
   D. ±j0.5
   Answer: A. z = (2 ± sqrt(-4))/4 = 0.5 ± j0.5, magnitude 0.7071 and angle pi/4. (Key point: Poles)

3. The final value of x(k) is:
   A. 1
   B. 0.5
   C. 2
   D. 0
   Answer: A. At z=1, 2 - 2 + 1 = 1, so (1-z^{-1})X(z) tends to 1. (Key point: Steady-state value)

4. From 2x(k) - 2x(k-1) + x(k-2) = 1, what are x(0) and x(1)?
   A. 0.5 and 1
   B. 1 and 1
   C. 0.5 and 0.5
   D. 0 and 1
   Answer: A. k=0: 2x(0)=1; k=1: 2x(1) - 2(0.5) = 1, so x(1) = 1. (Key point: Initial values from the recursion)

## Related in Digital Control System

- [Difference equation with step input](https://www.bctengineer.com/question.md?key=semester_6%2Fdigital_control_system%3Adifference-equation-step-0-25) — Digital Control System, chapter 2, asked 2×
- [Difference equation with step input, x(1)=0.3679](https://www.bctengineer.com/question.md?key=semester_6%2Fdigital_control_system%3Adifference-equation-step-0-3679) — Digital Control System, chapter 2, asked 2×
- [Difference equation x(k+2)+3x(k+1)+2x(k)=0](https://www.bctengineer.com/question.md?key=semester_6%2Fdigital_control_system%3Adifference-equation-x0-0-x1-1) — Digital Control System, chapter 2, asked 5×
- [Difference equation with u(K+1) and u(K) step inputs](https://www.bctengineer.com/question.md?key=semester_6%2Fdigital_control_system%3Adifference-equation-two-inputs-step) — Digital Control System, chapter 2
- [Difference equation with given input sequence](https://www.bctengineer.com/question.md?key=semester_6%2Fdigital_control_system%3Adifference-equation-given-inputs) — Digital Control System, chapter 2, asked 2×
- [Difference equation with input u(2) = −0.2142](https://www.bctengineer.com/question.md?key=semester_6%2Fdigital_control_system%3Adifference-equation-given-inputs-neg) — Digital Control System, chapter 2, asked 2×

## Related in other subjects

- [Difference eq with unit step input](https://www.bctengineer.com/question.md?key=semester_4%2Fapplied_mathematics%3Adifference-eq-unit-step) — Applied Mathematics, chapter 2
- [Need for difference equation; LCCDE and system function](https://www.bctengineer.com/question.md?key=semester_7%2Fdigital_signal_analysis_and_processing%3Awhy-difference-equation-lccde) — Digital Signal Analysis and Processing, chapter 1, asked 2×
- [Difference eq x(k+2)+2x(k+1)+3x(k)=0](https://www.bctengineer.com/question.md?key=semester_4%2Fapplied_mathematics%3Adifference-eq-2x1-3x-x0-0-x1-2) — Applied Mathematics, chapter 2, asked 5×
- [Difference eq x(k+2)+3x(k+1)+2x(k)=0](https://www.bctengineer.com/question.md?key=semester_4%2Fapplied_mathematics%3Adifference-eq-3x1-2x-x0-0-x1-1) — Applied Mathematics, chapter 2, asked 3×
