Skip to content

Commit

Permalink
verified tower fan speed control sequences [ci skip]
Browse files Browse the repository at this point in the history
  • Loading branch information
JayHuLBL committed Jan 19, 2024
1 parent 093128d commit 723f11f
Show file tree
Hide file tree
Showing 32 changed files with 844 additions and 482 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,7 @@ block Controller "Tower fan speed control"
chiWatCon == Buildings.Controls.OBC.CDL.Types.SimpleController.PID)));
parameter Real LIFT_min[nChi](
final unit=fill("K",nChi),
final quantity=fill("TemperatureDifference",nChi),
displayUnit=fill("degC",nChi))={12,12} "Minimum LIFT of each chiller"
final quantity=fill("TemperatureDifference",nChi))={12,12} "Minimum LIFT of each chiller"
annotation (Dialog(tab="Return temperature control", group="Setpoint"));
parameter Real TConWatSup_nominal[nChi](
final unit=fill("K",nChi),
Expand Down Expand Up @@ -173,7 +172,7 @@ block Controller "Tower fan speed control"
displayUnit="degC",
final quantity="ThermodynamicTemperature")
"Chilled water supply temperature setpoint"
annotation (Placement(transformation(extent={{-140,20},{-100,60}}),
annotation (Placement(transformation(extent={{-140,10},{-100,50}}),
iconTransformation(extent={{-140,20},{-100,60}})));
Buildings.Controls.OBC.CDL.Interfaces.RealInput reqPlaCap(
final unit="W",
Expand All @@ -185,7 +184,7 @@ block Controller "Tower fan speed control"
final max=fill(1, nChi),
final unit=fill("1", nChi))
"Maximum cooling tower speed setpoint from each chiller head pressure control loop"
annotation (Placement(transformation(extent={{-140,-40},{-100,0}}),
annotation (Placement(transformation(extent={{-140,-50},{-100,-10}}),
iconTransformation(extent={{-140,-40},{-100,0}})));
Buildings.Controls.OBC.CDL.Interfaces.BooleanInput uTow[nTowCel]
"Cooling tower cell operating status: true=running tower cell"
Expand Down Expand Up @@ -219,7 +218,7 @@ block Controller "Tower fan speed control"
final min=0,
final max=1,
final unit="1") "Fan speed setpoint of each cooling tower cell"
annotation (Placement(transformation(extent={{100,-20},{140,20}}),
annotation (Placement(transformation(extent={{100,-60},{140,-20}}),
iconTransformation(extent={{100,-20},{140,20}})));

Buildings.Controls.OBC.ASHRAE.PrimarySystem.ChillerPlant.Towers.FanSpeed.ReturnWaterTemperature.Controller
Expand Down Expand Up @@ -291,7 +290,7 @@ equation
annotation (Line(points={{-42,44},{-76,44},{-76,60},{-120,60}},
color={0,0,127}));
connect(fanSpeWse.TChiWatSupSet, TChiWatSupSet)
annotation (Line(points={{-42,41},{-82,41},{-82,40},{-120,40}},
annotation (Line(points={{-42,41},{-60,41},{-60,30},{-120,30}},
color={0,0,127}));
connect(uChi, fanSpeRetTem.uChi)
annotation (Line(points={{-120,120},{-64,120},{-64,-25},{18,-25}},
Expand All @@ -302,15 +301,15 @@ equation
annotation (Line(points={{18,-31},{-76,-31},{-76,0},{-120,0}},
color={0,0,127}));
connect(fanSpeRetTem.uMaxTowSpeSet, uMaxTowSpeSet)
annotation (Line(points={{18,-34},{-80,-34},{-80,-20},{-120,-20}},
annotation (Line(points={{18,-34},{-80,-34},{-80,-30},{-120,-30}},
color={0,0,127}));
connect(uFanSpe,fanSpeRetTem.uFanSpe)
annotation (Line(points={{-120,80},{-72,80},{-72,-37},{18,-37}},
color={0,0,127}));
connect(fanSpeRetTem.uTow, uTow) annotation (Line(points={{18,-40},{-68,-40},{
-68,-60},{-120,-60}}, color={255,0,255}));
connect(TChiWatSupSet, fanSpeRetTem.TChiWatSupSet)
annotation (Line(points={{-120,40},{-60,40},{-60,-46},{18,-46}},
annotation (Line(points={{-120,30},{-60,30},{-60,-46},{18,-46}},
color={0,0,127}));
connect(fanSpeRetTem.uPla, uPla)
annotation (Line(points={{18,-49},{-60,-49},{-60,-100},{-120,-100}},
Expand All @@ -325,7 +324,7 @@ equation
annotation (Line(points={{18,-58},{-48,-58},{-48,-160},{-120,-160}},
color={0,0,127}));
connect(fanSpeRetTem.ySpeSet,ySpeSet)
annotation (Line(points={{62,-40},{80,-40},{80,0},{120,0}},
annotation (Line(points={{62,-40},{120,-40}},
color={0,0,127}));

annotation (
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,15 @@ block Coupled
annotation (Dialog(group="Controller"));
parameter Real k=1 "Gain of controller"
annotation (Dialog(group="Controller"));
parameter Real Ti(final quantity="Time", final unit="s")=0.5 "Time constant of integrator block"
parameter Real Ti(
final quantity="Time",
final unit="s")=0.5
"Time constant of integrator block"
annotation (Dialog(group="Controller"));
parameter Real Td(final quantity="Time", final unit="s")=0.1 "Time constant of derivative block"
parameter Real Td(
final quantity="Time",
final unit="s")=0.1
"Time constant of derivative block"
annotation (Dialog(group="Controller", enable=
controllerType == Buildings.Controls.OBC.CDL.Types.SimpleController.PD or
controllerType == Buildings.Controls.OBC.CDL.Types.SimpleController.PID));
Expand All @@ -35,37 +41,37 @@ block Coupled
displayUnit="degC",
final quantity="ThermodynamicTemperature")
"Condenser water return temperature (condenser leaving)"
annotation (Placement(transformation(extent={{-160,30},{-120,70}}),
annotation (Placement(transformation(extent={{-160,20},{-120,60}}),
iconTransformation(extent={{-140,40},{-100,80}})));
Buildings.Controls.OBC.CDL.Interfaces.RealInput uConWatPumSpe[nConWatPum](
final min=fill(0, nConWatPum),
final max=fill(1, nConWatPum),
final unit=fill("1", nConWatPum)) "Current condenser water pump speed"
annotation (Placement(transformation(extent={{-160,0},{-120,40}}),
annotation (Placement(transformation(extent={{-160,-20},{-120,20}}),
iconTransformation(extent={{-140,0},{-100,40}})));
Buildings.Controls.OBC.CDL.Interfaces.RealInput uMaxTowSpeSet[nChi](
final min=fill(0, nChi),
final max=fill(1, nChi),
final unit=fill("1", nChi))
"Maximum cooling tower speed setpoint from each chiller head pressure control loop"
annotation (Placement(transformation(extent={{-160,-40},{-120,0}}),
annotation (Placement(transformation(extent={{-160,-60},{-120,-20}}),
iconTransformation(extent={{-140,-40},{-100,0}})));
Buildings.Controls.OBC.CDL.Interfaces.BooleanInput uChi[nChi]
"Chiller enabling status: true=ON"
annotation (Placement(transformation(extent={{-160,-80},{-120,-40}}),
annotation (Placement(transformation(extent={{-160,-100},{-120,-60}}),
iconTransformation(extent={{-140,-80},{-100,-40}})));
Buildings.Controls.OBC.CDL.Interfaces.RealInput plrTowMaxSpe(
final min=0,
final max=1,
final unit="1")
"Tower maximum speed that reset based on plant partial load ratio"
annotation (Placement(transformation(extent={{-160,-120},{-120,-80}}),
annotation (Placement(transformation(extent={{-160,-150},{-120,-110}}),
iconTransformation(extent={{-140,-120},{-100,-80}})));
Buildings.Controls.OBC.CDL.Interfaces.RealOutput ySpeSet(
final min=0,
final max=1,
final unit="1") "Fan speed setpoint of each cooling tower cell"
annotation (Placement(transformation(extent={{120,-60},{160,-20}}),
annotation (Placement(transformation(extent={{120,-20},{160,20}}),
iconTransformation(extent={{100,-20},{140,20}})));

Buildings.Controls.OBC.CDL.Reals.PIDWithReset conPID(
Expand All @@ -76,16 +82,17 @@ block Coupled
final yMax=yMax,
final yMin=yMin,
final reverseActing=false,
final y_reset=yMin) "Condenser water return temperature controller"
final y_reset=yMin)
"Condenser water return temperature controller"
annotation (Placement(transformation(extent={{-80,70},{-60,90}})));
Buildings.Controls.OBC.CDL.Reals.Line CWRTSpd
"Fan speed calculated based on return water temperature control loop"
annotation (Placement(transformation(extent={{80,70},{100,90}})));

protected
Buildings.Controls.OBC.CDL.Reals.Sources.Constant minTowSpe(
final k=fanSpeMin) "Minimum tower speed"
annotation (Placement(transformation(extent={{-80,110},{-60,130}})));
Buildings.Controls.OBC.CDL.Reals.Line CWRTSpd
"Fan speed calculated based on return water temperature control loop"
annotation (Placement(transformation(extent={{80,70},{100,90}})));
Buildings.Controls.OBC.CDL.Reals.Sources.Constant zer(
final k=yMin) "Zero constant"
annotation (Placement(transformation(extent={{0,110},{20,130}})));
Expand All @@ -96,28 +103,29 @@ protected
final uLow=fill(pumSpeChe, nConWatPum),
final uHigh=fill(2*pumSpeChe, nConWatPum))
"Check if the condenser water pump is proven on"
annotation (Placement(transformation(extent={{-100,10},{-80,30}})));
annotation (Placement(transformation(extent={{-100,-10},{-80,10}})));
Buildings.Controls.OBC.CDL.Logical.MultiOr anyProOn(
final nin=nConWatPum)
"Check if there is any condenser water pump is proven on"
annotation (Placement(transformation(extent={{-60,10},{-40,30}})));
annotation (Placement(transformation(extent={{-60,-10},{-40,10}})));
Buildings.Controls.OBC.CDL.Reals.MultiMin fanSpe(final nin=3)
"Cooling tower fan speed"
annotation (Placement(transformation(extent={{20,-70},{40,-50}})));
Buildings.Controls.OBC.CDL.Reals.MultiMin maxSpe(final nin=nChi)
annotation (Placement(transformation(extent={{20,-90},{40,-70}})));
Buildings.Controls.OBC.CDL.Reals.MultiMin maxSpe(
final nin=nChi)
"Lowest value of the maximum cooling tower speed from each chiller head pressure control loop"
annotation (Placement(transformation(extent={{-20,-70},{0,-50}})));
annotation (Placement(transformation(extent={{-20,-90},{0,-70}})));
Buildings.Controls.OBC.CDL.Reals.Switch swi "Logical switch"
annotation (Placement(transformation(extent={{80,-50},{100,-30}})));
annotation (Placement(transformation(extent={{80,-10},{100,10}})));
Buildings.Controls.OBC.CDL.Reals.Switch swi1[nChi] "Logical switch"
annotation (Placement(transformation(extent={{-60,-70},{-40,-50}})));
annotation (Placement(transformation(extent={{-60,-90},{-40,-70}})));
Buildings.Controls.OBC.CDL.Reals.Sources.Constant one1[nChi](
final k=fill(1, nChi)) "Constant one"
annotation (Placement(transformation(extent={{-100,-90},{-80,-70}})));
annotation (Placement(transformation(extent={{-100,-120},{-80,-100}})));

equation
connect(TConWatRet, conPID.u_m)
annotation (Line(points={{-140,50},{-70,50},{-70,68}}, color={0,0,127}));
annotation (Line(points={{-140,40},{-70,40},{-70,68}}, color={0,0,127}));
connect(TConWatRetSet, conPID.u_s)
annotation (Line(points={{-140,80},{-82,80}}, color={0,0,127}));
connect(conPID.y, CWRTSpd.u)
Expand All @@ -127,46 +135,44 @@ equation
connect(minTowSpe.y, CWRTSpd.f1)
annotation (Line(points={{-58,120},{-20,120},{-20,84},{78,84}}, color={0,0,127}));
connect(one.y, CWRTSpd.x2)
annotation (Line(points={{22,60},{40,60},{40,76},{78,76}},
color={0,0,127}));
annotation (Line(points={{22,60},{40,60},{40,76},{78,76}}, color={0,0,127}));
connect(one.y, CWRTSpd.f2)
annotation (Line(points={{22,60},{40,60},{40,72},{78,72}},
color={0,0,127}));
annotation (Line(points={{22,60},{40,60},{40,72},{78,72}}, color={0,0,127}));
connect(uConWatPumSpe, proOn.u)
annotation (Line(points={{-140,20},{-102,20}}, color={0,0,127}));
annotation (Line(points={{-140,0},{-102,0}}, color={0,0,127}));
connect(proOn.y, anyProOn.u)
annotation (Line(points={{-78,20},{-62,20}}, color={255,0,255}));
annotation (Line(points={{-78,0},{-62,0}}, color={255,0,255}));
connect(anyProOn.y, conPID.trigger)
annotation (Line(points={{-38,20},{0,20},{0,40},{-76,40},{-76,68}},
annotation (Line(points={{-38,0},{0,0},{0,30},{-76,30},{-76,68}},
color={255,0,255}));
connect(uChi, swi1.u2)
annotation (Line(points={{-140,-60},{-62,-60}}, color={255,0,255}));
annotation (Line(points={{-140,-80},{-62,-80}}, color={255,0,255}));
connect(one1.y, swi1.u3)
annotation (Line(points={{-78,-80},{-70,-80},{-70,-68},{-62,-68}},
annotation (Line(points={{-78,-110},{-70,-110},{-70,-88},{-62,-88}},
color={0,0,127}));
connect(uMaxTowSpeSet, swi1.u1)
annotation (Line(points={{-140,-20},{-80,-20},{-80,-52},{-62,-52}},
annotation (Line(points={{-140,-40},{-80,-40},{-80,-72},{-62,-72}},
color={0,0,127}));
connect(swi1.y, maxSpe.u)
annotation (Line(points={{-38,-60},{-30,-60},{-30,-60},{-22,-60}},
color={0,0,127}));
annotation (Line(points={{-38,-80},{-22,-80}}, color={0,0,127}));
connect(CWRTSpd.y, fanSpe.u[1])
annotation (Line(points={{102,80},{110,80},{110,40},{10,40},{10,-60.6667},{
18,-60.6667}},color={0,0,127}));
annotation (Line(points={{102,80},{110,80},{110,30},{10,30},{10,-80.6667},{
18,-80.6667}},
color={0,0,127}));
connect(maxSpe.y, fanSpe.u[2])
annotation (Line(points={{2,-60},{18,-60}}, color={0,0,127}));
annotation (Line(points={{2,-80},{18,-80}}, color={0,0,127}));
connect(plrTowMaxSpe, fanSpe.u[3])
annotation (Line(points={{-140,-100},{10,-100},{10,-59.3333},{18,-59.3333}},
annotation (Line(points={{-140,-130},{10,-130},{10,-79.3333},{18,-79.3333}},
color={0,0,127}));
connect(anyProOn.y, swi.u2)
annotation (Line(points={{-38,20},{0,20},{0,-40},{78,-40}}, color={255,0,255}));
annotation (Line(points={{-38,0},{78,0}}, color={255,0,255}));
connect(zer.y, swi.u3)
annotation (Line(points={{22,120},{60,120},{60,-48},{78,-48}},
annotation (Line(points={{22,120},{60,120},{60,-8},{78,-8}},
color={0,0,127}));
connect(fanSpe.y, swi.u1)
annotation (Line(points={{42,-60},{50,-60},{50,-32},{78,-32}}, color={0,0,127}));
annotation (Line(points={{42,-80},{50,-80},{50,8},{78,8}}, color={0,0,127}));
connect(swi.y,ySpeSet)
annotation (Line(points={{102,-40},{140,-40}}, color={0,0,127}));
annotation (Line(points={{102,0},{140,0}}, color={0,0,127}));

annotation (
defaultComponentName="couTowSpe",
Expand Down
Loading

0 comments on commit 723f11f

Please sign in to comment.