-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #337 from NREL/develop
Add ElectricHeater Technology
- Loading branch information
Showing
26 changed files
with
356 additions
and
158 deletions.
There are no files selected for viewing
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
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 |
---|---|---|
@@ -1,7 +1,7 @@ | ||
name = "REopt" | ||
uuid = "d36ad4e8-d74a-4f7a-ace1-eaea049febf6" | ||
authors = ["Nick Laws", "Hallie Dunham <[email protected]>", "Bill Becker <[email protected]>", "Bhavesh Rathod <[email protected]>", "Alex Zolan <[email protected]>", "Amanda Farthing <[email protected]>"] | ||
version = "0.38.2" | ||
version = "0.39.0" | ||
|
||
[deps] | ||
ArchGDAL = "c9ce4bd3-c3d5-55b8-8973-c0e20141b8c3" | ||
|
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,8 @@ | ||
{ | ||
"installed_cost_per_mmbtu_per_hour": 154902, | ||
"om_cost_per_mmbtu_per_hour": 0.0, | ||
"macrs_option_years": 0, | ||
"macrs_bonus_fraction": 0.0, | ||
"can_supply_steam_turbine": false, | ||
"cop": 1.0 | ||
} |
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
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 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 |
---|---|---|
@@ -0,0 +1,99 @@ | ||
# REopt®, Copyright (c) Alliance for Sustainable Energy, LLC. See also https://github.com/NREL/REopt.jl/blob/master/LICENSE. | ||
|
||
struct ElectricHeater <: AbstractThermalTech | ||
min_kw::Real | ||
max_kw::Real | ||
installed_cost_per_kw::Real | ||
om_cost_per_kw::Real | ||
macrs_option_years::Int | ||
macrs_bonus_fraction::Real | ||
can_supply_steam_turbine::Bool | ||
cop::Real | ||
end | ||
|
||
|
||
""" | ||
ElectricHeater | ||
If a user provides the `ElectricHeater` key then the optimal scenario has the option to purchase | ||
this new `ElectricHeater` to meet the heating load in addition to using the `ExistingBoiler` | ||
to meet the heating load. | ||
```julia | ||
function ElectricHeater(; | ||
min_mmbtu_per_hour::Real = 0.0, # Minimum thermal power size | ||
max_mmbtu_per_hour::Real = BIG_NUMBER, # Maximum thermal power size | ||
installed_cost_per_mmbtu_per_hour::Union{Real, nothing} = nothing, # Thermal power-based cost | ||
om_cost_per_mmbtu_per_hour::Union{Real, nothing} = nothing, # Thermal power-based fixed O&M cost | ||
macrs_option_years::Int = 0, # MACRS schedule for financial analysis. Set to zero to disable | ||
macrs_bonus_fraction::Real = 0.0, # Fraction of upfront project costs to depreciate under MACRS | ||
can_supply_steam_turbine::Union{Bool, nothing} = nothing # If the boiler can supply steam to the steam turbine for electric production | ||
cop::Union{Real, nothing} = nothing # COP of the heating (i.e., thermal produced / electricity consumed) | ||
) | ||
``` | ||
""" | ||
function ElectricHeater(; | ||
min_mmbtu_per_hour::Real = 0.0, | ||
max_mmbtu_per_hour::Real = BIG_NUMBER, | ||
installed_cost_per_mmbtu_per_hour::Union{Real, Nothing} = nothing, | ||
om_cost_per_mmbtu_per_hour::Union{Real, Nothing} = nothing, | ||
macrs_option_years::Int = 0, | ||
macrs_bonus_fraction::Real = 0.0, | ||
can_supply_steam_turbine::Union{Bool, Nothing} = nothing, | ||
cop::Union{Real, Nothing} = nothing | ||
) | ||
|
||
defaults = get_electric_heater_defaults() | ||
|
||
# populate defaults as needed | ||
if isnothing(installed_cost_per_mmbtu_per_hour) | ||
installed_cost_per_mmbtu_per_hour = defaults["installed_cost_per_mmbtu_per_hour"] | ||
end | ||
if isnothing(om_cost_per_mmbtu_per_hour) | ||
om_cost_per_mmbtu_per_hour = defaults["om_cost_per_mmbtu_per_hour"] | ||
end | ||
if isnothing(can_supply_steam_turbine) | ||
can_supply_steam_turbine = defaults["can_supply_steam_turbine"] | ||
end | ||
if isnothing(cop) | ||
cop = defaults["cop"] | ||
end | ||
|
||
# Convert max sizes, cost factors from mmbtu_per_hour to kw | ||
min_kw = min_mmbtu_per_hour * KWH_PER_MMBTU | ||
max_kw = max_mmbtu_per_hour * KWH_PER_MMBTU | ||
|
||
|
||
installed_cost_per_kw = installed_cost_per_mmbtu_per_hour / KWH_PER_MMBTU | ||
om_cost_per_kw = om_cost_per_mmbtu_per_hour / KWH_PER_MMBTU | ||
|
||
|
||
ElectricHeater( | ||
min_kw, | ||
max_kw, | ||
installed_cost_per_kw, | ||
om_cost_per_kw, | ||
macrs_option_years, | ||
macrs_bonus_fraction, | ||
can_supply_steam_turbine, | ||
cop | ||
) | ||
end | ||
|
||
|
||
|
||
""" | ||
function get_electric_heater_defaults() | ||
Obtains defaults for the electric heater from a JSON data file. | ||
inputs | ||
None | ||
returns | ||
eh_defaults::Dict -- Dictionary containing defaults for electric heater | ||
""" | ||
function get_electric_heater_defaults() | ||
eh_defaults = JSON.parsefile(joinpath(dirname(@__FILE__), "..", "..", "data", "electric_heater", "electric_heater_defaults.json")) | ||
return eh_defaults | ||
end |
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
Oops, something went wrong.
8c9f19b
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
8c9f19b
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/96806
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: