Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

90.1 PRM: fan power additional properties only populated for zones on AirLoops #1523

Open
eringold opened this issue Jun 2, 2023 · 3 comments
Assignees
Labels
AppendixG Methods to enable the Appendix G model workflow

Comments

@eringold
Copy link
Collaborator

eringold commented Jun 2, 2023

@dmaddoxwhite @lymereJ @weilixu Another issue trying to use model_create_prm_stable_baseline_building on an actual model.

Fan power additional properties are set for zones served by AirLoopHVACs in the proposed model:

if model_get_fan_power_breakdown
model.getAirLoopHVACs.sort.each do |air_loop|
supply_fan_w = air_loop_hvac_get_supply_fan_power(air_loop)
return_fan_w = air_loop_hvac_get_return_fan_power(air_loop)
relief_fan_w = air_loop_hvac_get_relief_fan_power(air_loop)
# Save fan power at the zone to determining
# baseline fan power
air_loop.thermalZones.sort.each do |zone|
zone.additionalProperties.setFeature('supply_fan_w', supply_fan_w.to_f)
zone.additionalProperties.setFeature('return_fan_w', return_fan_w.to_f)
zone.additionalProperties.setFeature('relief_fan_w', relief_fan_w.to_f)
end
end
end

After baseline air systems are made, those properties are queried:

supply_fan_power_fraction += zone_air_flow * zone.additionalProperties.getFeatureAsDouble('supply_fan_w').get
return_fan_power_fraction += zone_air_flow * zone.additionalProperties.getFeatureAsDouble('return_fan_w').get
relief_fan_power_fraction += zone_air_flow * zone.additionalProperties.getFeatureAsDouble('relief_fan_w').get

For zones that aren't served by AirLoops in the proposed model, but end up added to one in the Baseline model, those additional properties don't exist, and because zone.additionalProperties.getFeatureAsDouble isn't 'checked', they will throw 'optional is not initialized' errors. I believe such an occurance is very likely with actual proposed models (e.g. zones served by FCUs, but that don't have different enough loads to kick them into their own single-zone systems in the baseline).

Suggest querying and adding additional properties for more HVAC types in the proposed, or handling missing additional properties within air_loop_hvac_apply_prm_baseline_fan_power.

@eringold eringold changed the title Appendix G: fan power additional properties only populated for zones on AirLoops 90.1 PRM: fan power additional properties only populated for zones on AirLoops Jun 2, 2023
@lymereJ
Copy link
Collaborator

lymereJ commented Jun 2, 2023

Thanks for reporting that issue! I'll push some changes to address it. Would you be able to share a model that we could use for testing this defect?

@lymereJ lymereJ self-assigned this Jun 2, 2023
@lymereJ lymereJ added the AppendixG Methods to enable the Appendix G model workflow label Jun 2, 2023
@eringold
Copy link
Collaborator Author

eringold commented Jun 2, 2023

@lymereJ possibly. It's kind of an unwieldy model, probably not great to have as part of a test suite. Once I'm past this deadline I can see if I can mock something up that would be lighter.

This is also my first (and rushed) attempt at using the new PRM template, so it's possible there are things about how it expects the model to be setup that I haven't fully grasped.

@lymereJ
Copy link
Collaborator

lymereJ commented Jun 2, 2023

Sure, thanks!

If you want to share the rough model for now that'd be great, we could use it to test this fix internally and we could integrate the "better" model later.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
AppendixG Methods to enable the Appendix G model workflow
Projects
None yet
Development

No branches or pull requests

2 participants