Statistics code

Description

This code is dedicated to diagnose turbulence inside interstellar medium. First, the program creates a fractalcube with a turbulent spectrum index &beta from theoretical models. The grid point number can be adjusted to a higher value so that the spatial resolution of calculation is fine enough. Structure and correlation functions for two points are computed using fast Fourier transform (FFT) and inverse FFT.


This program consists of the following functions and procedures.

[Simulation of turbulence cloud]



The fractal.pro procedure creates a fractal cube of 3 dimensions. The spectrum index is denoted by &beta. Fluctuation density inside this fractal cube is the output and stored to calculate correlation and fluctuation functions.
The slicing.pro procedure allows you to handle with the data cube in order to investigate the turtubulence in 3D.
The spektrt.pro returns a power spectrum as a function of wave number.
Procedures cf_fft.pro and sf_fft.pro are used to compute the correlation and structure function, respectively. Finally, plots of the structure function and correlation function are set up.


Back to Homepage