Generating an Echo for an Audio Signal using Convolution

30 次查看(过去 30 天)
[y,Fs] = audioread('Test1.wav');
delay=0.8*Fs; %Delay
attenuation_factor=0.4;
h=zeros(1,delay);%Impulse
h(delay)=attenuation_factor; %Impulse at delay
z=conv(y,h); %Convolution
sound(z,Fs)
The produced sound doesn't include the desired echo, and not sure why so. I would apprechiate the help

采纳的回答

Prakash S R
Prakash S R 2022-5-10
编辑:Prakash S R 2022-5-10
z is simply the delayed input (echo). You forgot to add echo to the input! You are listening to the echo component only, not sound + echo

更多回答(1 个)

mariam
mariam 2023-12-5
[y,Fs] = audioread('Test1.wav');
delay=0.8*Fs; %Delay
attenuation_factor=0.4;
h=zeros(1,delay);%Impulse
h(delay)=attenuation_factor; %Impulse at delay
z=conv(y,h); %Convolution
sound(z,Fs)

类别

Help CenterFile Exchange 中查找有关 Audio I/O and Waveform Generation 的更多信息

标签

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by