-
Notifications
You must be signed in to change notification settings - Fork 460
Add Space Component Loads Report and Fix Zone Component Loads when Enclosures Differ from Zones #10730
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
Conversation
|
|
|
| auto &spCLDayTS = state.dataOutRptTab->spCompLoads[iSpace - 1].day[state.dataSize->CurOverallSimDay - 1].ts[TimeStepInDay - 1]; | ||
| gatherCompLoadIntGain2(state, spCLDayTS, state.dataHeatBal->space(iSpace).zoneNum, iSpace); | ||
| } | ||
| } |
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 recall something about if space heat balance is active, then the zone HB results are overwritten with the sum of the spaces. If that's true then why bother processing the zones at all (line 9511) if those results are overwritten by 9516? Is line 9516 iSpace = 1 to NumOfZones, or 1 to numSpaces?
If (state.dataHeatBal->doSpaceHeatBalanceSizing) {
gather spaces, 9516 to 9519
} else {
gather zones, 9511 to 9514
}
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.
That's possible. Baby steps at this point. Just trying to find all of the places that apply so that the space results are really just for the space.
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.
@mjwitte you never answered "Is line 9516 iSpace = 1 to NumOfZones, or 1 to numSpaces?" and I still see that in develop.
I see it as line 8986 now. Should be 1 to NumOfSpaces?
if (state.dataHeatBal->doSpaceHeatBalanceSizing) {
for (int iSpace = 1; iSpace <= state.dataGlobal->NumOfZones; ++iSpace) {
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.
for (int iSpace = 1; iSpace <= state.dataGlobal->NumOfZones;
@rraustad Yikes! This pasteo is in the code three times . . .

I'll open branch to fix this. Thanks for remembering this.
|
mjwitte
left a comment
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.
Space component loads walkthru . . .
| for (int zoneNum = 1; zoneNum <= state.dataGlobal->NumOfZones; ++zoneNum) { // Start of zone loads report variable update loop ... | ||
| auto &zone = state.dataHeatBal->Zone(zoneNum); | ||
| auto &znAirRpt = state.dataHeatBal->ZnAirRpt(zoneNum); | ||
| auto &znEquipConfig = state.dataZoneEquip->ZoneEquipConfig(zoneNum); | ||
| reportAirHeatBal1(state, znAirRpt, znEquipConfig, zoneNum); | ||
| } | ||
| if (state.dataHeatBal->doSpaceHeatBalance) { | ||
| for (int spaceNum = 1; spaceNum <= state.dataGlobal->numSpaces; ++spaceNum) { | ||
| auto &spAirRpt = state.dataHeatBal->spaceAirRpt(spaceNum); | ||
| auto &spEquipConfig = state.dataZoneEquip->spaceEquipConfig(spaceNum); | ||
| int zoneNum = state.dataHeatBal->space(spaceNum).zoneNum; | ||
| reportAirHeatBal1(state, spAirRpt, spEquipConfig, zoneNum, spaceNum); |
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.
Break up ReportAirHeatBalance into smaller functions that can be re-used for zones and spaces.
| Array1D<Real64> MixSenLoad; // Mixing sensible loss or gain | ||
| Array1D<Real64> MixLatLoad; // Mixing latent loss or gain |
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 to DataHeatBalance::AirReportVars.
| // Following used for reporting | ||
| state.dataHeatBal->ZnAirRpt.allocate(state.dataGlobal->NumOfZones); | ||
| if (state.dataHeatBal->doSpaceHeatBalanceSimulation) { | ||
| if (state.dataHeatBal->doSpaceHeatBalance) { |
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.
Hmm, this is wrong, should be doSpaceHeatBalanceSimulation || doSpaceHeatBalanceSizing. It might be ok, but not safe if sizing is false and simulation is true. Will fix.
| for (int iZoneGCLH = 1; iZoneGCLH <= state.dataGlobal->NumOfZones; ++iZoneGCLH) { | ||
| auto &znCompLoadDayTSZone = znCompLoadDayTS.spacezone[iZoneGCLH - 1]; | ||
| auto &zoneAirRpt = state.dataHeatBal->ZnAirRpt(iZoneGCLH); | ||
| gatherSpaceZoneCompLoadsHVAC(znCompLoadDayTSZone, zoneAirRpt, state.dataHVACGlobal->TimeStepSysSec); |
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.
Another breakup into smaller functions.
| int zoneNum = state.dataHeatBal->space(iSpace).zoneNum; | ||
| if (!state.dataZoneEquip->ZoneEquipConfig(zoneNum).IsControlled) continue; | ||
| if (allocated(state.dataSize->CalcFinalSpaceSizing)) { | ||
| computeSpaceZoneCompLoads(state, |
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.
This pattern repeats several times, called for either space of zone.
|
|
|
|
@Myoldmopar @mjwitte it has been 16 days since this pull request was last updated. |
|
@Myoldmopar @mjwitte it has been 7 days since this pull request was last updated. |
1 similar comment
|
@Myoldmopar @mjwitte it has been 7 days since this pull request was last updated. |
|
|
Pulled in develop to get the license year fixed. Everything is passing locally so I expect this to be back to what it was before with just a few table diffs. If so, I think this is probably ready to go in. Any final thoughts from @mjwitte or anyone else? |
|
Nothing more from me. |
|
|
|
|
|
Fully happy still with latest develop, merging. Thanks @mjwitte ! |
Pull request overview
Array3Dwith nested vectors of structs inOutputReportsTabular.Pull 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.