Combination of two signals with different sample rates

77 ビュー (過去 30 日間)
Sotiris Katsimentes
Sotiris Katsimentes 2022 年 6 月 10 日
回答済み: Peter Perkins 2022 年 6 月 13 日
Hello,
I want to combine two signals with different sampling rate. I have have 2 sound signals, one (A) has telephone quality (Fs = 8Kz) and the other (B) music CD quality(Fs = 44.1 KHz). I want to add the music from file B to file A as a music investment (need someweakening). The duration of the result is equal to the longer of A and B.
How i can manage it??
  5 件のコメント
Star Strider
Star Strider 2022 年 6 月 11 日
Do not resample the signal with the lower sampling frequency to the higher sampling frequency, because that creates data where none previously existed. Instead, resample the signal with the higher sampling frequency to the lower sampling frequency.
Mathieu NOE
Mathieu NOE 2022 年 6 月 13 日
編集済み: Mathieu NOE 2022 年 6 月 13 日
hmmm
that depends if the signal sampled at 44.1 kHz should not be downsampled because it contains valuable info in the high frequency range ( 4 to 22 kHz)
beside that , upsampling does not create "noticable" / bad info's if it's done correctly :
  • for real time upsampling : insert zero elements AND then low pass filter (see for example : slidesSampling.dvi (toronto.edu)
  • for non real time upsampling : you can do the same , or simply interpolation. A higher order interpolation will almost create zero artifacts / info in the "new" frequency range. You can try it , do the upsampling and make the fft of the upsampled signal vs the original signal. You will end up will a almost zero fft amplitude in the extended frequency range. BTW, interp1 does not require any toolbox.

サインインしてコメントする。

回答 (1 件)

Peter Perkins
Peter Perkins 2022 年 6 月 13 日
Use a timetable, and call synchronize. synchronize uses interp1, but it may be that you particularly want to use the SP-oriented resample function instead:
ttHighFreq.yUpsampled = resample(ttLowFreq.y,...)

カテゴリ

Help Center および File ExchangeMultirate Signal Processing についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by