---
title: "DTFS of 1 + sin + 3cos + cos(4πn/N + π/2)"
subject: "Signals and Systems"
chapter: 2
key: "semester_4/signals_and_systems:dtfs-coefficients-with-phase-term"
source: https://www.bctengineer.com/q/semester_4/signals_and_systems/dtfs-coefficients-with-phase-term
site: BCT Engineering
---

# DTFS of 1 + sin + 3cos + cos(4πn/N + π/2)

Signals and Systems · Chapter 2: Fourier Series

- Asked in: 2082 Kartik, 5 marks; 2083 Bhadra (new course), 5 marks; 2083 Baisakh (new course), 4 marks (asked 3 times)
- Video: [Determine DTFS of the signal and draw the spectrum | Numerical 1 on DTFS | EnggClasses](https://www.youtube.com/watch?v=HlEse_jD3ow) — EnggClasses
- Answer checked by Claude Opus 5.5 (high effort) on 2026-10-14
- Page: https://www.bctengineer.com/q/semester_4/signals_and_systems/dtfs-coefficients-with-phase-term
- Whole chapter: https://www.bctengineer.com/md/semester_4/signals_and_systems/chapter-2

## Question

Find and plot the Fourier series coefficients (magnitude and associated phase) for the following signal with period N. x[n] = 1 + sin((2π/N)n) + 3cos((2π/N)n) + cos((4π/N)n + π/2)

## Short answer

Using Euler expansion: a0=1, a1=1.5−j0.5 (magnitude 1.581, phase −18.43°), a_{-1}=1.5+j0.5 (1.581, +18.43°), a2=j0.5 (0.5, +90°), a_{-2}=−j0.5 (0.5, −90°). Other coefficients zero within period; all repeat every N.

## Answer

Fundamental frequency $\omega_0 = 2\pi/N$. Expand each term with Euler's formula and read off the coefficients of $e^{jk\omega_0 n}$:

$$
\begin{aligned}
x[n] &= 1 + \frac{1}{2j}\left[e^{j\omega_0 n} - e^{-j\omega_0 n}\right] + \frac{3}{2}\left[e^{j\omega_0 n} + e^{-j\omega_0 n}\right] \\
&\quad + \frac{1}{2}\left[e^{j(2\omega_0 n + \pi/2)} + e^{-j(2\omega_0 n + \pi/2)}\right] \\
&= 1 + \left(\frac{3}{2} + \frac{1}{2j}\right)e^{j\omega_0 n} + \left(\frac{3}{2} - \frac{1}{2j}\right)e^{-j\omega_0 n} \\
&\quad + \frac{1}{2}e^{j\pi/2}e^{j2\omega_0 n} + \frac{1}{2}e^{-j\pi/2}e^{-j2\omega_0 n}
\end{aligned}
$$

#### Fourier series coefficients (one period, $k = -2$ to $2$)
Using $\frac{1}{2j} = -\frac{j}{2}$:

| $k$ | $a_k$ | $\lvert a_k\rvert$ | $\angle a_k$ |
|---|---|---|---|
| 0 | $1$ | 1 | $0$ |
| 1 | $\frac{3}{2} - \frac{j}{2}$ | $\frac{\sqrt{10}}{2} = 1.581$ | $-18.43^\circ$ |
| $-1$ | $\frac{3}{2} + \frac{j}{2}$ | 1.581 | $+18.43^\circ$ |
| 2 | $\frac{j}{2}$ | 0.5 | $+90^\circ$ |
| $-2$ | $-\frac{j}{2}$ | 0.5 | $-90^\circ$ |
| others in the period | 0 | 0 | - |

Working: $|a_1| = \sqrt{1.5^2 + 0.5^2} = \sqrt{2.5} = 1.581$, $\angle a_1 = -\tan^{-1}(0.5/1.5) = -18.43^\circ$ ($-0.322$ rad).

The coefficients repeat with period $N$: $a_{k+N} = a_k$ (e.g. $a_{N-1} = a_{-1}$, $a_{N-2} = a_{-2}$). Here $N \ge 5$ is assumed so that the harmonics do not overlap.

#### Plots (one period, $k = -2 \dots 2$, repeating every $N$)
```text
 |a_k|  (repeats every N)
 1.581     |     |
     1     |  |  |
   0.5  |  |  |  |  |
       -+--+--+--+--+--> k
       -2 -1  0  1  2

 angle a_k (deg)
    90              |
 18.43     |        |
       -+--+--o--+--+--> k
-18.43  |        |
   -90  |
       -2 -1  0  1  2
```

Magnitude is even in $k$ and phase is odd in $k$, as expected for a real signal ($a_{-k} = a_k^*$).

## Check yourself

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

1. How are the coefficients found for this sum of sinusoids?
   A. Evaluate the analysis sum numerically only
   B. Expand each term with Euler's formula and read off coefficients of e^(jk w0 n)
   C. Take the derivative of x[n]
   D. Use Parseval's relation
   Answer: B. Writing sinusoids as complex exponentials gives a_k directly by comparison. (Key point: Method)

2. What is a_1?
   A. 3/2 + j/2
   B. 3/2 - j/2
   C. 3 - j
   D. 1/2
   Answer: B. a_1 = 3/2 + 1/(2j) = 3/2 - j/2. (Key point: a_1 value)

3. What are |a_1| and the angle of a_1?
   A. 1.581 and -18.43 degrees
   B. 1.581 and +18.43 degrees
   C. 2.5 and -18.43 degrees
   D. 1.581 and -71.57 degrees
   Answer: A. |a_1| = sqrt(1.5^2 + 0.5^2) = 1.581; angle = -atan(0.5/1.5) = -18.43 degrees. (Key point: Magnitude and phase of a_1)

4. What is a_2 for the term cos(2 w0 n + pi/2)?
   A. 1/2
   B. j/2
   C. -j/2
   D. 0
   Answer: B. (1/2) e^(j pi/2) = j/2; a_-2 = -j/2. (Key point: Effect of pi/2 phase)

## Related in Signals and Systems

- [DTFS of 1 + sin + 3cos + cos(4πn/N)](https://www.bctengineer.com/question.md?key=semester_4%2Fsignals_and_systems%3Adtfs-coefficients-no-phase-term) — Signals and Systems, chapter 2, asked 2×
- [Fourier series coefficients and plot](https://www.bctengineer.com/question.md?key=semester_4%2Fsignals_and_systems%3Afourier-series-coefficients-plot) — Signals and Systems, chapter 2
- [DTFS of 1 + 3cos(2πn/N + π/3)](https://www.bctengineer.com/question.md?key=semester_4%2Fsignals_and_systems%3Adtfs-cosine-with-phase) — Signals and Systems, chapter 2
- [FS of 1 + sinω₀t + 2cosω₀t + cos(2ω₀t + π/4)](https://www.bctengineer.com/question.md?key=semester_4%2Fsignals_and_systems%3Actfs-coefficients-phase-mixed) — Signals and Systems, chapter 2
- [Period of cos(πn/5)·sin(πn/3)](https://www.bctengineer.com/question.md?key=semester_4%2Fsignals_and_systems%3Aenergy-power-period-cos-sin-product) — Signals and Systems, chapter 1
- [DTFS of sin(ω₀n) with N = 6](https://www.bctengineer.com/question.md?key=semester_4%2Fsignals_and_systems%3Adtfs-sine-period-six) — Signals and Systems, chapter 2, asked 2×

## Related in other subjects

- [Fourier series coefficients of a square wave](https://www.bctengineer.com/question.md?key=semester_5%2Fdata_communication%3Afs-coefficients-square-wave) — Data Communication, chapter 3
- [How Fourier series coefficients are calculated](https://www.bctengineer.com/question.md?key=semester_7%2Fdigital_signal_analysis_and_processing%3Afourier-series-coefficients) — Digital Signal Analysis and Processing, chapter 3, asked 2×
- [Fourier series of half-period ramp pulses](https://www.bctengineer.com/question.md?key=semester_3%2Felectrical_circuit_theory%3Afourier-ramp-half-period-vo) — Electrical Circuit Theory, chapter 6
- [Fourier series: x sin x](https://www.bctengineer.com/question.md?key=semester_3%2Fmathematics_iii%3Afourier-series-x-sin-x-two) — Mathematics III, chapter 4, asked 7×
