-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Restructuring of the documentation (#22)
* Reworked the documentation structure * Added consistent labels to all headings * Added pages for the individual nodes * Updated the tests based on recent approaches * Reworking on field functions --------- Co-authored-by: hellemo <[email protected]>
- Loading branch information
Showing
27 changed files
with
781 additions
and
289 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,15 @@ | ||
name = "EnergyModelsRenewableProducers" | ||
uuid = "b007c34f-ba52-4995-ba37-fffe79fbde35" | ||
authors = ["Sigmund Eggen Holm <[email protected]>, Julian Straus <[email protected]>"] | ||
version = "0.6.0" | ||
version = "0.6.1" | ||
|
||
[deps] | ||
EnergyModelsBase = "5d7e687e-f956-46f3-9045-6f5a5fd49f50" | ||
JuMP = "4076af6c-e467-56ae-b986-b466b2749572" | ||
Pkg = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f" | ||
TimeStruct = "f9ed5ce0-9f41-4eaa-96da-f38ab8df101c" | ||
|
||
[compat] | ||
EnergyModelsBase = "^0.7.0" | ||
EnergyModelsBase = "0.8" | ||
JuMP = "1.5" | ||
TimeStruct = "^0.8.0" | ||
julia = "^1.6" | ||
TimeStruct = "0.8" | ||
julia = "1.9" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# Methods - `EnergyModelsBase` | ||
|
||
## Index | ||
|
||
```@index | ||
Pages = ["methods-EMB.md"] | ||
``` | ||
|
||
## Extension methods | ||
|
||
```@docs | ||
EnergyModelsBase.variables_node | ||
EnergyModelsBase.create_node | ||
``` | ||
|
||
## Constraint methods | ||
|
||
```@docs | ||
EnergyModelsBase.constraints_capacity | ||
EnergyModelsBase.constraints_flow_in | ||
EnergyModelsBase.constraints_level_aux | ||
``` | ||
|
||
## Check methods | ||
|
||
```@docs | ||
EnergyModelsBase.check_node | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
|
||
# Methods - Accessing fields | ||
|
||
## Index | ||
|
||
```@index | ||
Pages = ["methods-fields.md"] | ||
``` | ||
|
||
## `NonDisRES` | ||
|
||
```@docs | ||
EnergyModelsRenewableProducers.profile | ||
``` | ||
|
||
## `HydroStorage` | ||
|
||
```@docs | ||
EnergyModelsRenewableProducers.level_init | ||
EnergyModelsRenewableProducers.level_inflow | ||
EnergyModelsRenewableProducers.level_min | ||
``` | ||
|
||
## `PumpedHydroStor` | ||
|
||
```@docs | ||
EnergyModelsRenewableProducers.opex_var_pump | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,62 +1,29 @@ | ||
# [Public interface](@id sec_lib_public) | ||
# [Public interface](@id lib-pub) | ||
|
||
## [`NonDisRES` (non-dispatchable renewable energy source)](@id NonDisRES_public) | ||
|
||
This type models both wind power, solar power, and run of river hydropower. | ||
These have in common that they generate power from an intermittent energy source, so they can have large variations in power output, based on the availability of the renewable source at the time. | ||
These power sources can be modelled using the same type [`NonDisRES`](@ref). | ||
The new type is a subtype of `EMB.Source`. The new type only differs from its supertype through the field `profile`. | ||
|
||
The field `profile::TimeProfile` is a dimensionless ratio (between 0 and 1) describing how much of the installed capacity is utilized at the current operational period. | ||
Therefore, when using [`NonDisRES`](@ref) to model some renewable source, the data provided to this field is what defines the intermittent characteristics of the source. | ||
|
||
The [`NonDisRES`](@ref) node is modelled very similar to a regular `EMB.Source}` node. The only difference is how the intermittent nature of the non-dispatchable source is handled. The maximum power generation of the source in the operational period ``t`` depends on the time-dependent `Profile` variable. | ||
|
||
!!! note | ||
If not needed, the production does not need to run at full capacity. The amount of energy *not* produced is computed using the non-negative [optimization variable](@ref optimization_variables) ``\texttt{curtailment}`` (declared for [`NonDisRES`](@ref) nodes only). | ||
|
||
The fields of the different types are listed below: | ||
## [Module](@id lib-pub-module) | ||
|
||
```@docs | ||
NonDisRES | ||
EnergyModelsRenewableProducers | ||
``` | ||
|
||
## [`HydroStorage` (regulated hydro storage with or without pump)](@id HydroStorage_public) | ||
|
||
A hydropower plant is much more flexible than, *e.g.*, a wind farm since the water can be stored for later use. | ||
Energy can be produced (almost) whenever it is needed. | ||
Some hydropower plants also have pumps installed. | ||
These are used to pump water into the reservoir when excess and cheap energy is available in the network. | ||
`EnergyModelsRenewableProducers` introduces hence two different types representing a regulated hydropower plant ([`HydroStor`](@ref)) and a pumped regulated hydropower plant ([`PumpedHydroStor`](@ref)) without a lower reservoir. | ||
Both types have a `level` and `discharge` capacity while a `PumpedHydroStor` also includes a `charge` capacity. | ||
## [Node types](@id lib-pub-node) | ||
|
||
The variable `level_init` represents the initial energy available in the reservoir in the beginning of each investment period. | ||
The variable `level_inflow` describes the inflow into the reservoir (measured in energy units), while `level_min` is the allowed minimum storage level in the dam, given as a ratio of the installed storage capacity of the reservoir at | ||
every operational period. | ||
The required minimum level is enforced by NVE and varies over the year. | ||
The resources stored in the hydro storage is set as `stor_res`, similar to a regular `EMB.RefStorage`. | ||
### [Abstract types](@id lib-pub-node-abstract) | ||
|
||
The five last parameters are used in the same way as in `EMB.Storage`. | ||
In the implementation of [`PumpedHydroStor`](@ref), the values set in `input` represents a loss of energy when using the pumps. | ||
A value of `1` means no energy loss, while a value of `0` represents 100% energy loss of that inflow variable. | ||
```@docs | ||
HydroStorage | ||
``` | ||
|
||
The fields of the different types are listed below: | ||
### [Concrete types](@id lib-pub-node-concrete) | ||
|
||
```@docs | ||
HydroStorage | ||
NonDisRES | ||
HydroStor | ||
PumpedHydroStor | ||
``` | ||
|
||
In recent version increases, we changed the individual fields of the `HydroStorage` nodes as well as their types. | ||
Hence, we still incorporate legacy constructors that can be utilized when having a model in previous versions. | ||
However, we removed one legacy constructor as it is no longer required. | ||
Calling the constructor will provide you now with an error. | ||
|
||
This legacy constructor is: | ||
### [Legacy constructors](@id lib-pub-node-legacy) | ||
|
||
```@docs | ||
RegHydroStor | ||
``` | ||
|
||
See the section on *[how to update models](@ref update-models)* for further information regarding how you can translate your existing model to the new model. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.
e239f80
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@JuliaRegistrator register
e239f80
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Registration pull request created: JuliaRegistries/General/114602
Tip: Release Notes
Did you know you can add release notes too? Just add markdown formatted text underneath the comment after the text
"Release notes:" and it will be added to the registry PR, and if TagBot is installed it will also be added to the
release that TagBot creates. i.e.
To add them here just re-invoke and the PR will be updated.
Tagging
After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.
This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via: