Turbine output control

2 posts / 0 new
Last post
Turbine output control

Hi SAM team,

I'm working on a LK script to change some simulation inputs and I'm wondering if it's possible to change the turbine output fraction to an array. In my script, it sets the 'ui_disp_1_turbout' to hourly values over a year with no error, but after simulating, it shows that the turbine output fraction does not follow the assigned array, and just stays as a single value. Attached is an image of part of the code.

If this is not possible, is there a way to best mimic an off grid CSP system to follow the demand profile?

Lastly, is there a quicker way to do element-wise multiplication/ division between arrays or with a single value in LK other than using a loop?


Paul Gilman

Dear Holly,

The ui_disp_1_turbout input variable is a number with a single value, and is the turbine output fraction for Period 1. It is not possible to change the turbine output fraction on an hour by hour basis from LK. I'm not sure what happens when you set its value to an array -- it seems like you should get an error trying to set a number to an array.

A tedious way to do this might be to set the value of the turbine output fraction, run an entire simulation, extract the output data you need for the time step in question, then change the value of the turbine output fraction, run another simulation, etc.

LK does not have functions for array operations. If you plan to do that often in your script, you can write a functions for array multiplication/division.

Best regards,

Theme by Danetsoft and Danang Probo Sayekti inspired by Maksimer