Open kbenne opened 9 years ago
here's where it happens, inside _isSetpointComponent
there's a check on line 145
It begs the question of whether you actually need TWO plant eq operation schemes for the same object... In your above example, if I put only one parallel branch (WH1) and one after the spliiter (WH2), you will end up with the waterheaters being referenced by both a HeatingLoad and a ComponentSetpoint one:
PlantEquipmentOperationSchemes,
Plant Loop 1 Operation Schemes, !- Name
PlantEquipmentOperation:HeatingLoad, !- Control Scheme Object Type 1
Plant Loop 1 Heating Operation Scheme, !- Control Scheme Name 1
Always On Discrete, !- Control Scheme Schedule Name 1
PlantEquipmentOperation:ComponentSetpoint, !- Control Scheme Object Type 2
Plant Loop 1 Setpoint Operation Scheme, !- Control Scheme Name 2
Always On Discrete; !- Control Scheme Schedule Name 2
PlantEquipmentOperation:HeatingLoad,
Plant Loop 1 Heating Operation Scheme, !- Name
0, !- Load Range Lower Limit 1 {W}
1000000000, !- Load Range Upper Limit 1 {W}
Plant Loop 1 Heating Equipment List; !- Range Equipment List Name 1
PlantEquipmentList,
Plant Loop 1 Heating Equipment List, !- Name
WaterHeater:Mixed, !- Equipment Object Type 1
Water Heater Mixed 1, !- Equipment Name 1
WaterHeater:Mixed, !- Equipment Object Type 2
Water Heater Mixed 2; !- Equipment Name 2
PlantEquipmentOperation:ComponentSetpoint,
Plant Loop 1 Setpoint Operation Scheme, !- Name
WaterHeater:Mixed, !- Equipment Object Type 1
Water Heater Mixed 1, !- Equipment Name 1
Node 3, !- Demand Calculation Node Name 1
Node 7, !- Setpoint Node Name 1
Autosize, !- Component Flow Rate 1 {m3/s}
Heating; !- Operation Type 1
[ Note: apparently "missing" the Water Heater Mixed 2 here ]
I haven't found a single E+ example file where a PlantEquipmentOperation:ComponentSetpoint AND another (like PlantEquipmentOperation:Heating/CoolingLoad) are listed on the PlantEquipmentOperationSchemes
@kbenne thoughts please?
Ruby test code
include OpenStudio::Model
m = Model.new
p = PlantLoop.new(m)
wh1 = WaterHeaterMixed.new(m)
p.addSupplyBranchForComponent(wh1)
pump = PumpVariableSpeed.new(m)
pump.addToNode(p.supplyInletNode)
sch = ScheduleConstant.new(m)
sch.setValue(45.0)
spm_sch = SetpointManagerScheduled.new(m, sch)
spm_sch.addToNode(wh1.supplyOutletModelObject.get.to_Node.get)
wh2 = WaterHeaterMixed.new(m)
wh2.addToNode(p.supplyOutletNode)
spm_sch2 = spm_sch.clone(m).to_SetpointManagerScheduled.get
spm_sch2.addToNode(p.supplyOutletNode)
m.save('1654_model.osm', true)
ft = OpenStudio::EnergyPlus::ForwardTranslator.new
w = ft.translateModel(m)
puts w.getObjectsByType("PlantEquipmentOperationSchemes")
puts w.getObjectsByType("PlantEquipmentOperation:HeatingLoad")
puts w.getObjectsByType("PlantEquipmentOperation:HeatingLoad")[0].getTarget(3).get
puts w.getObjectsByType("PlantEquipmentOperation:ComponentSetpoint")
w.save('1654_model.idf', true)
Output:
PlantEquipmentOperationSchemes,
Plant Loop 1 Operation Schemes, !- Name
PlantEquipmentOperation:HeatingLoad, !- Control Scheme Object Type 1
Plant Loop 1 Heating Operation Scheme, !- Control Scheme Name 1
Always On Discrete, !- Control Scheme Schedule Name 1
PlantEquipmentOperation:ComponentSetpoint, !- Control Scheme Object Type 2
Plant Loop 1 Setpoint Operation Scheme, !- Control Scheme Name 2
Always On Discrete; !- Control Scheme Schedule Name 2
PlantEquipmentOperation:HeatingLoad,
Plant Loop 1 Heating Operation Scheme, !- Name
0, !- Load Range Lower Limit 1 {W}
1000000000, !- Load Range Upper Limit 1 {W}
Plant Loop 1 Heating Equipment List; !- Range Equipment List Name 1
PlantEquipmentList,
Plant Loop 1 Heating Equipment List, !- Name
WaterHeater:Mixed, !- Equipment Object Type 1
Water Heater Mixed 1, !- Equipment Name 1
WaterHeater:Mixed, !- Equipment Object Type 2
Water Heater Mixed 2; !- Equipment Name 2
PlantEquipmentOperation:ComponentSetpoint,
Plant Loop 1 Setpoint Operation Scheme, !- Name
WaterHeater:Mixed, !- Equipment Object Type 1
Water Heater Mixed 1, !- Equipment Name 1
Node 3, !- Demand Calculation Node Name 1
Node 7, !- Setpoint Node Name 1
Autosize, !- Component Flow Rate 1 {m3/s}
Heating; !- Operation Type 1
I agree two component operation schemes for the same component seems silly, but two different operation schemes for two different components is a thing right? I thought the issue I reported was a problem even with one operation scheme per component.
It's a thing to have multiple plant equipment operation schemes yes. But the PlantEquipmentOperationScheme is listing stuff in priority order: https://bigladdersoftware.com/epx/docs/9-5/input-output-reference/group-plant-condenser-control.html#plantequipmentoperationschemes
Here basically since these are both defaulted, the PlantEquipmentOperation:HeatingLoad applies to a range up to 1000000000 W (so basically "INFINITY"), and is listed first. As a result the PlantEquipmentOperation:ComponentSetpoint
is never going to be applied. I don't think there's side effects to having it defined anyway, my question was more what is the actual intended behavior?
If I put a WaterHeaterMixed on a branch between the mixer and splitter:
ping @kbenne
@kbenne I'd like to eventually reach a consensus on this one and either fix or close. Could you carve 15min in the coming weeks to think about it please? Otherwise I'll ping you in 6 months again ;)
The component setpoint operation scheme is not working for components after the supply side mixer, and directly upstream of the supply outlet node. The workaround is to insert a pipe between the setpoint component and the supply outlet node.
This does not work.
This is the workaround.