honeybee-openstudio 2.37.0 → 2.38.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/honeybee-openstudio.gemspec +1 -1
- data/lib/honeybee/_defaults/model.json +174 -2
- data/lib/honeybee/generator/loadcenter.rb +42 -0
- data/lib/honeybee/generator/pv.rb +42 -0
- data/lib/honeybee.rb +4 -0
- data/lib/to_openstudio/generator/loadcenter.rb +71 -0
- data/lib/to_openstudio/generator/pv.rb +86 -0
- data/lib/to_openstudio/geometry/shade.rb +7 -0
- data/lib/to_openstudio/model.rb +15 -0
- data/lib/to_openstudio.rb +4 -0
- metadata +6 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 29f2ccee97b67e79d4c5ac17749a0e27d3fbce5c39a9bd35b1cc8ede1e4b324b
|
4
|
+
data.tar.gz: 543203bb0e0b04b2e333c5b6cdb4e0d9d9f71dce069cdca49ce885d46eb406e1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f774d8538c3a2ef55628adabc6ff8a733113bf2aa8a0584cc63364750d214bb800ae4dcf002c74d0b4260d9e7c921ee42003e4ba09e1c337c2551581aa6fe615
|
7
|
+
data.tar.gz: 5bbe03f646a5e63b058c10a556a0694f1eaf84e74d88921c5c247a62d91a4908435093d22406f73f415f9b282393783f6740cfcc2fda238cf9d80da1eb4330aa
|
data/honeybee-openstudio.gemspec
CHANGED
@@ -4,7 +4,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
|
4
4
|
|
5
5
|
Gem::Specification.new do |spec|
|
6
6
|
spec.name = 'honeybee-openstudio'
|
7
|
-
spec.version = '2.
|
7
|
+
spec.version = '2.38.0'
|
8
8
|
spec.authors = ['Tanushree Charan', 'Dan Macumber', 'Chris Mackey', 'Mostapha Sadeghipour Roudsari']
|
9
9
|
spec.email = ['tanushree.charan@nrel.gov', 'chris@ladybug.tools']
|
10
10
|
|
@@ -3,7 +3,7 @@
|
|
3
3
|
"servers": [],
|
4
4
|
"info": {
|
5
5
|
"description": "Honeybee model schema.",
|
6
|
-
"version": "1.
|
6
|
+
"version": "1.55.0",
|
7
7
|
"title": "Honeybee Model Schema",
|
8
8
|
"contact": {
|
9
9
|
"name": "Ladybug Tools",
|
@@ -204,6 +204,11 @@
|
|
204
204
|
"x-displayName": "ElectricEquipmentAbridged",
|
205
205
|
"description": "<SchemaDefinition schemaRef=\"#/components/schemas/ElectricEquipmentAbridged\" />\n"
|
206
206
|
},
|
207
|
+
{
|
208
|
+
"name": "electricloadcenter_model",
|
209
|
+
"x-displayName": "ElectricLoadCenter",
|
210
|
+
"description": "<SchemaDefinition schemaRef=\"#/components/schemas/ElectricLoadCenter\" />\n"
|
211
|
+
},
|
207
212
|
{
|
208
213
|
"name": "energymaterial_model",
|
209
214
|
"x-displayName": "EnergyMaterial",
|
@@ -484,11 +489,21 @@
|
|
484
489
|
"x-displayName": "ModifierSetAbridged",
|
485
490
|
"description": "<SchemaDefinition schemaRef=\"#/components/schemas/ModifierSetAbridged\" />\n"
|
486
491
|
},
|
492
|
+
{
|
493
|
+
"name": "moduletype_model",
|
494
|
+
"x-displayName": "ModuleType",
|
495
|
+
"description": "<SchemaDefinition schemaRef=\"#/components/schemas/ModuleType\" />\n"
|
496
|
+
},
|
487
497
|
{
|
488
498
|
"name": "moisturediffusionmodel_model",
|
489
499
|
"x-displayName": "MoistureDiffusionModel",
|
490
500
|
"description": "<SchemaDefinition schemaRef=\"#/components/schemas/MoistureDiffusionModel\" />\n"
|
491
501
|
},
|
502
|
+
{
|
503
|
+
"name": "mountingtype_model",
|
504
|
+
"x-displayName": "MountingType",
|
505
|
+
"description": "<SchemaDefinition schemaRef=\"#/components/schemas/MountingType\" />\n"
|
506
|
+
},
|
492
507
|
{
|
493
508
|
"name": "nolimit_model",
|
494
509
|
"x-displayName": "NoLimit",
|
@@ -544,6 +559,11 @@
|
|
544
559
|
"x-displayName": "PVAVEquipmentType",
|
545
560
|
"description": "<SchemaDefinition schemaRef=\"#/components/schemas/PVAVEquipmentType\" />\n"
|
546
561
|
},
|
562
|
+
{
|
563
|
+
"name": "pvproperties_model",
|
564
|
+
"x-displayName": "PVProperties",
|
565
|
+
"description": "<SchemaDefinition schemaRef=\"#/components/schemas/PVProperties\" />\n"
|
566
|
+
},
|
547
567
|
{
|
548
568
|
"name": "people_model",
|
549
569
|
"x-displayName": "People",
|
@@ -1050,6 +1070,7 @@
|
|
1050
1070
|
"economizertype_model",
|
1051
1071
|
"electricequipment_model",
|
1052
1072
|
"electricequipmentabridged_model",
|
1073
|
+
"electricloadcenter_model",
|
1053
1074
|
"energymaterial_model",
|
1054
1075
|
"energymaterialnomass_model",
|
1055
1076
|
"energymaterialvegetation_model",
|
@@ -1106,7 +1127,9 @@
|
|
1106
1127
|
"modelradianceproperties_model",
|
1107
1128
|
"modifierset_model",
|
1108
1129
|
"modifiersetabridged_model",
|
1130
|
+
"moduletype_model",
|
1109
1131
|
"moisturediffusionmodel_model",
|
1132
|
+
"mountingtype_model",
|
1110
1133
|
"nolimit_model",
|
1111
1134
|
"opaqueconstruction_model",
|
1112
1135
|
"opaqueconstructionabridged_model",
|
@@ -1125,6 +1148,7 @@
|
|
1125
1148
|
"ptacequipmenttype_model",
|
1126
1149
|
"pvav_model",
|
1127
1150
|
"pvavequipmenttype_model",
|
1151
|
+
"pvproperties_model",
|
1128
1152
|
"radianceshadestateabridged_model",
|
1129
1153
|
"radiancesubfacestateabridged_model",
|
1130
1154
|
"radiant_model",
|
@@ -1495,6 +1519,104 @@
|
|
1495
1519
|
},
|
1496
1520
|
"additionalProperties": false
|
1497
1521
|
},
|
1522
|
+
"ModuleType": {
|
1523
|
+
"title": "ModuleType",
|
1524
|
+
"description": "An enumeration.",
|
1525
|
+
"enum": [
|
1526
|
+
"Standard",
|
1527
|
+
"Premium",
|
1528
|
+
"ThinFilm"
|
1529
|
+
],
|
1530
|
+
"type": "string"
|
1531
|
+
},
|
1532
|
+
"MountingType": {
|
1533
|
+
"title": "MountingType",
|
1534
|
+
"description": "An enumeration.",
|
1535
|
+
"enum": [
|
1536
|
+
"FixedOpenRack",
|
1537
|
+
"FixedRoofMounted",
|
1538
|
+
"OneAxis",
|
1539
|
+
"OneAxisBacktracking",
|
1540
|
+
"TwoAxis"
|
1541
|
+
],
|
1542
|
+
"type": "string"
|
1543
|
+
},
|
1544
|
+
"PVProperties": {
|
1545
|
+
"title": "PVProperties",
|
1546
|
+
"description": "Base class for all objects requiring a valid EnergyPlus identifier.",
|
1547
|
+
"type": "object",
|
1548
|
+
"properties": {
|
1549
|
+
"identifier": {
|
1550
|
+
"title": "Identifier",
|
1551
|
+
"description": "Text string for a unique object ID. This identifier remains constant as the object is mutated, copied, and serialized to different formats (eg. dict, idf, osm). This identifier is also used to reference the object across a Model. It must be < 100 characters, use only ASCII characters and exclude (, ; ! \\n \\t).",
|
1552
|
+
"maxLength": 100,
|
1553
|
+
"minLength": 1,
|
1554
|
+
"pattern": "^[^,;!\\n\\t]+$",
|
1555
|
+
"type": "string"
|
1556
|
+
},
|
1557
|
+
"display_name": {
|
1558
|
+
"title": "Display Name",
|
1559
|
+
"description": "Display name of the object with no character restrictions.",
|
1560
|
+
"type": "string"
|
1561
|
+
},
|
1562
|
+
"type": {
|
1563
|
+
"title": "Type",
|
1564
|
+
"default": "PVProperties",
|
1565
|
+
"pattern": "^PVProperties$",
|
1566
|
+
"type": "string",
|
1567
|
+
"readOnly": true
|
1568
|
+
},
|
1569
|
+
"rated_efficiency": {
|
1570
|
+
"title": "Rated Efficiency",
|
1571
|
+
"description": "A number between 0 and 1 for the rated nameplate efficiency of the photovoltaic solar cells under standard test conditions (STC). Standard test conditions are 1,000 Watts per square meter solar irradiance, 25 degrees C cell temperature, and ASTM G173-03 standard spectrum. Nameplate efficiencies reported by manufacturers are typically under STC. Standard poly- or mono-crystalline silicon modules tend to have rated efficiencies in the range of 14-17%. Premium high efficiency mono-crystalline silicon modules with anti-reflective coatings can have efficiencies in the range of 18-20%. Thin film photovoltaic modules typically have efficiencies of 11% or less. (Default: 0.15 for standard silicon solar cells).",
|
1572
|
+
"default": 0.15,
|
1573
|
+
"exclusiveMinimum": 0,
|
1574
|
+
"exclusiveMaximum": 1,
|
1575
|
+
"type": "number",
|
1576
|
+
"format": "double"
|
1577
|
+
},
|
1578
|
+
"active_area_fraction": {
|
1579
|
+
"title": "Active Area Fraction",
|
1580
|
+
"description": "The fraction of the parent Shade geometry that is covered in active solar cells. This fraction includes the difference between the PV panel (aka. PV module) area and the active cells within the panel as well as any losses for how the (typically rectangular) panels can be arranged on the Shade geometry. When the parent Shade geometry represents just the solar panels, this fraction is typically around 0.9 given that the framing elements of the panel reduce the overall active area. (Default: 0.9, assuming parent Shade geometry represents only the PV panel geometry).",
|
1581
|
+
"default": 0.9,
|
1582
|
+
"exclusiveMinimum": 0,
|
1583
|
+
"maximum": 1,
|
1584
|
+
"type": "number",
|
1585
|
+
"format": "double"
|
1586
|
+
},
|
1587
|
+
"module_type": {
|
1588
|
+
"description": "Text to indicate the type of solar module. This is used to determine the temperature coefficients used in the simulation of the photovoltaic modules. When the rated_efficiency is between 12-18%, the Standard type is typically most appropriate. When the rated_efficiency is greater than 18%, the Premium type is likely more appropriate. When the rated_efficiency is less than 12%, this likely refers to a case where the ThinFilm module type is most appropriate.",
|
1589
|
+
"default": "Standard",
|
1590
|
+
"allOf": [
|
1591
|
+
{
|
1592
|
+
"$ref": "#/components/schemas/ModuleType"
|
1593
|
+
}
|
1594
|
+
]
|
1595
|
+
},
|
1596
|
+
"mounting_type": {
|
1597
|
+
"description": "Text to indicate the type of mounting and/or tracking used for the photovoltaic array. Note that the OneAxis options have an axis of rotation that is determined by the azimuth of the parent Shade geometry. Also note that, in the case of one or two axis tracking, shadows on the (static) parent Shade geometry still reduce the electrical output, enabling the simulation to account for large context geometry casting shadows on the array. However, the effects of smaller detailed shading may be improperly accounted for and self shading of the dynamic panel geometry is only accounted for via the tracking_ground_coverage_ratio property on this object. FixedOpenRack refers to ground or roof mounting where the air flows freely. FixedRoofMounted refers to mounting flush with the roof with limited air flow. OneAxis refers to a fixed tilt and azimuth, which define an axis of rotation. OneAxisBacktracking is the same as OneAxis but with controls to reduce self-shade at low sun angles. TwoAxis refers to a dynamic tilt and azimuth that track the sun.",
|
1598
|
+
"default": "FixedOpenRack",
|
1599
|
+
"allOf": [
|
1600
|
+
{
|
1601
|
+
"$ref": "#/components/schemas/MountingType"
|
1602
|
+
}
|
1603
|
+
]
|
1604
|
+
},
|
1605
|
+
"system_loss_fraction": {
|
1606
|
+
"title": "System Loss Fraction",
|
1607
|
+
"description": "A number between 0 and 1 for the fraction of the electricity output lost due to factors other than EPW weather conditions, panel efficiency/type, active area, mounting, and inverter conversion from DC to AC. Factors that should be accounted for in this input include soiling, snow, wiring losses, electrical connection losses, manufacturer defects/tolerances/mismatch in cell characteristics, losses from power grid availability, and losses due to age or light-induced degradation. Losses from these factors tend to be between 10-20% but can vary widely depending on the installation, maintenance and the grid to which the panels are connected..",
|
1608
|
+
"default": 0.14,
|
1609
|
+
"minimum": 0,
|
1610
|
+
"maximum": 1,
|
1611
|
+
"type": "number",
|
1612
|
+
"format": "double"
|
1613
|
+
}
|
1614
|
+
},
|
1615
|
+
"required": [
|
1616
|
+
"identifier"
|
1617
|
+
],
|
1618
|
+
"additionalProperties": false
|
1619
|
+
},
|
1498
1620
|
"ShadeEnergyPropertiesAbridged": {
|
1499
1621
|
"title": "ShadeEnergyPropertiesAbridged",
|
1500
1622
|
"description": "Base class for all objects that are not extensible with additional keys.\n\nThis effectively includes all objects except for the Properties classes\nthat are assigned to geometry objects.",
|
@@ -1520,6 +1642,15 @@
|
|
1520
1642
|
"maxLength": 100,
|
1521
1643
|
"minLength": 1,
|
1522
1644
|
"type": "string"
|
1645
|
+
},
|
1646
|
+
"pv_properties": {
|
1647
|
+
"title": "Pv Properties",
|
1648
|
+
"description": "An optional PVProperties object to specify photovoltaic behavior of the Shade. If None, the Shade will have no Photovoltaic properties. Note that the normal of the Shade is important in determining the performance of the shade as a PV geometry.",
|
1649
|
+
"allOf": [
|
1650
|
+
{
|
1651
|
+
"$ref": "#/components/schemas/PVProperties"
|
1652
|
+
}
|
1653
|
+
]
|
1523
1654
|
}
|
1524
1655
|
},
|
1525
1656
|
"additionalProperties": false
|
@@ -10841,6 +10972,38 @@
|
|
10841
10972
|
},
|
10842
10973
|
"additionalProperties": false
|
10843
10974
|
},
|
10975
|
+
"ElectricLoadCenter": {
|
10976
|
+
"title": "ElectricLoadCenter",
|
10977
|
+
"description": "Base class for all objects that are not extensible with additional keys.\n\nThis effectively includes all objects except for the Properties classes\nthat are assigned to geometry objects.",
|
10978
|
+
"type": "object",
|
10979
|
+
"properties": {
|
10980
|
+
"type": {
|
10981
|
+
"title": "Type",
|
10982
|
+
"default": "ElectricLoadCenter",
|
10983
|
+
"pattern": "^ElectricLoadCenter$",
|
10984
|
+
"type": "string",
|
10985
|
+
"readOnly": true
|
10986
|
+
},
|
10987
|
+
"inverter_efficiency": {
|
10988
|
+
"title": "Inverter Efficiency",
|
10989
|
+
"description": "A number between 0 and 1 for the load center inverter nominal rated DC-to-AC conversion efficiency. An inverter converts DC power, such as that output by photovoltaic panels, to AC power, such as that distributed by the electrical grid and is available from standard electrical outlets. Inverter efficiency is defined as the inverter rated AC power output divided by its rated DC power output.",
|
10990
|
+
"default": 0.96,
|
10991
|
+
"exclusiveMinimum": 0,
|
10992
|
+
"maximum": 1,
|
10993
|
+
"type": "number",
|
10994
|
+
"format": "double"
|
10995
|
+
},
|
10996
|
+
"inverter_dc_to_ac_size_ratio": {
|
10997
|
+
"title": "Inverter Dc To Ac Size Ratio",
|
10998
|
+
"description": "A positive number (typically greater than 1) for the ratio of the inverter DC rated size to its AC rated size. Typically, inverters are not sized to convert the full DC output under standard test conditions (STC) as such conditions rarely occur in reality and therefore unnecessarily add to the size/cost of the inverter. For a system with a high DC to AC size ratio, during times when the DC power output exceeds the inverter rated DC input size, the inverter limits the power output by increasing the DC operating voltage, which moves the arrays operating point down its current-voltage (I-V) curve. In EnergyPlus, this is accomplished by simply limiting the system output to the AC size as dictated by the ratio. The default value of 1.1 is reasonable for most systems. A typical range is 1.1 to 1.25, although some large-scale systems have ratios of as high as 1.5. The optimal value depends on the system location, array orientation, and module cost.",
|
10999
|
+
"default": 1.1,
|
11000
|
+
"exclusiveMinimum": 0,
|
11001
|
+
"type": "number",
|
11002
|
+
"format": "double"
|
11003
|
+
}
|
11004
|
+
},
|
11005
|
+
"additionalProperties": false
|
11006
|
+
},
|
10844
11007
|
"ModelEnergyProperties": {
|
10845
11008
|
"title": "ModelEnergyProperties",
|
10846
11009
|
"description": "Base class for all objects that are not extensible with additional keys.\n\nThis effectively includes all objects except for the Properties classes\nthat are assigned to geometry objects.",
|
@@ -11521,6 +11684,15 @@
|
|
11521
11684
|
"$ref": "#/components/schemas/VentilationSimulationControl"
|
11522
11685
|
}
|
11523
11686
|
]
|
11687
|
+
},
|
11688
|
+
"electric_load_center": {
|
11689
|
+
"title": "Electric Load Center",
|
11690
|
+
"description": "An optional parameter object that defines the properties of the model electric loads center that manages on site electricity generation and conversion.",
|
11691
|
+
"allOf": [
|
11692
|
+
{
|
11693
|
+
"$ref": "#/components/schemas/ElectricLoadCenter"
|
11694
|
+
}
|
11695
|
+
]
|
11524
11696
|
}
|
11525
11697
|
},
|
11526
11698
|
"additionalProperties": false
|
@@ -14623,7 +14795,7 @@
|
|
14623
14795
|
"version": {
|
14624
14796
|
"title": "Version",
|
14625
14797
|
"description": "Text string for the current version of the schema.",
|
14626
|
-
"default": "1.
|
14798
|
+
"default": "1.55.0",
|
14627
14799
|
"pattern": "([0-9]+)\\.([0-9]+)\\.([0-9]+)",
|
14628
14800
|
"type": "string",
|
14629
14801
|
"readOnly": true
|
@@ -0,0 +1,42 @@
|
|
1
|
+
# *******************************************************************************
|
2
|
+
# Honeybee OpenStudio Gem, Copyright (c) 2020, Alliance for Sustainable
|
3
|
+
# Energy, LLC, Ladybug Tools LLC and other contributors. All rights reserved.
|
4
|
+
#
|
5
|
+
# Redistribution and use in source and binary forms, with or without
|
6
|
+
# modification, are permitted provided that the following conditions are met:
|
7
|
+
#
|
8
|
+
# (1) Redistributions of source code must retain the above copyright notice,
|
9
|
+
# this list of conditions and the following disclaimer.
|
10
|
+
#
|
11
|
+
# (2) Redistributions in binary form must reproduce the above copyright notice,
|
12
|
+
# this list of conditions and the following disclaimer in the documentation
|
13
|
+
# and/or other materials provided with the distribution.
|
14
|
+
#
|
15
|
+
# (3) Neither the name of the copyright holder nor the names of any contributors
|
16
|
+
# may be used to endorse or promote products derived from this software without
|
17
|
+
# specific prior written permission from the respective party.
|
18
|
+
#
|
19
|
+
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) AND ANY CONTRIBUTORS
|
20
|
+
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
|
21
|
+
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
22
|
+
# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER(S), ANY CONTRIBUTORS, THE
|
23
|
+
# UNITED STATES GOVERNMENT, OR THE UNITED STATES DEPARTMENT OF ENERGY, NOR ANY OF
|
24
|
+
# THEIR EMPLOYEES, BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
|
25
|
+
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
26
|
+
# OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
27
|
+
# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
28
|
+
# STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
29
|
+
# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
30
|
+
# *******************************************************************************
|
31
|
+
|
32
|
+
require 'honeybee/model_object'
|
33
|
+
|
34
|
+
module Honeybee
|
35
|
+
class ElectricLoadCenter < ModelObject
|
36
|
+
|
37
|
+
def defaults
|
38
|
+
@@schema[:components][:schemas][:ElectricLoadCenter][:properties]
|
39
|
+
end
|
40
|
+
|
41
|
+
end #ElectricLoadCenter
|
42
|
+
end #Honeybee
|
@@ -0,0 +1,42 @@
|
|
1
|
+
# *******************************************************************************
|
2
|
+
# Honeybee OpenStudio Gem, Copyright (c) 2020, Alliance for Sustainable
|
3
|
+
# Energy, LLC, Ladybug Tools LLC and other contributors. All rights reserved.
|
4
|
+
#
|
5
|
+
# Redistribution and use in source and binary forms, with or without
|
6
|
+
# modification, are permitted provided that the following conditions are met:
|
7
|
+
#
|
8
|
+
# (1) Redistributions of source code must retain the above copyright notice,
|
9
|
+
# this list of conditions and the following disclaimer.
|
10
|
+
#
|
11
|
+
# (2) Redistributions in binary form must reproduce the above copyright notice,
|
12
|
+
# this list of conditions and the following disclaimer in the documentation
|
13
|
+
# and/or other materials provided with the distribution.
|
14
|
+
#
|
15
|
+
# (3) Neither the name of the copyright holder nor the names of any contributors
|
16
|
+
# may be used to endorse or promote products derived from this software without
|
17
|
+
# specific prior written permission from the respective party.
|
18
|
+
#
|
19
|
+
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) AND ANY CONTRIBUTORS
|
20
|
+
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
|
21
|
+
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
22
|
+
# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER(S), ANY CONTRIBUTORS, THE
|
23
|
+
# UNITED STATES GOVERNMENT, OR THE UNITED STATES DEPARTMENT OF ENERGY, NOR ANY OF
|
24
|
+
# THEIR EMPLOYEES, BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
|
25
|
+
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
26
|
+
# OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
27
|
+
# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
28
|
+
# STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
29
|
+
# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
30
|
+
# *******************************************************************************
|
31
|
+
|
32
|
+
require 'honeybee/model_object'
|
33
|
+
|
34
|
+
module Honeybee
|
35
|
+
class PVProperties < ModelObject
|
36
|
+
|
37
|
+
def defaults
|
38
|
+
@@schema[:components][:schemas][:PVProperties][:properties]
|
39
|
+
end
|
40
|
+
|
41
|
+
end #PVProperties
|
42
|
+
end #Honeybee
|
data/lib/honeybee.rb
CHANGED
@@ -96,6 +96,10 @@ require 'honeybee/ventcool/opening'
|
|
96
96
|
require 'honeybee/ventcool/simulation'
|
97
97
|
require 'honeybee/internalmass'
|
98
98
|
|
99
|
+
# import the generator objects
|
100
|
+
require 'honeybee/generator/loadcenter'
|
101
|
+
require 'honeybee/generator/pv'
|
102
|
+
|
99
103
|
# import the simulation objects
|
100
104
|
require 'honeybee/simulation/design_day'
|
101
105
|
require 'honeybee/simulation/parameter_model'
|
@@ -0,0 +1,71 @@
|
|
1
|
+
# *******************************************************************************
|
2
|
+
# Honeybee OpenStudio Gem, Copyright (c) 2020, Alliance for Sustainable
|
3
|
+
# Energy, LLC, Ladybug Tools LLC and other contributors. All rights reserved.
|
4
|
+
#
|
5
|
+
# Redistribution and use in source and binary forms, with or without
|
6
|
+
# modification, are permitted provided that the following conditions are met:
|
7
|
+
#
|
8
|
+
# (1) Redistributions of source code must retain the above copyright notice,
|
9
|
+
# this list of conditions and the following disclaimer.
|
10
|
+
#
|
11
|
+
# (2) Redistributions in binary form must reproduce the above copyright notice,
|
12
|
+
# this list of conditions and the following disclaimer in the documentation
|
13
|
+
# and/or other materials provided with the distribution.
|
14
|
+
#
|
15
|
+
# (3) Neither the name of the copyright holder nor the names of any contributors
|
16
|
+
# may be used to endorse or promote products derived from this software without
|
17
|
+
# specific prior written permission from the respective party.
|
18
|
+
#
|
19
|
+
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) AND ANY CONTRIBUTORS
|
20
|
+
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
|
21
|
+
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
22
|
+
# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER(S), ANY CONTRIBUTORS, THE
|
23
|
+
# UNITED STATES GOVERNMENT, OR THE UNITED STATES DEPARTMENT OF ENERGY, NOR ANY OF
|
24
|
+
# THEIR EMPLOYEES, BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
|
25
|
+
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
26
|
+
# OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
27
|
+
# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
28
|
+
# STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
29
|
+
# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
30
|
+
# *******************************************************************************
|
31
|
+
|
32
|
+
require 'honeybee/generator/loadcenter'
|
33
|
+
|
34
|
+
require 'to_openstudio/model_object'
|
35
|
+
|
36
|
+
module Honeybee
|
37
|
+
class ElectricLoadCenter
|
38
|
+
|
39
|
+
def to_openstudio(openstudio_model, generator_objects)
|
40
|
+
# create the ElectricLoadCenter:Distribution specification
|
41
|
+
load_center = OpenStudio::Model::ElectricLoadCenterDistribution.new(openstudio_model)
|
42
|
+
load_center.setName('Model Load Center Distribution')
|
43
|
+
|
44
|
+
# add the generators to the specification
|
45
|
+
generator_objects.each do |gen_obj|
|
46
|
+
load_center.addGenerator(gen_obj)
|
47
|
+
end
|
48
|
+
|
49
|
+
# assign the major properties to the load center
|
50
|
+
load_center.setGeneratorOperationSchemeType('Baseload')
|
51
|
+
load_center.setElectricalBussType('DirectCurrentWithInverter')
|
52
|
+
|
53
|
+
# create the inverter and assign it
|
54
|
+
inverter = OpenStudio::Model::ElectricLoadCenterInverterPVWatts.new(openstudio_model)
|
55
|
+
if @hash[:inverter_dc_to_ac_size_ratio]
|
56
|
+
inverter.setDCToACSizeRatio(@hash[:inverter_dc_to_ac_size_ratio])
|
57
|
+
else
|
58
|
+
inverter.setDCToACSizeRatio(defaults[:inverter_dc_to_ac_size_ratio][:default])
|
59
|
+
end
|
60
|
+
if @hash[:inverter_efficiency]
|
61
|
+
inverter.setInverterEfficiency(@hash[:inverter_efficiency])
|
62
|
+
else
|
63
|
+
inverter.setInverterEfficiency(defaults[:inverter_efficiency][:default])
|
64
|
+
end
|
65
|
+
load_center.setInverter(inverter)
|
66
|
+
|
67
|
+
load_center
|
68
|
+
end
|
69
|
+
|
70
|
+
end #ElectricLoadCenter
|
71
|
+
end #Honeybee
|
@@ -0,0 +1,86 @@
|
|
1
|
+
# *******************************************************************************
|
2
|
+
# Honeybee OpenStudio Gem, Copyright (c) 2020, Alliance for Sustainable
|
3
|
+
# Energy, LLC, Ladybug Tools LLC and other contributors. All rights reserved.
|
4
|
+
#
|
5
|
+
# Redistribution and use in source and binary forms, with or without
|
6
|
+
# modification, are permitted provided that the following conditions are met:
|
7
|
+
#
|
8
|
+
# (1) Redistributions of source code must retain the above copyright notice,
|
9
|
+
# this list of conditions and the following disclaimer.
|
10
|
+
#
|
11
|
+
# (2) Redistributions in binary form must reproduce the above copyright notice,
|
12
|
+
# this list of conditions and the following disclaimer in the documentation
|
13
|
+
# and/or other materials provided with the distribution.
|
14
|
+
#
|
15
|
+
# (3) Neither the name of the copyright holder nor the names of any contributors
|
16
|
+
# may be used to endorse or promote products derived from this software without
|
17
|
+
# specific prior written permission from the respective party.
|
18
|
+
#
|
19
|
+
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) AND ANY CONTRIBUTORS
|
20
|
+
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
|
21
|
+
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
22
|
+
# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER(S), ANY CONTRIBUTORS, THE
|
23
|
+
# UNITED STATES GOVERNMENT, OR THE UNITED STATES DEPARTMENT OF ENERGY, NOR ANY OF
|
24
|
+
# THEIR EMPLOYEES, BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
|
25
|
+
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
26
|
+
# OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
27
|
+
# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
28
|
+
# STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
29
|
+
# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
30
|
+
# *******************************************************************************
|
31
|
+
|
32
|
+
require 'honeybee/generator/pv'
|
33
|
+
|
34
|
+
require 'to_openstudio/model_object'
|
35
|
+
|
36
|
+
module Honeybee
|
37
|
+
class PVProperties
|
38
|
+
|
39
|
+
def to_openstudio(openstudio_model, parent)
|
40
|
+
# calculate the DC system size from the efficiency and the parent area
|
41
|
+
rated_watts = defaults[:rated_efficiency][:default] * 1000
|
42
|
+
if @hash[:rated_efficiency]
|
43
|
+
rated_watts = @hash[:rated_efficiency] * 1000
|
44
|
+
end
|
45
|
+
active_fraction = defaults[:active_area_fraction][:default]
|
46
|
+
if @hash[:active_area_fraction]
|
47
|
+
active_fraction = @hash[:active_area_fraction]
|
48
|
+
end
|
49
|
+
sys_cap = parent.netArea * active_fraction * rated_watts
|
50
|
+
sys_cap = sys_cap.round
|
51
|
+
|
52
|
+
# create the PVWatts generator and set identifier
|
53
|
+
os_gen = OpenStudio::Model::GeneratorPVWatts.new(openstudio_model, parent, sys_cap)
|
54
|
+
os_gen.setName(@hash[:identifier] + '..' + parent.name.get)
|
55
|
+
|
56
|
+
# assign the module type
|
57
|
+
if @hash[:module_type]
|
58
|
+
os_gen.setModuleType(@hash[:module_type])
|
59
|
+
else
|
60
|
+
os_gen.setModuleType(defaults[:module_type][:default])
|
61
|
+
end
|
62
|
+
|
63
|
+
# assign the mounting type
|
64
|
+
if @hash[:mounting_type]
|
65
|
+
os_gen.setArrayType(@hash[:mounting_type])
|
66
|
+
else
|
67
|
+
os_gen.setArrayType(defaults[:mounting_type][:default])
|
68
|
+
end
|
69
|
+
|
70
|
+
# assign the system loss fraction
|
71
|
+
if @hash[:system_loss_fraction]
|
72
|
+
os_gen.setSystemLosses(@hash[:system_loss_fraction])
|
73
|
+
else
|
74
|
+
os_gen.setSystemLosses(defaults[:system_loss_fraction][:default])
|
75
|
+
end
|
76
|
+
|
77
|
+
# assign the tracking ground coverage ratio
|
78
|
+
if @hash[:tracking_ground_coverage_ratio]
|
79
|
+
os_gen.setGroundCoverageRatio(@hash[:tracking_ground_coverage_ratio])
|
80
|
+
end
|
81
|
+
|
82
|
+
os_gen
|
83
|
+
end
|
84
|
+
|
85
|
+
end #PVProperties
|
86
|
+
end #Honeybee
|
@@ -82,6 +82,13 @@ module Honeybee
|
|
82
82
|
os_shading_surface.setTransmittanceSchedule(os_schedule)
|
83
83
|
end
|
84
84
|
end
|
85
|
+
|
86
|
+
# create PV objects if there are properties
|
87
|
+
if @hash[:properties][:energy][:pv_properties]
|
88
|
+
gen_obj = PVProperties.new(@hash[:properties][:energy][:pv_properties])
|
89
|
+
os_gen_obj = gen_obj.to_openstudio(openstudio_model, os_shading_surface)
|
90
|
+
$generators << os_gen_obj
|
91
|
+
end
|
85
92
|
end
|
86
93
|
|
87
94
|
os_shading_surface
|
data/lib/to_openstudio/model.rb
CHANGED
@@ -133,6 +133,7 @@ module Honeybee
|
|
133
133
|
$shw_for_plant = nil # track whether a hot water plant is needed
|
134
134
|
$detailed_hvac_hash = Hash.new # track the detailed HVAC systems that have been assigned
|
135
135
|
$ironbug_exe = nil # ironbug executable; will be overwritten by any detailed HVACs
|
136
|
+
$generators = [] # track the generator objects in the model
|
136
137
|
|
137
138
|
# create all of the non-geometric model elements
|
138
139
|
if @hash[:properties].key?(:energy)
|
@@ -217,6 +218,20 @@ module Honeybee
|
|
217
218
|
create_orphaned_apertures
|
218
219
|
create_orphaned_doors
|
219
220
|
create_shade_meshes
|
221
|
+
|
222
|
+
unless $generators.empty?
|
223
|
+
if log_report
|
224
|
+
puts 'Translating Electricity Generators'
|
225
|
+
end
|
226
|
+
if @hash[:properties][:energy][:electric_load_center]
|
227
|
+
load_center_object = ElectricLoadCenter.new(
|
228
|
+
@hash[:properties][:energy][:electric_load_center])
|
229
|
+
else
|
230
|
+
empty_hash = Hash.new
|
231
|
+
load_center_object = ElectricLoadCenter.new(empty_hash)
|
232
|
+
end
|
233
|
+
load_center_object.to_openstudio(@openstudio_model, $generators)
|
234
|
+
end
|
220
235
|
end
|
221
236
|
|
222
237
|
def create_materials(material_dicts, check_existing=false)
|
data/lib/to_openstudio.rb
CHANGED
@@ -96,6 +96,10 @@ require 'to_openstudio/ventcool/opening'
|
|
96
96
|
require 'to_openstudio/ventcool/simulation'
|
97
97
|
require 'to_openstudio/internalmass'
|
98
98
|
|
99
|
+
# import the generator objects
|
100
|
+
require 'to_openstudio/generator/loadcenter'
|
101
|
+
require 'to_openstudio/generator/pv'
|
102
|
+
|
99
103
|
# extend the simulation objects
|
100
104
|
require 'to_openstudio/simulation/design_day'
|
101
105
|
require 'to_openstudio/simulation/parameter_model'
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: honeybee-openstudio
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.38.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tanushree Charan
|
@@ -11,7 +11,7 @@ authors:
|
|
11
11
|
autorequire:
|
12
12
|
bindir: exe
|
13
13
|
cert_chain: []
|
14
|
-
date:
|
14
|
+
date: 2024-01-03 00:00:00.000000000 Z
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
17
17
|
name: json_pure
|
@@ -133,6 +133,8 @@ files:
|
|
133
133
|
- lib/honeybee/construction/windowshade.rb
|
134
134
|
- lib/honeybee/construction_set.rb
|
135
135
|
- lib/honeybee/extension.rb
|
136
|
+
- lib/honeybee/generator/loadcenter.rb
|
137
|
+
- lib/honeybee/generator/pv.rb
|
136
138
|
- lib/honeybee/geometry/aperture.rb
|
137
139
|
- lib/honeybee/geometry/door.rb
|
138
140
|
- lib/honeybee/geometry/face.rb
|
@@ -226,6 +228,8 @@ files:
|
|
226
228
|
- lib/to_openstudio/construction/window.rb
|
227
229
|
- lib/to_openstudio/construction/windowshade.rb
|
228
230
|
- lib/to_openstudio/construction_set.rb
|
231
|
+
- lib/to_openstudio/generator/loadcenter.rb
|
232
|
+
- lib/to_openstudio/generator/pv.rb
|
229
233
|
- lib/to_openstudio/geometry/aperture.rb
|
230
234
|
- lib/to_openstudio/geometry/door.rb
|
231
235
|
- lib/to_openstudio/geometry/face.rb
|