10-27-2008 11:22 AM
hello, i'm working in the simulation of a wind turbine model, and the problem is that the generated power by the turbine depends on the power coefficient, which depends on the speed of the turbine, which I calculate from the integral of power generated. then generates a complicated cycle.
Here I leave my VI and wind data with which it works.
Solved! Go to Solution.
10-27-2008 12:26 PM
It is not clear what does not work.
One thing I noticed: The first iteration of the loop produces a zero length array which results in NaN values appearing on many of the wires. This persists through the later iterations.
Why are you creating increasingly longer arrays at each iteration? This requires reallocation of memory on each iteration and may lead to problems when your datasets get large.
Lynn
10-27-2008 03:09 PM
Thank you,
Well, I have seen the same thing, but i don't know what happens, may be the initializing, or the loop, i don't know.
The aim of my project is to create a electromechanical wind turbine simulator. The torque generated by the turbine will be send to a frecuency inverter which controls a induction machine. I have the same simulation in Matlab and it works, equally produces NaN values at the start, but then stabilize.
I attached below another VI with another idea for programming, but neither works.
(the wind speed file must be entered when you run the VI and the program ask you for it).
10-27-2008 04:25 PM
Look at the modification of your VI which I have attached.
I cleaned up the diagram to make it smaller and more readable. Diagrams should generally be no larger than one screen and wiring should go left to right.
I made the Gr.fico de Viento a control with the values saved as default so I did not need to read the file each time.
I pass one point form the array to the loop (autoindexing) to simulate getting one point at a time from the turbine. I initialized an array to be the same size as the dataset and replace the initial values when each is received in the loop. I initialized the array with 0.001 because zero seemed to cause the NaN which does not go way. The Wait time was reduced to expedite troubleshooting.
A limiter (In Range and Coerce) keeps the values on the feedback signal from becoming infinite. This may be wrong for your model but it lets you see what is happening. The limiting only seems to apply near the beginning. Is there a minimum amount of data the integrator needs to produce meaningful results?
Lynn
10-27-2008 05:19 PM
thank you very much.
I would like very much to see your corrections, but i can´t open the file that you attached because my Labview version is 8.
10-28-2008 07:38 AM
Here it is saved for 8.0.
Lynn
10-28-2008 03:58 PM
thank you,
your correction are very useful, but still the simulation don't works how as it should. The generated power must be positive and relatively constant, angular speed must be increasing, CP can't be greater than 1 and lambda must be between 0 and 25. I have inserted some limiters and the behavior aproximates to the required, but now there is an oscillation in the parameters.
10-28-2008 08:48 PM
sorry, the previous attached file is wrong, it lacks a cycle more inside the programming. please consider the attachment of this message.
thank you.
Here is my simulation in Matlab Simulink and its results:
10-29-2008 10:05 AM
Can you post the formula you use to calculate the generated power and the angular speed?
The implementation in your turbina2.vi seems unrealistic. The angular velocity is the integral of the angular velocity from two iterations previously divided by the wind speed array cubed and other terms. This would make the angular velocity infinite for zero wind speed. The generated power term is dependent on the angular velocity divided by the wind speed. Infinite power at zero speed!! Can I buy stock in your company?
Lynn
10-29-2008 02:12 PM - edited 10-29-2008 02:18 PM
Hello, here are the formulas:
This can be the problem, The angular speed (Wm) depends on the Torque par (Tm) and the torque par depends on the angular speed. But if you see the Matlab simulation, it works perfectly in despite of this strange cycle.
here is a diagram of the equations:
And at zero wind speed, the Power Coefficient is zero too.
i hope you canhelp me.
Reggards.