-1
$\begingroup$

let us consider following code

>> fs=100;
>> t=0:1/fs:2.93;
>> x=25*sin(2*pi*30*t)+20*cos(2*pi*25*t)+10*rand(size(t));
>> y=23*sin(2*pi*30*t)+21*cos(2*pi*25*t)+11*rand(size(t));

i would like to ask question related to Cross Power Spectral Density function , which in matlab can be easily estimated using function

>> cpsd(x,y,[],[],1024,fs)

enter image description here can this method used tool for identify if two time series have identical spectral structure? i mean suppose we have two time series which is supposed to have same spectral structure(periodic components with same frequencies as it is given in our case) can this function help us to proof that give two series have same structure? thanks in advance

$\endgroup$
  • $\begingroup$ downvoting without explaining reason cool $\endgroup$ – dato datuashvili Oct 1 '14 at 13:15
1
$\begingroup$

I think that the picture is more or less what should be expected. There are strong components at 25 Hz and 30 Hz, which are the frequencies of the tones in $x$ and $y$. There is also a strong DC (0 Hz) component because the noise has a strong mean, because it ranges from 0 to 1, not -1 to 1. Without the noise the cpsd looks like this-

CPSD

$\endgroup$
  • $\begingroup$ i have updated my picture $\endgroup$ – dato datuashvili Oct 1 '14 at 16:12
  • $\begingroup$ anyway i can say that this function can help me to identify if two time series have same structure? $\endgroup$ – dato datuashvili Oct 1 '14 at 16:13
  • $\begingroup$ What do you mean by "structure"? But even without knowing that my answer will probably be "no". It tells you how similarly their power is distributed in the frequency domain. $\endgroup$ – Jim Clay Oct 1 '14 at 16:57
  • $\begingroup$ by structure i mean spectral picture for instance let us suppose that two time series have same frequencies, then we should get peaks only at those frequencies that are containing in both signal right $\endgroup$ – dato datuashvili Oct 1 '14 at 17:19
  • $\begingroup$ it is logical if in one time series there will be two difference frequencies then we will get 4 such peaks like we have in our case $\endgroup$ – dato datuashvili Oct 1 '14 at 17:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.