@@ -126,11 +126,7 @@ void BLASTAbsorberSpecs::simulate(
126126 EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag)
127127{
128128
129- this ->EquipFlowCtrl = state.dataPlnt ->PlantLoop (calledFromLocation.loopNum )
130- .LoopSide (calledFromLocation.loopSideNum )
131- .Branch (calledFromLocation.branchNum )
132- .Comp (calledFromLocation.compNum )
133- .FlowCtrl ;
129+ this ->EquipFlowCtrl = calledFromLocation.comp ->FlowCtrl ;
134130
135131 if (calledFromLocation.loopNum == this ->CWPlantLoc .loopNum ) {
136132 // called from dominant chilled water connection loop side
@@ -757,9 +753,9 @@ void BLASTAbsorberSpecs::oneTimeInit(EnergyPlusData &state)
757753
758754 this ->ModulatedFlowSetToLoop = true ;
759755 state.dataLoopNodes ->Node (this ->EvapOutletNodeNum ).TempSetPoint =
760- state.dataLoopNodes ->Node (state. dataPlnt -> PlantLoop ( this ->CWPlantLoc .loopNum ). TempSetPointNodeNum ).TempSetPoint ;
756+ state.dataLoopNodes ->Node (this ->CWPlantLoc .loop -> TempSetPointNodeNum ).TempSetPoint ;
761757 state.dataLoopNodes ->Node (this ->EvapOutletNodeNum ).TempSetPointHi =
762- state.dataLoopNodes ->Node (state. dataPlnt -> PlantLoop ( this ->CWPlantLoc .loopNum ). TempSetPointNodeNum ).TempSetPointHi ;
758+ state.dataLoopNodes ->Node (this ->CWPlantLoc .loop -> TempSetPointNodeNum ).TempSetPointHi ;
763759 }
764760 }
765761}
@@ -844,9 +840,9 @@ void BLASTAbsorberSpecs::initialize(EnergyPlusData &state,
844840 // fix for clumsy old input that worked because loop setpoint was spread.
845841 // could be removed with transition, testing , model change, period of being obsolete.
846842 state.dataLoopNodes ->Node (this ->EvapOutletNodeNum ).TempSetPoint =
847- state.dataLoopNodes ->Node (state. dataPlnt -> PlantLoop ( this ->CWPlantLoc .loopNum ). TempSetPointNodeNum ).TempSetPoint ;
843+ state.dataLoopNodes ->Node (this ->CWPlantLoc .loop -> TempSetPointNodeNum ).TempSetPoint ;
848844 state.dataLoopNodes ->Node (this ->EvapOutletNodeNum ).TempSetPointHi =
849- state.dataLoopNodes ->Node (state. dataPlnt -> PlantLoop ( this ->CWPlantLoc .loopNum ). TempSetPointNodeNum ).TempSetPointHi ;
845+ state.dataLoopNodes ->Node (this ->CWPlantLoc .loop -> TempSetPointNodeNum ).TempSetPointHi ;
850846 }
851847
852848 Real64 mdotEvap = 0.0 ; // local fluid mass flow rate thru evaporator
@@ -913,8 +909,8 @@ void BLASTAbsorberSpecs::sizeChiller(EnergyPlusData &state)
913909 Real64 tmpGeneratorVolFlowRate = this ->GeneratorVolFlowRate ;
914910
915911 // find the appropriate Plant Sizing object
916- int PltSizNum = state. dataPlnt -> PlantLoop ( this ->CWPlantLoc .loopNum ). PlantSizNum ;
917- int PltSizCondNum = state. dataPlnt -> PlantLoop ( this ->CDPlantLoc .loopNum ). PlantSizNum ;
912+ int PltSizNum = this ->CWPlantLoc .loop -> PlantSizNum ;
913+ int PltSizCondNum = this ->CDPlantLoc .loop -> PlantSizNum ;
918914
919915 if (this ->GenHeatSourceType == DataLoopNode::NodeFluidType::Steam) {
920916 if (this ->GeneratorInletNodeNum > 0 && this ->GeneratorOutletNodeNum > 0 ) {
@@ -1385,25 +1381,19 @@ void BLASTAbsorberSpecs::sizeChiller(EnergyPlusData &state)
13851381 OutputReportPredefined::PreDefTableEntry (state,
13861382 state.dataOutRptPredefined ->pdchChillerPlantloopName ,
13871383 this ->Name ,
1388- this ->CWPlantLoc .loopNum > 0 ? state.dataPlnt ->PlantLoop (this ->CWPlantLoc .loopNum ).Name : " N/A" );
1389- OutputReportPredefined::PreDefTableEntry (
1390- state,
1391- state.dataOutRptPredefined ->pdchChillerPlantloopBranchName ,
1392- this ->Name ,
1393- this ->CWPlantLoc .loopNum > 0
1394- ? state.dataPlnt ->PlantLoop (this ->CWPlantLoc .loopNum ).LoopSide (this ->CWPlantLoc .loopSideNum ).Branch (this ->CWPlantLoc .branchNum ).Name
1395- : " N/A" );
1384+ this ->CWPlantLoc .loop != nullptr ? this ->CWPlantLoc .loop ->Name : " N/A" );
1385+ OutputReportPredefined::PreDefTableEntry (state,
1386+ state.dataOutRptPredefined ->pdchChillerPlantloopBranchName ,
1387+ this ->Name ,
1388+ this ->CWPlantLoc .loop != nullptr ? this ->CWPlantLoc .branch ->Name : " N/A" );
13961389 OutputReportPredefined::PreDefTableEntry (state,
13971390 state.dataOutRptPredefined ->pdchChillerCondLoopName ,
13981391 this ->Name ,
1399- this ->CDPlantLoc .loopNum > 0 ? state.dataPlnt ->PlantLoop (this ->CDPlantLoc .loopNum ).Name : " N/A" );
1400- OutputReportPredefined::PreDefTableEntry (
1401- state,
1402- state.dataOutRptPredefined ->pdchChillerCondLoopBranchName ,
1403- this ->Name ,
1404- this ->CDPlantLoc .loopNum > 0
1405- ? state.dataPlnt ->PlantLoop (this ->CDPlantLoc .loopNum ).LoopSide (this ->CDPlantLoc .loopSideNum ).Branch (this ->CDPlantLoc .branchNum ).Name
1406- : " N/A" );
1392+ this ->CDPlantLoc .loop != nullptr ? this ->CDPlantLoc .loop ->Name : " N/A" );
1393+ OutputReportPredefined::PreDefTableEntry (state,
1394+ state.dataOutRptPredefined ->pdchChillerCondLoopBranchName ,
1395+ this ->Name ,
1396+ this ->CDPlantLoc .loop != nullptr ? this ->CDPlantLoc .branch ->Name : " N/A" );
14071397 OutputReportPredefined::PreDefTableEntry (state, state.dataOutRptPredefined ->pdchChillerMinPLR , this ->Name , this ->MinPartLoadRat );
14081398 OutputReportPredefined::PreDefTableEntry (state,
14091399 state.dataOutRptPredefined ->pdchChillerFuelType ,
@@ -1483,7 +1473,7 @@ void BLASTAbsorberSpecs::calculate(EnergyPlusData &state, Real64 &MyLoad, bool R
14831473
14841474 // If FlowLock is True, the new resolved mdot is used to update Power, QEvap, Qcond, and
14851475 // condenser side outlet temperature.
1486- if (state. dataPlnt -> PlantLoop ( this ->CWPlantLoc .loopNum ). LoopSide ( this -> CWPlantLoc . loopSideNum ). FlowLock == DataPlant::FlowLock::Unlocked) {
1476+ if (this ->CWPlantLoc .side -> FlowLock == DataPlant::FlowLock::Unlocked) {
14871477 this ->PossibleSubcooling = false ;
14881478 this ->QEvaporator = std::abs (MyLoad);
14891479 // limit by max capacity
@@ -1502,7 +1492,7 @@ void BLASTAbsorberSpecs::calculate(EnergyPlusData &state, Real64 &MyLoad, bool R
15021492
15031493 } else if (this ->FlowMode == DataPlant::FlowMode::LeavingSetpointModulated) {
15041494 // Calculate the Delta Temp from the inlet temp to the chiller outlet setpoint
1505- switch (state. dataPlnt -> PlantLoop ( this ->CWPlantLoc .loopNum ). LoopDemandCalcScheme ) {
1495+ switch (this ->CWPlantLoc .loop -> LoopDemandCalcScheme ) {
15061496 case DataPlant::LoopDemandCalcScheme::SingleSetPoint: {
15071497 EvapDeltaTemp =
15081498 state.dataLoopNodes ->Node (this ->EvapInletNodeNum ).Temp - state.dataLoopNodes ->Node (this ->EvapOutletNodeNum ).TempSetPoint ;
@@ -1525,7 +1515,7 @@ void BLASTAbsorberSpecs::calculate(EnergyPlusData &state, Real64 &MyLoad, bool R
15251515 this ->EvapMassFlowRate = min (this ->EvapMassFlowRateMax , this ->EvapMassFlowRate );
15261516 PlantUtilities::SetComponentFlowRate (
15271517 state, this ->EvapMassFlowRate , this ->EvapInletNodeNum , this ->EvapOutletNodeNum , this ->CWPlantLoc );
1528- switch (state. dataPlnt -> PlantLoop ( this ->CWPlantLoc .loopNum ). LoopDemandCalcScheme ) {
1518+ switch (this ->CWPlantLoc .loop -> LoopDemandCalcScheme ) {
15291519 case DataPlant::LoopDemandCalcScheme::SingleSetPoint: {
15301520 this ->EvapOutletTemp = state.dataLoopNodes ->Node (this ->EvapOutletNodeNum ).TempSetPoint ;
15311521 } break ;
@@ -1576,15 +1566,14 @@ void BLASTAbsorberSpecs::calculate(EnergyPlusData &state, Real64 &MyLoad, bool R
15761566 this ->EvapOutletTemp = state.dataLoopNodes ->Node (this ->EvapInletNodeNum ).Temp - EvapDeltaTemp;
15771567 } else {
15781568 Real64 TempEvapOutSetPoint{0 }; // C - evaporator outlet temperature setpoint
1579- switch (state. dataPlnt -> PlantLoop ( this ->CWPlantLoc .loopNum ). LoopDemandCalcScheme ) {
1569+ switch (this ->CWPlantLoc .loop -> LoopDemandCalcScheme ) {
15801570 case DataPlant::LoopDemandCalcScheme::SingleSetPoint: {
15811571 if ((this ->FlowMode == DataPlant::FlowMode::LeavingSetpointModulated) ||
15821572 (DataPlant::CompData::getPlantComponent (state, this ->CWPlantLoc ).CurOpSchemeType == DataPlant::OpScheme::CompSetPtBased) ||
15831573 (state.dataLoopNodes ->Node (this ->EvapOutletNodeNum ).TempSetPoint != DataLoopNode::SensedNodeFlagValue)) {
15841574 TempEvapOutSetPoint = state.dataLoopNodes ->Node (this ->EvapOutletNodeNum ).TempSetPoint ;
15851575 } else {
1586- TempEvapOutSetPoint =
1587- state.dataLoopNodes ->Node (state.dataPlnt ->PlantLoop (this ->CWPlantLoc .loopNum ).TempSetPointNodeNum ).TempSetPoint ;
1576+ TempEvapOutSetPoint = state.dataLoopNodes ->Node (this ->CWPlantLoc .loop ->TempSetPointNodeNum ).TempSetPoint ;
15881577 }
15891578 } break ;
15901579 case DataPlant::LoopDemandCalcScheme::DualSetPointDeadBand: {
@@ -1593,8 +1582,7 @@ void BLASTAbsorberSpecs::calculate(EnergyPlusData &state, Real64 &MyLoad, bool R
15931582 (state.dataLoopNodes ->Node (this ->EvapOutletNodeNum ).TempSetPointHi != DataLoopNode::SensedNodeFlagValue)) {
15941583 TempEvapOutSetPoint = state.dataLoopNodes ->Node (this ->EvapOutletNodeNum ).TempSetPointHi ;
15951584 } else {
1596- TempEvapOutSetPoint =
1597- state.dataLoopNodes ->Node (state.dataPlnt ->PlantLoop (this ->CWPlantLoc .loopNum ).TempSetPointNodeNum ).TempSetPointHi ;
1585+ TempEvapOutSetPoint = state.dataLoopNodes ->Node (this ->CWPlantLoc .loop ->TempSetPointNodeNum ).TempSetPointHi ;
15981586 }
15991587 } break ;
16001588 default : {
@@ -1716,8 +1704,7 @@ void BLASTAbsorberSpecs::calculate(EnergyPlusData &state, Real64 &MyLoad, bool R
17161704 // Hot water plant is used for the generator
17171705 CpFluid =
17181706 this ->GenPlantLoc .loop ->glycol ->getSpecificHeat (state, state.dataLoopNodes ->Node (this ->GeneratorInletNodeNum ).Temp , RoutineName);
1719- if (state.dataPlnt ->PlantLoop (this ->GenPlantLoc .loopNum ).LoopSide (this ->GenPlantLoc .loopSideNum ).FlowLock ==
1720- DataPlant::FlowLock::Unlocked) {
1707+ if (this ->GenPlantLoc .side ->FlowLock == DataPlant::FlowLock::Unlocked) {
17211708 if ((this ->FlowMode == DataPlant::FlowMode::Constant) || (this ->FlowMode == DataPlant::FlowMode::NotModulated)) {
17221709 GenMassFlowRate = this ->GenMassFlowRateMax ;
17231710 } else { // LeavingSetpointModulated
0 commit comments