# How can I seperate a superposition of sine and random waves?

12 次查看（过去 30 天）
Alexi B.2015-2-6

Hi, I'm into modal analysis. We want to vibrate a body using a combination of sine and random signals. Then we measure the response on a body using accelerometer. The measurement is 1 signal, the need is to separate the signal into two signals (sine and random) and see how close is the measurement to the original signals we used to vibrate the body, thus learning about the nature of interference, accuracy of accelerometers and so on. Does anyone knows how to do it? (not FFT)

### 采纳的回答

Youssef Khmou 2015-2-6
Separation of two wave forms can be accomplished using Kalman filter or wiener filter, you can find resources of these two filters, next you use root mean square error between recovered and original sine waves.
##### 4 个评论显示 3更早的评论隐藏 3更早的评论
Youssef Khmou 2015-2-8

Y1 is the recovered wave form and and y is raw vector, the basic way is :
nn=y-Y1;
Compare statistically nn and noise.

### 更多回答（1 个）

Image Analyst 2015-2-7
I guess I don't know why you need to separate anything. Why? Why not just calculate the RMS error, or PSNR, or similar things to tell how different your known input signal is from your output (measured) signal? I guess you might need to scale the amplitudes and make sure your time scales are also matched up, but that's about it I would think. If you don't want to do a spectral analysis with fft (for some unexplained reason), then you can use pwelch() (in the Signal Processing Toolbox). http://www.mathworks.com/help/signal/ref/pwelch.html
##### 2 个评论显示 1更早的评论隐藏 1更早的评论
Image Analyst 2015-2-7
If you take the fft, you get the spectrum, which is the relative strengths of all frequencies in the signal. I don't know how you played with the fft, but whatever you did, you must have told it to give you back just the one sine wave. I mean the code will do exactly what you tell it to. The fft will give you all frequencies of sine waves back, but then you must have done the extra steps of zeroing out all the ones you don't want and then inverse transforming. That's the only way you could get just one frequency out instead of all of them.
Let me try to explain it a different way. An fft is a bunch of sine waves of all frequencies that, when summed, can replicate the original signal, similar to how you can replicate any signal with polynomials in a Taylor series. You say you're just getting one frequency out...look at it like this. You know a Taylor series, and you know that if you get a Taylor series for a sine wave, you get a1*x + x3*x^3 + a5*x^5 + a7*x^7 + ... Now if I told you that I did the Taylor series and got back just a line (the a1*x term), instead of all the terms, the only way that could happen is if I manually deleted all the terms a5, a7, a9, etc.

### 类别

Find more on Digital Filter Analysis 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!

Translated by