wiki:u/erica/OutflowFeedback

Version 4 (modified by Jonathan, 9 years ago) ( diff )

October 8, 2015

Learned today a bit about the way Astrobear generates a forcing function to perturb the grid in turbulence simulations. The grid is transformed into Fourier space so that each cell in Fourier space is given a wave vector. The wave vectors (with corresponding amplitude and phase information) will be summed to give a forcing function. The amplitudes are semi random in that they are weighted against the spectral index of the power spectrum one wishes to achieve (the amplitude is always orthogonal to the k vector, but how it is orthogonal is random). The phases are random. Once this spectrum is generated in Fourier space it is transformed back into physical space and saved into a variable for the forcing function. This forcing function (really an acceleration function) is then multiplied to every zone of the box for a specified fluid variable (by default the velocity). The forcing function is normalized so that it it produces purely solenoidal perturbations (i.e. the amplitude vector is perpendicular to the k vector). At each time step the velocity is shifted so that the average velocity is 0.

The forcing function goes something like:

where

is a random complex vector subject to

for

and

We also want to be real, so

However, in the code - it looks like both are chosen randomly, and then the real part of the transform is taken. I have to think about the implications of this…

where

Now when we combine the terms, we get

Attachments (6)

Note: See TracWiki for help on using the wiki.