Frequency Domain Analysis of Continuous Time Signals

Basic Knowledge Review

Fourier Series Expansion of Continuous Time Periodic Signal ( Period T )

Fourier complex coefficients , fundamental frequency  

Fourier transform pairs of continuous-time non-periodic signals

1. Exponential Fourier series of periodic rectangular pulse signal

% 计算并画出周期矩形脉冲信号的双边幅度谱和相位谱。
clc;clear;close all
A = 1;    % 幅度 
tau = 0.1; % 脉冲宽度
T = 0.5;  % 周期
Omega_0 = 2*pi/T;  % 基波频率 Ω0
K = 2*pi/tau/Omega_0; 
k = 0 : 2*K;
F_k = A*tau/T*sinc(k*Omega_0*tau/2/pi);  % 系数F_k
F_k_mag=abs(F_k);      % F_k的幅度
F_k_phase = angle(F_k);  % F_k的相位
k= -2*K : 2*K;
F_k_mag = [fliplr(F_k_mag(2:end)) F_k_mag]; % fliplr:左右翻转矩阵
F_k_phase = [ -fliplr(F_k_phase(2:end)) F_k_phase];
subplot(2,1,1)
stem(k*Omega_0, F_k_mag);
xlabel('k \Omega_o');
ylabel('magnitude');
grid
subplot(2,1,2)
stem(k*Omega_0, F_k_phase);
xlabel('k \Omega_o ');
ylabel('phase');
grid

Two-sided amplitude spectrum and phase spectrum of periodic rectangular pulse signal at T = 0.5

When the period parameter T increases:

Two-sided amplitude spectrum and phase spectrum of periodic rectangular pulse signal at T = 0.5

Two-sided amplitude spectrum and phase spectrum of periodic rectangular pulse signal at T = 0.5

2. The superposition of each harmonic of the periodic rectangular pulse signal

Periodic rectangular pulse signal:

Triangular Fourier series: ,  where

 The first N harmonics are superimposed to obtain .

% 来计算画出前N次谐波叠加得到的周期矩形脉冲信号近似波形。
clc;clear;close all
t = -2 : 10^(-4) : 2;
A = 1;
tau = 1; % 脉冲宽度
T = 2;  % 周期
Omega_0 = 2*pi/T;  %基波频率
c0 = A*tau/T; 
N = input('N=');
f_N = c0 * ones(1,length(t));  %f_N(t)
for k= 1 : 1 : N  
     f_N = f_N + 2*A*tau/T *sinc(k*Omega_0*tau/ 2/pi) *cos(k*Omega_0*t);
end
plot(t, f_N);
xlabel('t');
ylabel('f_N(t)');
title(['N=',num2str(N)]) 
axis([-2 2 -0.2 1.2]);

Plot for N=25

Plot for N=50

Plot for N=1000

It can be seen from the figure that with the increase of N, the synthesized waveform is getting closer to the original rectangular pulse signal.

Gibbs phenomenon:
After Fourier series expansion of the periodic function (such as rectangular pulse ) with discontinuous points , select finite items for synthesis. When more items are selected, the peak value in the synthesized waveform will be closer to the discontinuity point of the original signal. When the number of selected items is large, the peak tends to a constant, which is called the Gibbs phenomenon (also known as the Gibbs effect).

  

Guess you like

Origin blog.csdn.net/weixin_58351753/article/details/128329506