Equal weight discretization. Please help!
3 views (last 30 days)
Show older comments
Hello,
I am a brand new matlab user thus facing quite some difficulties. I have a function:
S(w)=5/16*Hs^2.*w.^4.*wp^(-5).*exp(-5/4.*(w./wp).^(-4));
Some of you will recognize it as a Pierson_Moskowitz wave energy spectrum. The thing is that I want to use equal area discretization in order to generate time signal. I think that using while loop could help me out. I could loop over frequency (w) axis as long as the integral of S(w) function is less than prescribed value (certain fraction of the total area under the curve). Then the problem comes in. I do not know how to tell Matlab that in the next loop it should start using frequency value (w) from the point where in previous loop the integral of S(w) reached desired value. Also, I do not know how to get the the frequency values at which while loop was met.
Please help me out or give some hint how to solve it as I have been struggling with this for a few week already.
I appreciate any help!
2 Comments
Star Strider
on 19 Oct 2014
Would taking the inverse Fourier transform (or series) work to transform it into the time domain?
Answers (0)
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!