定义输入信号
f
(
t
)
=
u
⋅
s
i
n
(
2
π
f
t
+
ψ
)
⋯
⋯
(
1
)
f(t)=u\cdot sin(2\pi ft+\psi) \quad \cdots \cdots(1)
f(t)=u⋅sin(2πft+ψ)⋯⋯(1)
其中
u
为信号幅度,
f
为信号频率,
ψ
为信号相位
其中u为信号幅度,f为信号频率,\psi 为信号相位
其中u为信号幅度,f为信号频率,ψ为信号相位
DTFT的频谱对称
DTFT定义为:
x
(
Ω
)
=
∑
n
=
−
∞
∞
x
(
n
)
⋅
e
−
j
n
Ω
x(\Omega)=\sum_{n=-\infty}^{\infty}{x(n)}\cdot e^{-jn\Omega}
x(Ω)=n=−∞∑∞x(n)⋅e−jnΩ
=
R
e
[
x
(
Ω
)
]
+
j
I
m
[
x
(
Ω
)
]
=Re[x(\Omega)]+jIm[x(\Omega)]
=Re[x(Ω)]+jIm[x(Ω)]
=
∣
x
(
Ω
)
∣
e
j
a
r
g
[
x
(
Ω
)
]
⋯
⋯
(
2
)
=|x(\Omega)|e^{jarg[x(\Omega)]}\quad \cdots \cdots(2)
=∣x(Ω)∣ejarg[x(Ω)]⋯⋯(2)
共轭对称性证明:
x
∗
(
Ω
)
=
∑
n
=
−
∞
∞
x
∗
(
n
)
⋅
e
j
n
Ω
⋯
⋯
(
3
)
x
∗
(
−
Ω
)
=
∑
n
=
−
∞
∞
x
∗
(
n
)
⋅
e
−
j
n
Ω
⋯
⋯
(
4
)
x^*(\Omega)=\sum_{n=-\infty}^{\infty}{x^*(n)}\cdot e^{jn\Omega}\quad \cdots \cdots(3) \\ x^*(-\Omega)=\sum_{n=-\infty}^{\infty}{x^*(n)}\cdot e^{-jn\Omega}\quad \cdots \cdots(4)
x∗(Ω)=n=−∞∑∞x∗(n)⋅ejnΩ⋯⋯(3)x∗(−Ω)=n=−∞∑∞x∗(n)⋅e−jnΩ⋯⋯(4)
则当
x
(
n
)
x(n)
x(n)为实函数时,
x
(
Ω
)
=
x
∗
(
−
Ω
)
,
x
(
−
Ω
)
=
x
∗
(
Ω
)
x(\Omega)=x^*(-\Omega),x(-\Omega)=x^*(\Omega)
x(Ω)=x∗(−Ω),x(−Ω)=x∗(Ω)
故而:
∣
x
(
Ω
)
∣
=
∣
x
∗
(
−
Ω
)
∣
=
∣
x
∗
(
Ω
)
∣
=
∣
x
(
−
Ω
)
∣
⋯
⋯
(
5
)
|x(\Omega)|=|x^*(-\Omega)|=|x^*(\Omega)|=|x(-\Omega)|\quad \cdots \cdots(5)
∣x(Ω)∣=∣x∗(−Ω)∣=∣x∗(Ω)∣=∣x(−Ω)∣⋯⋯(5)
即
x
(
Ω
)
x(\Omega)
x(Ω)在模值上关于Y轴对称
信号采样
设采样率为 f s f_s fs
数字频率
数字频率定义为
Ω
=
2
π
f
f
s
⋯
⋯
(
6
)
\Omega = 2\pi \frac{f}{f_s} \quad \cdots \cdots(6)
Ω=2πfsf⋯⋯(6)
采样所得信号
则采样得到的信号为:
f
(
n
)
=
u
⋅
s
i
n
(
2
π
f
⋅
n
f
s
+
ψ
)
,
n
=
0
,
1
⋯
,
N
−
1
⋯
⋯
(
7
)
f(n)= u\cdot sin(2\pi f\cdot \frac{n}{f_s}+\psi),\quad n=0,1\cdots ,N-1 \quad \cdots \cdots(7)
f(n)=u⋅sin(2πf⋅fsn+ψ),n=0,1⋯,N−1⋯⋯(7)
分类讨论
考虑两种情况:
{
f
<
f
s
2
,
第一种情况
f
≥
f
s
2
,
第二种情况
\begin{cases} f<\frac{f_s}{2},\quad 第一种情况 \\ f\geq \frac{f_s}{2},\quad 第二种情况\end{cases}
{f<2fs,第一种情况f≥2fs,第二种情况
第一种情况
其数字频率
Ω
\Omega
Ω为:
Ω
1
=
2
π
f
f
s
ϵ
(
0
,
π
)
⋯
⋯
(
8
)
\Omega_1 = 2\pi \frac{f}{f_s}\epsilon(0,\pi) \quad \cdots \cdots(8)
Ω1=2πfsfϵ(0,π)⋯⋯(8)
即不发生频谱搬移
第二种情况
定义
f
f
f为:
f
=
k
⋅
f
s
2
+
f
′
,
f
′
ϵ
[
0
,
f
s
2
)
⋯
⋯
(
9
)
f = k\cdot \frac{f_s}{2}+f^{'},\quad f^{'}\epsilon[0,\frac{f_s}{2}) \quad \cdots \cdots(9)
f=k⋅2fs+f′,f′ϵ[0,2fs)⋯⋯(9)
将式(9)代入式(7),得到:
f
(
n
)
=
u
⋅
s
i
n
{
2
π
⋅
(
k
⋅
f
s
2
+
f
′
)
⋅
n
f
s
+
ψ
}
,
n
=
0
,
1
⋯
,
N
−
1
⋯
⋯
(
10
)
f(n)= u\cdot sin\{2\pi \cdot(k\cdot \frac{f_s}{2}+f^{'})\cdot \frac{n}{f_s}+\psi\},\quad n=0,1\cdots ,N-1 \quad \cdots \cdots(10)
f(n)=u⋅sin{2π⋅(k⋅2fs+f′)⋅fsn+ψ},n=0,1⋯,N−1⋯⋯(10)
将式(10)化简,得到:
f
(
n
)
=
u
⋅
s
i
n
(
n
k
⋅
π
+
2
π
f
′
⋅
n
f
s
+
ψ
)
,
n
=
0
,
1
⋯
,
N
−
1
⋯
⋯
(
11
)
f(n)= u\cdot sin(nk\cdot \pi+2\pi f^{'}\cdot \frac{n}{f_s}+\psi),\quad n=0,1\cdots ,N-1 \quad \cdots \cdots(11)
f(n)=u⋅sin(nk⋅π+2πf′⋅fsn+ψ),n=0,1⋯,N−1⋯⋯(11)
f
(
n
)
=
u
⋅
(
−
1
)
n
k
⋅
s
i
n
(
2
π
f
′
⋅
n
f
s
+
ψ
)
,
n
=
0
,
1
⋯
,
N
−
1
⋯
⋯
(
12
)
f(n) = u\cdot (-1)^{nk}\cdot sin(2\pi f^{'}\cdot \frac{n}{f_s}+\psi),\quad n=0,1\cdots ,N-1 \quad \cdots \cdots(12)
f(n)=u⋅(−1)nk⋅sin(2πf′⋅fsn+ψ),n=0,1⋯,N−1⋯⋯(12)
上式可写作:
f
(
n
)
=
u
⋅
c
o
s
(
n
⋅
k
π
)
⋅
s
i
n
(
2
π
f
′
⋅
n
f
s
+
ψ
)
,
n
=
0
,
1
⋯
,
N
−
1
⋯
⋯
(
13
)
f(n) = u\cdot cos(n\cdot k\pi)\cdot sin(2\pi f^{'}\cdot \frac{n}{f_s}+\psi),\quad n=0,1\cdots ,N-1 \quad \cdots \cdots(13)
f(n)=u⋅cos(n⋅kπ)⋅sin(2πf′⋅fsn+ψ),n=0,1⋯,N−1⋯⋯(13)
继续分类讨论
考虑k为偶数的情况
c
o
s
(
n
⋅
k
π
)
cos(n\cdot k\pi)
cos(n⋅kπ)始终为1,故而不影响
故而其数字频率为:
Ω
2
=
2
π
⋅
f
′
f
s
\Omega_2=2\pi \cdot \frac{f^{'}}{f_s}
Ω2=2π⋅fsf′
考虑k为奇数的情况
c
o
s
(
n
⋅
k
π
)
=
c
o
s
(
n
π
)
cos(n\cdot k\pi)=cos(n\pi)
cos(n⋅kπ)=cos(nπ),因为时域的乘积为频域的卷积,故而其数字频率为:
Ω
2
=
π
+
2
π
⋅
f
′
f
s
\Omega_2=\pi+2\pi \cdot \frac{f^{'}}{f_s}
Ω2=π+2π⋅fsf′
因为DTFT具有周期性
(
−
π
,
π
)
(-\pi,\pi)
(−π,π),故上式又可写为:
Ω
2
′
=
−
π
+
2
π
⋅
f
′
f
s
\Omega_2^{'}=-\pi + 2\pi \cdot \frac{f^{'}}{f_s}
Ω2′=−π+2π⋅fsf′
考虑DTFT的对称性,则实际的数字频率为:
Ω
2
′
′
=
π
−
2
π
⋅
f
′
f
s
\Omega_{2}^{''}=\pi-2\pi \cdot \frac{f^{'}}{f_s}
Ω2′′=π−2π⋅fsf′
Matlab仿真
第一种情况
取采样率为1000,信号频率为333,其频谱如图所示:
第二种情况
k为偶数的情况
取采样率为1000,信号频率为1100,则由上述可得:
f
=
2
∗
500
+
100
Ω
=
2
π
100
1000
f=2*500+100 \\ \Omega = 2\pi \frac{100}{1000} \\
f=2∗500+100Ω=2π1000100
则频谱对应的频率应为
f
=
f
s
⋅
Ω
2
π
=
100
f = f_s\cdot \frac{\Omega}{2\pi} = 100
f=fs⋅2πΩ=100,如图所示:
k为奇数的情况:
取采样率为1000,信号频率为600,则由上述可得:
f
=
1
∗
500
+
100
Ω
=
π
−
2
π
100
1000
f=1*500+100 \\ \Omega =\pi - 2\pi \frac{100}{1000} \\
f=1∗500+100Ω=π−2π1000100
则频谱对应的频率应为
f
=
f
s
⋅
Ω
2
π
=
400
f = f_s\cdot \frac{\Omega}{2\pi} = 400
f=fs⋅2πΩ=400,如图所示:
Matlab仿真代码
fs = 1000;%采样率
f = 600;%信号频率
N = 1000;%总点数
n = 0:N-1;
t = n / fs;
y = sin(2*pi*f*t);%输入信号
%%频谱显示
fft_y = fft(y);
abs_y = abs(fft_y);
abs_y(2:N/2-1) = 2*abs_y(2:N/2-1);
plot_y = abs_y(1:N/2) / N;
w = n(1:N/2) / N* fs;
stem(w,plot_y)
title([num2str(f),'Hz'])
以上为个人拙见,如有不当之处还请多多指教。