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.

FRR delivery across needle combinations

Open in vLab iLab Assistant

This example demonstrates how the frr_mip_flag can be used to avoid FRR-delivery in forbidden zones for Pelton generators. General modeling of pelton units and forbidden zones is explained in the pelton units and forbidden zones example. This example demonstrates the functionality for FRR-up reserves, but the functionality can be used for FRR-down reserves as well.

The model setup for this example is available in the following format:

Create SHOP session and import basic model

Our example model has a pelton generator with two needle_combinations. The first needle combination has a minimum production of 5 MW, and a maximum production of 20 MW. The second needle combination must produce between 25 MW and 40 MW. This means that there is a forbidden zone between 20 MW and 25 MW.

Loading...

Add FRR up requirement

We start by adding a reserve obligation for FRR up, run the model, and plot the resulting production and reserve delivery. The default behaviour is that the reserves must be delivered by the current running needle combination.

Loading...

Allow FRR delivery in forbidden zone

We now set the attribute p_frr_max to the maximum production of the second needle combination. This means that the model can deliver reserves up to this limit for both needle combinations. Consequently, the reserves can be delivered in the forbidden zone.

The history saving thread hit an unexpected error (OperationalError('database is locked')).History will not be written to the database.
Loading...

With FRR requirement across needle combinations, avoiding the forbidden zone

By setting the attribute frr_mip_flag to 1, we allow reserve delivery across needle combinations, but the model is forced to avoid the forbidden zone. Note that if the frr_mip_flag is active, the p_frr_max limit will be ignored.

Loading...

Binary variable options

The constraints for avoiding the forbidden zone can be turned on by setting the generator frr_mip_flag to 1. Alternatively, the constraints can be turned on for all generators by turning on frr_mip on the global_settings object. This setting is overruled by the individual generator frr_mip_flags.

If universal mip is turned off, frr mip will be turned off for all generators. This applies also if the generator frr_mip_flag is active.

The default setting is to use binary variables for the constraints in incremental iterations. The binary variables can be turned off for incremental iterations through the binary_reserve_limits attribute on the global_settings object. However, this is not recommended, as not using binary variables might cause unwanted behaviour.