Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

Reversible turbines

Open in vLab iLab Assistant

This example is available in the following formats:

Introduction

This example imports a basic model and adds a reversible turbine modelled as two separate generator and pump objects. To ensure that the pump and generator does not operate at the same time, two commit_groups are created to force the optimization to choose between production and pumping. This assumes that the reversible turbine is a single turbine-generator machine, and not a ternary set of one pump and one turbine that can run in hydraulic short circuit.

Imports

Create a SHOP session and import basic model from file function

Loading...

Add a variable speed pump

Pumps can be added as pump objects, and need to be connected to a plant. We then apply attributes to the pump object. The pump added to model “half” of the reversible turbine is a variable speed pump, see the binary pump example for modelling of binary pumps. The difference between a binary and variable speed pump in SHOP is that multiple points are added in the turbine efficiency curves for variable speed pumps. The p_min and p_max attributes of the pump are set to limit the consumption to be between 30 and 50 MW.

The upper reservoir is also set to be full at the start of the optimization, and the generator is committed to be on in all hours.

When we plot the market price, we see that the first hours have a low price compared to the water value in the upper reservoir. This makes it economical to pump for the first hours, but this is not possible since the generator is committed to be on for the whole period.

Loading...

Run SHOP

We first run a naive optimization where the pump and generator are unaware that they are coupled and unable to operate at the same time.

We observe that the pump is used in the first six hours of the period, even though the generator is also producing power. This is not possible when dealing with a reversible turbine, but additional input is required for SHOP to recognize this.

Loading...

Using commit_group to stop simultaneous pumping and production

To stop the pump and generator running at the same time, we can use the commit_group object. A commit_group is simply a collection of generators and pumps. When two commit_groups are connected, the units connected to the first group can not run when any of the units in the other group is running, and vice versa. No other input is required for the commit_groups, only the connections.

First we recreate the previous model:

Now we add two commit_groups and connect the pump to one group and the generator to the other group. The the two commit_groups are then connected, which means that the pump and generator cannot operate at the same time.

Since the commit_group constraints are applied directly to the binary variables that decide whether a unit is on or off, it is important to use MIP to ensure the constraints are enforced.

The results below show that the pump no longer operates in the beginning of the optimization since the generator is forced to run.

Loading...