Matlab envelope function help

13 ビュー (過去 30 日間)
Leon Ellis
Leon Ellis 2021 年 9 月 5 日
編集済み: John D'Errico 2021 年 9 月 5 日
Good day, my goal is to use the envelope() function to take sound signals and plot it's outskurts, so only it's amplitudes. Given an array of all the amplitudes of this sound signal, i was told I could use the envelope() function to create a new array plotting the outskirts of the signal making it easier to find words spoken in the sound wave. I'm unsure how to do this and am struggling to understand how the function works. If possible could I please get examples on how the function works (explain it as if I'm a dummy, cause at this point I think I am). Thanks a lot in advance!

採用された回答

John D'Errico
John D'Errico 2021 年 9 月 5 日
編集済み: John D'Errico 2021 年 9 月 5 日
Seems pretty easy. Read the help, and look at the examples. Envelope is part of the signal processing toolbox.
t = linspace(0,5*pi,300);
sig = 2*sin(t) + sin(3*t) + randn(size(t))/50; % some noise for fun
[hi,lo] = envelope(sig);
plot(t,sig,'r-',t,hi,'g-',t,lo,'b-')
legend('Signal','upper','lower')
grid on
It can probably do better if I spend some time reading the help, but that is your job. I don't even have that toolbox.

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeLine Plots についてさらに検索

製品


リリース

R2020a

Community Treasure Hunt

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

Start Hunting!

Translated by