-
Notifications
You must be signed in to change notification settings - Fork 396
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
Fix Fan:ZoneExhaust
AFN validation
#10661
Conversation
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.
Code walkthrough.
} | ||
if (!found) { | ||
ShowSevereError(m_state, format("{}Fan:ZoneExhaust is not defined in {}", RoutineName, CurrentModuleObject)); | ||
ShowContinueError( | ||
m_state, | ||
format("The inlet node of the {} Fan:ZoneExhaust is not defined in the {}'s ZoneHVAC:EquipmentConnections", | ||
m_state.dataZoneEquip->ZoneEquipList(j).EquipName, | ||
m_state.dataZoneEquip->ZoneEquipConfig(j).ZoneName)); | ||
ErrorsFound = true; |
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.
Moved this verification so it can be done after iterating through all exhaust nodes.
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.
👍 reasonable!
" ZoneHVAC:Dehumidifier:DX,", | ||
" North Zone Dehumidifier, !- Name", | ||
" always_avail, !- Availability Schedule Name", | ||
" Zone3DehumidifierInlet, !- Air Inlet Node Name", | ||
" Dehumidifier Outlet Node,!- Air Outlet Node Name", | ||
" 50.16, !- Rated Water Removal {L/day}", | ||
" 3.412, !- Rated Energy Factor {L/kWh}", | ||
" 0.12036, !- Rated Air Flow Rate {m3/s}", | ||
" ZoneDehumidWaterRemoval, !- Water Removal Curve Name", | ||
" ZoneDehumidEnergyFactor, !- Energy Factor Curve Name", | ||
" ZoneDehumidPLFFPLR, !- Part Load Fraction Correlation Curve Name", | ||
" 10.0, !- Minimum Dry-Bulb Temperature for Dehumidifier Operation {C}", | ||
" 32.0, !- Maximum Dry-Bulb Temperature for Dehumidifier Operation {C}", | ||
" 0.0; !- Off-Cycle Parasitic Electric Load {W}", |
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.
Add a dehumidifier to this test to create the same situation as the defect file (multiple exhaust nodes). The defect file uses a VRF terminal.
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.
Nice job just modifying an existing test here.
|
||
// Check that the validation fails if the AFN exhaust fan is not well setup | ||
int exhaustFanInletNodeIndex = state->afn->MultizoneCompExhaustFanData(1).InletNode; | ||
state->afn->MultizoneCompExhaustFanData(1).InletNode = 6; | ||
state->afn->ValidateExhaustFanInputOneTimeFlag = true; | ||
EXPECT_THROW(state->afn->validate_exhaust_fan_input(), std::runtime_error); |
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.
Mess with the exhaust fan node to make sure that the if statement that was moved still creates a fatal error.
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.
I'm happy with this, any objections?
} | ||
if (!found) { | ||
ShowSevereError(m_state, format("{}Fan:ZoneExhaust is not defined in {}", RoutineName, CurrentModuleObject)); | ||
ShowContinueError( | ||
m_state, | ||
format("The inlet node of the {} Fan:ZoneExhaust is not defined in the {}'s ZoneHVAC:EquipmentConnections", | ||
m_state.dataZoneEquip->ZoneEquipList(j).EquipName, | ||
m_state.dataZoneEquip->ZoneEquipConfig(j).ZoneName)); | ||
ErrorsFound = true; |
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.
👍 reasonable!
" ZoneHVAC:Dehumidifier:DX,", | ||
" North Zone Dehumidifier, !- Name", | ||
" always_avail, !- Availability Schedule Name", | ||
" Zone3DehumidifierInlet, !- Air Inlet Node Name", | ||
" Dehumidifier Outlet Node,!- Air Outlet Node Name", | ||
" 50.16, !- Rated Water Removal {L/day}", | ||
" 3.412, !- Rated Energy Factor {L/kWh}", | ||
" 0.12036, !- Rated Air Flow Rate {m3/s}", | ||
" ZoneDehumidWaterRemoval, !- Water Removal Curve Name", | ||
" ZoneDehumidEnergyFactor, !- Energy Factor Curve Name", | ||
" ZoneDehumidPLFFPLR, !- Part Load Fraction Correlation Curve Name", | ||
" 10.0, !- Minimum Dry-Bulb Temperature for Dehumidifier Operation {C}", | ||
" 32.0, !- Maximum Dry-Bulb Temperature for Dehumidifier Operation {C}", | ||
" 0.0; !- Off-Cycle Parasitic Electric Load {W}", |
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.
Nice job just modifying an existing test here.
No objections, and it's still clean when I pull in develop and test. Thanks @lymereJ, merging. |
Pull request overview
Fan:ZoneExhaust
node validation issue with Airflow Network #10660Pull Request Author
Add to this list or remove from it as applicable. This is a simple templated set of guidelines.
Reviewer
This will not be exhaustively relevant to every PR.