poctave results differ depending on PSD or time signal input
Show older comments
I am doing fractional octave analysis using poctave.
poctave will take either a time signal or a positive power spectrum, such as calculated by pwelch.
(My example code file is attached. It analyzes a synthesized mixed sines/noise signal and an audio sample loaded from a file.)
I am wondering why the results are different depending on whether I feed poctave a time signal or PSD. Here I created a 5-second signal consisting of several sinusoids with added gaussian noise. The noise energy spectrum is flat as expected, and the third octave spectrum rises with frequency as one would expect. The sine components are clearly visible in the log spectrum calculated from pwelch's pxx output:

However, the third octave bands are very different depending on whether poctave took a time signal or PSD as input. While they're mostly parallel-shifted, there are spectral differences.
Why is this the case?
If I use a short, real-world audio sample (background noise from a bar in this case), the bevavior is similar:

Accepted Answer
More Answers (0)
Categories
Find more on Spectral Measurements in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
