[yt-dev] power spectra in yt

John ZuHone jzuhone at gmail.com
Wed Apr 16 18:58:48 PDT 2014


Hi Mike,

> I am interested in using yt to do power spectra for analyzing turbulence in our simulations.  I quickly coded up a script to do this (warning: I haven't verified this, so some of the normalization may be wrong, but it doesn't assume a cubic domain, and it looked ok by eye):

I think this is a very good idea. I have coded up something similar myself recently:

http://paste.yt-project.org/show/4529/

It creates a "FourierSpace" class that can be used to create power spectra and potentially other useful things from FFTs. It needs some work. 

> The caveat is that we need to put this onto a uniform grid to do the FFT, but then we can use the numpy FFT routines.

Or you could use pyFFTW, which is probably faster: 

http://hgomersall.github.io/pyFFTW/

> The other thing is what sort of interface and where should this live in yt?  Ideally we'd compute some other properties (integral scales, etc.), but it would be nice to have some discussion about what people use and then we can start woth some basic functionality.

I think something like this should live in yt/analysis_modules. 

Best,

John
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.spacepope.org/pipermail/yt-dev-spacepope.org/attachments/20140416/94430049/attachment.html>


More information about the yt-dev mailing list