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

Plant Component Setpoint Operation Scheme #1654

Open
kbenne opened this issue May 15, 2015 · 7 comments
Open

Plant Component Setpoint Operation Scheme #1654

kbenne opened this issue May 15, 2015 · 7 comments

Comments

@kbenne
Copy link
Contributor

kbenne commented May 15, 2015

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.

screen shot 2015-05-15 at 8 50 23 am

This is the workaround.

screen shot 2015-05-15 at 8 48 03 am

@jmarrec
Copy link
Collaborator

jmarrec commented Jun 8, 2021

here's where it happens, inside _isSetpointComponent there's a check on line 145

bool _isSetpointComponent(const PlantLoop& plantLoop, const ModelObject& comp) {
auto supplyOutletNode = plantLoop.supplyOutletNode();
auto hvacComp = comp.optionalCast<HVACComponent>();
OS_ASSERT(hvacComp);
auto nodes = subsetCastVector<Node>(plantLoop.supplyComponents(hvacComp.get(), supplyOutletNode));
OS_ASSERT(!nodes.empty());
auto componentOutletNode = nodes.front();
if (componentOutletNode != supplyOutletNode) {
auto _setpointManagers = componentOutletNode.setpointManagers();
if (!_setpointManagers.empty()) {
return true;
}
}
return false;
}

@jmarrec
Copy link
Collaborator

jmarrec commented Jun 8, 2021

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?

@jmarrec jmarrec self-assigned this Jun 8, 2021
@jmarrec
Copy link
Collaborator

jmarrec commented Jun 8, 2021

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

@kbenne
Copy link
Contributor Author

kbenne commented Jun 8, 2021

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.

@jmarrec
Copy link
Collaborator

jmarrec commented Jun 9, 2021

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:

  • If I do not use a SPM:Scheduled (or else) on its outlet node, I think it's appropriate to add it to a PlantEquipmentOperation:HeatingLoad
  • If I do use a SPM:Scheduled on its outlet node, which one do I want defaulted? HeatingLoad or ComponentSetpoint?

@jmarrec
Copy link
Collaborator

jmarrec commented Jul 29, 2021

ping @kbenne

@jmarrec
Copy link
Collaborator

jmarrec commented Jan 6, 2022

@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 ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants