Small variation in amplitude
3 次查看(过去 30 天)
显示 更早的评论
Does anybody can tell me plz,how can I make change in the amplitude of speech signal ?I need to make small variation in the amplitude.I am working in synthesize speech ,I would like to change the amplitude of the speech signal signal.
0 个评论
采纳的回答
Wayne King
2012-7-29
编辑:Wayne King
2012-7-29
You can amplitude modulate the different sections.
For example, I'll amplitude modulate from 1 to 3 seconds in the following signal
Fs = 1000;
t = 0:1/Fs:5-(1/Fs);
x = cos(2*pi*100*t);
x(1000:3000) = x(1000:3000).*(1+0.2*cos(2*pi*10*t(1:2001)));
Vary the modulation depth (I've used 0.2 here) and the modulation frequency (here 10 Hz) to get a realistic variation in amplitude.
The modulation depth should be between 0 and 1, I'm guessing you want a small value like 0.1, 0.2.
The modulation frequency should probably be a low frequency as well maybe 5 Hz or less.
更多回答(2 个)
Wayne King
2012-7-29
编辑:Wayne King
2012-7-29
Just multiply the signal by a constant between 0 and 1
t = linspace(0,1,1000);
x = cos(2*pi*100*t)+sin(2*pi*100*(t-pi/4));
% scale the amplitude by 1/5
y = 0.2*x;
plot(t,x), hold on;
plot(t,y,'r','linewidth',2)
If you want to add just a small variation, then multiply by a factor just slightly over or under 1.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Simulation, Tuning, and Visualization 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!