Mann turbulence wind field generation

Hi everybody,

I am student and currently working on my master thesis. I try to generate wind fields to simulate LIDAR measurement behaviour. To achieve this I searched the internet for example codes and tried to get an overview of the common wind models. I found that only Francesco Perrone, who was also active on this forum, tried to generate wind fields in Matlab, too. I used his submissions on MATLAB Central as template and tried to program my own scripts. Now I am able to generate wind fields that match very well the theoretical spectra, at least in case of Kaimal and the improved von Karman model.

I have great trouble with the Mann model and hope to find some help here. As written before I used the work of F. Perrone as a starting point, I read the Mann Paper “Wind Field Generation”, used the IEC 61400-1 Ed. 3 and read many other papers. The following MATLAB function shows my current progress:

.m file

And here is the power spectral density of the resulting dimensionless wind field (as it should be according to the Bladed Theory Manual) in blue and the theoretical Kaimal spectrum in red. When using Gamma = 3.9, the Kaimal spectrum should be a good approximation to the generated wind field. But as you can see, especially the u-component / longitudinal-component of the wind shows great deviations for low frequencies:

Matlab Spectrum

Here is a spectrum of a file produced with Bladed:

Bladed Spectrum

For the Matlab spectra, I used the following parameters:

MeanWindSpeed = 15;
Seed = 1;
HubHeight = 130;
Duration = 600;
Nx = 1024;
GridWidth = 270;
Ny = 32;
GridHeight = 270;
Nz = 32;

I would be glad if somebody could review the MATLAB function and give me some feedback if there are serious mistakes. I know that Mann provides multiple equations to calculate the wind field, but I think that my approach is not complete wrong (at least because the spectrum does nearly fit to the Kaimal spectrum).
If further information are required (for example if an independently working script is needed or if you want to know how I calculated the spectrum), please ask.

Kind regards,

Vincent Wilms