FFT on flow field to find peaks?
I have an oscillating fluid flow field and at some distance X from the inlet, I would like to see if the imposed frequency field is still the primary forcing factor. I was thinking to do a FFT on a section downstream. But I do not know the procedure or easy way to carry out this approximation? What do I need to do the FFT?
Can someone comment? CFDtoy 
Re: FFT on flow field to find peaks?
To do the FFT you could do as I do, and use a software based spectrum analyser such as Sigview ( see www.sigview.com ) . Sigview is very low cost ( about $50 I think ) and is well worth it considering it's capabilities. FWIW if you are tempted to use Excel I wouldn't bother  I tried using Excel initially ( creaating an FFT function is very simple ) but quickly found that the restriction on the number of rows in Excel made for a very low number of samples at my frequencies and poor FFT resolution.
I have written a 2D Euler time marching code and like you need to be able to examine the frequency content of the transient flow in my domain due to a periodic forcing function. Basically I write the thermodynamic pressure from my code to file every nth timestep as a text file ( this can be at a given cell, or averaged over a line of constant J say ) to create a pressure time history text file. I can then use Sigview's "import ASCII file" function to read in the time history data and produce a graphical output of the time waveform, then use the FFT function to create a graphical visualiation of the frequency spectrum. Very simple, but useful ! You can also compare multiple waveforms, or spectra as a waterfall plot to examine the transient freqency content say, or to be more useful do a 2 channel comparison in Sigview, so if you had say the time history for your primary forcing factor, and time history for another location downstream you could compare the amplitude attenuation, frequency content, cross phase etc. I have had to do this on rectangular 2D ducts to explore the effect of grid dependency on frequency content, attenuation etc to be sure that the effects I am seeing in my domain ( a gas turbine intake silencer ) are not an artefact of a poor grid resolution  50 cells/wavelength seems about right. If you go down the Sigview route and get stuck, I'll be more than happy to help you via this board. Hope this helps, Simon. 
Re: FFT on flow field to find peaks?
Matlab has good FFT functions.

Re: FFT on flow field to find peaks?
If we take the pressuretime trace and perform an FFT on it, what are the units for the X axis and Y axis?
Thanks 
Re: FFT on flow field to find peaks?
Nobody yet has told you what you need to be measuring. A straight FFT will tell you nothing about the relationship between the input (imposed frequency field) and the output (section downstream). You need to measure the coherence between them. Simply put, this is a measure of how much of the output signal was created by the input signal.
Any DSP text will describe how to measure this. 
Re: FFT on flow field to find peaks? on a profile
Thanks for your comments. I guess I ll be little bit more specific.
Consider a downstream distance X where I have Ux, Uy, Uz components along radial direction Y. (fixed X, Z) I have this information at different time intervals t1,t2..etc..upto tN. I have imposed a frequency in the flow field and expect the Ux, Uy, Uz to fluctuate in this frequency with some noise ofcourse. Now, I am not sure If i should do an FFt in that location for each point ? or .. do some kind of FFt for the point say each Uy1, Uy2, Uy3..UyN at different time in that line segment or should I do an FFt, say ..take a time t1 and use all the information along the y direction from Uy1 to UyN and do some analysis ? Y direction is taken since it is the profile I want to see how it fluctuates to the imposed oscillation. Could give me some insight to what I should do to get the frequency hidden in the transient profile across this section ? Thanks CFDtoy 
Re: FFT on flow field to find peaks? on a profile
Google 'numerical recipies' on the Internet. They have a nice section on FT.

Re: FFT on flow field to find peaks? on a profile
Hi Jojo:
Thanks for the reply. I am looking for the procedure to perform FFT's. Like I explained, I have a fixed x,z location and I have say axial velocity component Ux varying in y direction at different time intervals. Should I do a FFT for each point along y or ..take all the points and do FFT..and what is the procedure if either of them is adopted. Thanks for your kind help. Please let me know what you think about it. CFDtoy 
Re: FFT on flow field to find peaks? on a profile
Do you want to detect harmonics with respect to time and space (in short: a frequency or a wavelength)?

Re: FFT on flow field to find peaks? on a profile
Frequency

Re: FFT on flow field to find peaks? on a profile
If you want a frequency, it means your FFT is in time. You can do an FFT by time series. For each point (x,y,z) in your domain, put your value along time in a 2D array and perfom the FFT on it.

Re: FFT on flow field to find peaks? on a profile
Hello Jojo:
I think thts what I want to knw. I put each point (x,y,z) in the domain as a function of time right? so, the file can read time f(X) f(Y) f(Z) t f1x f1y f1z t f2x f2y f2z . . . . . . . . t fnx fny fnz or t f(x1) . . . f(xn) . f(y1) . . t f(yn) . f(z1) . . t f(zn) and do an FFT of this ? is that waht you mean? CFDtoy 
Re: FFT on flow field to find peaks? on a profile
FFT is done on a function. A function is made of two series: an abscissa and an ordinate. In your case, the abscissa is time and your ordinate is the variable f evolution at the probe point you want. Your file must have the following shape:
time1 f(x,y,z,time1) time2 f(x,y,z,time2) time3 f(x,y,z,time3) ... ... 
Re: FFT on flow field to find peaks? on a profile
Having that file format can I use programs like matlab to get what i want? Could you direct me to the procedure after gettin that file format?
CFDtoy 
Re: FFT on flow field to find peaks? on a profile
I do not know Matlab. I know it has an FFT module.
This file is the only thing you need as an input to any FFT module. Choose the one you want. The user's guide should inform you about the command to read this file, run the FFT operation and graph the result. 
Quote:
how i can make this input file for fft to obtain frequency in one position versus time? thanks 
create input file in FFT
Quote:
how i can create this file? thanks CFDtoy 
problem by monitor history of flow field ?
Dear jojo and CFDtoy
I easily done this by going to solver/monitor/surface and create and select the point that i want time dependent variable(in my case is Y velocity) to minitor its history by time of flow field. the file update after each time step BUT the component of y velocity versus flow time is all zero!!!!!! how i can solve it? best regards thanks 
All times are GMT 4. The time now is 11:21. 