- #1
chipmeisterc
- 7
- 0
Hi all,
I am trying to simulate ocean waves on a 3d grid of points. I have recently discovered the Pierson Moskowitz spectrum which will give a wave spectral density (ms/hz) for a given wind condition.
I am trying to represent this by using a large number (say 64) Gerstner waves. Each wave I am assigning a unique frequency with 64 even intervals between 0.05 hz and 20hz which seems to cover most of the useful spectrum and discreetly sampling the equation:
http://oceanworld.tamu.edu/resources/ocng_textbook/chapter16/Images/eq16-30.gif
I am picking a random phase and direction.
For amplitude on my first attempt I tried to directly use the spectral density directly multiplied by a constant however this seems to give very poor results - what's more as my amplitudes are summed the amplitudes get bigger and bigger with more and more waves so my question is how do I get from wave spectral density to amplitude correctly?
From reading various papers my understanding is that spectral density represents amplitude variance? I had no idea what variance meant until about 15 minutes ago, however after watching Khan Academy I know know this is Standard deviation^2 (another new one to me! ) or the squared average of each point minus the mean. I can therefore understand variance and how it relates to a set of data but struggling to wrap my head around it in the context of a single frequency or how I use this to pick sensible amplitudes for each wave?
Any help greatly appreciated!
Edit just to add that using the above equation the values returned do not seem to have the same y-axis scaling as the following diagram, which would also suggest the output units of the above equation are slightly different?? :
Thanks
I am trying to simulate ocean waves on a 3d grid of points. I have recently discovered the Pierson Moskowitz spectrum which will give a wave spectral density (ms/hz) for a given wind condition.
I am trying to represent this by using a large number (say 64) Gerstner waves. Each wave I am assigning a unique frequency with 64 even intervals between 0.05 hz and 20hz which seems to cover most of the useful spectrum and discreetly sampling the equation:
http://oceanworld.tamu.edu/resources/ocng_textbook/chapter16/Images/eq16-30.gif
I am picking a random phase and direction.
For amplitude on my first attempt I tried to directly use the spectral density directly multiplied by a constant however this seems to give very poor results - what's more as my amplitudes are summed the amplitudes get bigger and bigger with more and more waves so my question is how do I get from wave spectral density to amplitude correctly?
From reading various papers my understanding is that spectral density represents amplitude variance? I had no idea what variance meant until about 15 minutes ago, however after watching Khan Academy I know know this is Standard deviation^2 (another new one to me! ) or the squared average of each point minus the mean. I can therefore understand variance and how it relates to a set of data but struggling to wrap my head around it in the context of a single frequency or how I use this to pick sensible amplitudes for each wave?
Any help greatly appreciated!
Edit just to add that using the above equation the values returned do not seem to have the same y-axis scaling as the following diagram, which would also suggest the output units of the above equation are slightly different?? :
Last edited: