|
[Sponsors] |
[waves2Foam] Trying to produce a frequency spectrum of a surface elevation time series |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
January 16, 2016, 05:47 |
Trying to produce a frequency spectrum of a surface elevation time series
|
#1 |
New Member
Maxim Van Zonhoven
Join Date: Nov 2015
Posts: 4
Rep Power: 11 |
Hi Niels and others,
First of all thank you for providing us with this wonderful toolbox. I am trying to produce a frequency spectrum of a surface elevation time series (first attach.: SE.jpg). My FFT knowledge is a little rusty so I would like some help. The code I use in postProcessingProperties: deleteParentOutputDirectory false; regularSpectrum { callName surfaceElevation; removeDuplicate true; inputDir surfaceElevationAnyName; deltaT 0.01; tMin 11; // Default: minimum time tMax 25; // Default: maximum time // The action list is a set of processes on the data actionList (removeSubDirs interpolateSurfaceElevation powerSpectraFFT write2Ascii); allDataSets yes; freqBins 1024; windowShiftFraction 0.5; } The result is shown in the second attachment (Spectrum.jpg). For the most part this seems straightforward, I also checked my interpolated values to make sure they are correct. I assume a power spectrum instead of an amplitude spectrum is produced? Also, why do you need to specify freqBins? Isn't this related to the interpolated time step? However, my experiment is based on: Chen, L. F., Zang, J., Hillis, A. J., Morgan, G. J., & Plummer, A. R. (2014). Numerical investigation of wave-structure interaction using OpenFOAM. Ocean Engineering , 91-109. They approx. obtain something in the order of magnitude of attachment 3: Spectrum_Chen. My questions are: 1) Is my spectrum computation correct? 2) How do I transform this to an amplitude spectrum? (for some reason, I achieve somewhat satisfying results by taking the sqrt and dividing this by 2: attach. 3) 3) How do I include zero in my frequency range (there should be some important frequency content around 0 Hz that is now neglected) Thanks in advance. Kind regards, Maxim |
|
January 19, 2016, 13:16 |
|
#2 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,902
Rep Power: 37 |
Good afternoon all,
I will try to answer some of the questions: @Maxim: Unless you are using regular waves, I would say that the time series is too short for a evaluation of the power spectrum. If you are using regular wave, please note that there is a method specific for regular waves and based on a least-squares fitting. Please consult the source code (src/waves2FoamProcessing) for more information. Kind regards, Niels
__________________
Please note that I do not use the Friend-feature, so do not be offended, if I do not accept a request. Last edited by wyldckat; August 25, 2018 at 12:53. Reason: removed answers to other posts that were on the main thread |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[Other] Contribution a new utility: refine wall layer mesh based on yPlus field | lakeat | OpenFOAM Community Contributions | 58 | December 23, 2021 03:36 |
How to export time series of variables for one point? | mary mor | OpenFOAM Post-Processing | 8 | July 19, 2017 11:54 |
High Courant Number @ icoFoam | Artex85 | OpenFOAM Running, Solving & CFD | 11 | February 16, 2017 14:40 |
Extrusion with OpenFoam problem No. Iterations 0 | Lord Kelvin | OpenFOAM Running, Solving & CFD | 8 | March 28, 2016 12:08 |
Stuck in a Rut- interDyMFoam! | xoitx | OpenFOAM Running, Solving & CFD | 14 | March 25, 2016 08:09 |