diff --git a/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/AutoTuner/AMIGO/PID.mo b/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/AutoTuner/AMIGO/PID.mo
index 8918f37119c..621c305ffd9 100644
--- a/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/AutoTuner/AMIGO/PID.mo
+++ b/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/AutoTuner/AMIGO/PID.mo
@@ -48,7 +48,7 @@ protected
annotation (Placement(transformation(extent={{-10,-70},{10,-50}})));
equation
- connect(derTim.Td, Td)
+ connect(derTim.Td, Td)
annotation (Line(points={{12,-60},{120,-60}},
color={0,0,127}));
connect(intTim.Ti, Ti)
diff --git a/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/Relay/BaseClasses/HalfPeriodRatio.mo b/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/Relay/BaseClasses/HalfPeriodRatio.mo
index ad2deaaf0b5..1cd6c315233 100644
--- a/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/Relay/BaseClasses/HalfPeriodRatio.mo
+++ b/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/Relay/BaseClasses/HalfPeriodRatio.mo
@@ -38,12 +38,12 @@ protected
final k=0)
"Minimum value for the horizon length"
annotation (Placement(transformation(extent={{-80,0},{-60,20}})));
- Buildings.Controls.OBC.CDL.Discrete.TriggeredSampler tOnSam(final y_start=
- Buildings.Controls.OBC.CDL.Constants.eps)
+ Buildings.Controls.OBC.CDL.Discrete.TriggeredSampler tOnSam(
+ final y_start=Buildings.Controls.OBC.CDL.Constants.eps)
"Block that samples tOn when the tuning period ends"
annotation (Placement(transformation(extent={{-80,70},{-60,90}})));
- Buildings.Controls.OBC.CDL.Discrete.TriggeredSampler tOffSam(final y_start=
- Buildings.Controls.OBC.CDL.Constants.eps)
+ Buildings.Controls.OBC.CDL.Discrete.TriggeredSampler tOffSam(
+ final y_start=Buildings.Controls.OBC.CDL.Constants.eps)
"Block that samples tOff when the tuning period ends"
annotation (Placement(transformation(extent={{-80,-60},{-60,-80}})));
Buildings.Controls.OBC.CDL.Discrete.TriggeredSampler samAddtOntOff
@@ -175,10 +175,10 @@ lengths of the On period and the Off period, respectively.
An On period is defined as the period when the relay switch output of the relay controller is
true
.
Likewise, an Off period is defined as the period when the relay switch output is false
.
-See details of the relay switch output in
+See details of the relay switch output in
+
Buildings.Controls.OBC.Utilities.PIDWithAutotuning.Relay.Controller.
This block also detects when a PID tuning period should start and end.
Specifically, the tuning period is triggered to begin when either ton
@@ -186,8 +186,8 @@ or toff
becomes positive.
The tuning period is triggered to end when either ton
or toff
changes after the tuning period starts, as illustrated below:
- +
+
tOn
, and the length of the Off period, tOff
, as shown below.
-- +
+
Note that tOn
is sampled when the relay switch output becomes false.
diff --git a/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/Relay/BaseClasses/Validation/HalfPeriodRatio.mo b/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/Relay/BaseClasses/Validation/HalfPeriodRatio.mo
index 14c9885e879..d98898a9c54 100644
--- a/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/Relay/BaseClasses/Validation/HalfPeriodRatio.mo
+++ b/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/Relay/BaseClasses/Validation/HalfPeriodRatio.mo
@@ -76,13 +76,16 @@ Buildings.Controls.OBC.Utilities.PIDWithAutotuning.Relay.BaseClasses.HalfPeriodR
diff --git a/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/Relay/ResponseProcess.mo b/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/Relay/ResponseProcess.mo index efd36089ae9..08e85830e74 100644 --- a/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/Relay/ResponseProcess.mo +++ b/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/Relay/ResponseProcess.mo @@ -6,7 +6,7 @@ block ResponseProcess parameter Real yLow(min=1E-6) = 0.5 "Lower value for the output"; Buildings.Controls.OBC.CDL.Interfaces.BooleanInput on - "Relay switch. True: tuning on perid, False: tuningoff period" + "Relay switch. True: tuning on perid, False: tuning off period" annotation (Placement(transformation(extent={{-140,-80},{-100,-40}}), iconTransformation(extent={{-140,-80},{-100,-40}}))); Buildings.Controls.OBC.CDL.Interfaces.RealInput tim( diff --git a/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/SystemIdentification/FirstOrderTimedelayed/BaseClasses/TimeConstantDelay.mo b/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/SystemIdentification/FirstOrderTimedelayed/BaseClasses/TimeConstantDelay.mo index 2ef0cd3ec72..339a1456aa6 100644 --- a/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/SystemIdentification/FirstOrderTimedelayed/BaseClasses/TimeConstantDelay.mo +++ b/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/SystemIdentification/FirstOrderTimedelayed/BaseClasses/TimeConstantDelay.mo @@ -18,7 +18,7 @@ block TimeConstantDelay "Gain" annotation (Placement(transformation(extent={{-140,-20},{-100,20}}), iconTransformation(extent={{-140,-20},{-100,20}}))); - Buildings.Controls.OBC.CDL.Interfaces.RealInput ratioLT + Buildings.Controls.OBC.CDL.Interfaces.RealInput rat "Ratio between the time constant and the time delay" annotation (Placement(transformation(extent={{-140,-70},{-100,-30}}), iconTransformation(extent={{-140,-80},{-100,-40}}))); @@ -85,7 +85,7 @@ protected equation connect(absk.u, k) annotation (Line(points={{-82,0},{-120,0}}, color={0,0,127})); - connect(ratioLT, exp.u) + connect(rat, exp.u) annotation (Line(points={{-120,-50},{-82,-50}}, color={0,0,127})); connect(relDeaBan.y, div1.u1) annotation (Line(points={{22,40},{28,40},{28,0}, {-4,0},{-4,-14},{-2,-14}}, color={0,0,127})); @@ -116,8 +116,7 @@ equation connect(div3.y, T) annotation (Line(points={{-18,70},{120,70}}, color={0,0,127})); connect(mul2.u2, T) annotation (Line(points={{-2,78},{-10,78},{-10,70},{120, - 70}}, - color={0,0,127})); + 70}}, color={0,0,127})); connect(mul2.u1, exp.u) annotation (Line(points={{-2,90},{-90,90},{-90,-50},{-82, -50}}, color={0,0,127})); connect(mul2.y, L) annotation (Line(points={{22,84},{92,84},{92,-60},{120,-60}}, diff --git a/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/SystemIdentification/FirstOrderTimedelayed/BaseClasses/Validation/TimeConstantDelay.mo b/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/SystemIdentification/FirstOrderTimedelayed/BaseClasses/Validation/TimeConstantDelay.mo index 6cc7db7289d..41fcc681a3f 100644 --- a/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/SystemIdentification/FirstOrderTimedelayed/BaseClasses/Validation/TimeConstantDelay.mo +++ b/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/SystemIdentification/FirstOrderTimedelayed/BaseClasses/Validation/TimeConstantDelay.mo @@ -27,8 +27,8 @@ equation 6},{-12,6}}, color={0,0,127})); connect(k.y, timConDel.k) annotation (Line(points={{-38,0},{-12,0}}, color={0,0,127})); - connect(ratioLT.y, timConDel.ratioLT) annotation (Line(points={{-38,-40},{-20, - -40},{-20,-6},{-12,-6}}, color={0,0,127})); + connect(ratioLT.y, timConDel.rat) annotation (Line(points={{-38,-40},{-20,-40}, + {-20,-6},{-12,-6}}, color={0,0,127})); annotation ( experiment( StopTime=1.0, diff --git a/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/SystemIdentification/FirstOrderTimedelayed/ControlProcessModel.mo b/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/SystemIdentification/FirstOrderTimedelayed/ControlProcessModel.mo index 6dc8a6be0a8..871b949f93d 100644 --- a/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/SystemIdentification/FirstOrderTimedelayed/ControlProcessModel.mo +++ b/Buildings/Controls/OBC/Utilities/PIDWithAutotuning/SystemIdentification/FirstOrderTimedelayed/ControlProcessModel.mo @@ -100,7 +100,8 @@ protected final y_start=1) "Block that samples the time constant when the tuning period ends" annotation (Placement(transformation(extent={{70,10},{90,30}}))); - Buildings.Controls.OBC.CDL.Discrete.TriggeredSampler samtau(final y_start=0.5) + Buildings.Controls.OBC.CDL.Discrete.TriggeredSampler samtau( + final y_start=0.5) "Block that samples the normalized time delay when the tuning period ends" annotation (Placement(transformation(extent={{-70,-70},{-50,-50}}))); Buildings.Controls.OBC.CDL.Continuous.MultiplyByParameter gai( @@ -110,8 +111,7 @@ protected equation connect(gain.u, u) annotation (Line(points={{-86,28},{-88,28},{-88,80},{-120, - 80}}, - color={0,0,127})); + 80}}, color={0,0,127})); connect(gain.tOn, tOn) annotation (Line(points={{-86,20},{-94,20},{-94,40},{ -120,40}}, color={0,0,127})); connect(gain.tOff, tOff) annotation (Line(points={{-86,12},{-94,12},{-94,-20}, @@ -137,19 +137,15 @@ equation color={0,0,127})); connect(samk.trigger, triEnd) annotation (Line(points={{-44,8},{-44,-90},{80, -90},{80,-120}}, color={255,0,255})); - connect(gain.k, samk.u) - annotacolor={0,0,127})); connect(samk.y, k) annotation (Line(points={{-32,20},{-20,20},{-20,70},{120, - 70}}, - color={0,0,127})); + 70}}, color={0,0,127})); connect(timConDel.tOn, samtOn.y) annotation (Line(points={{-2,26},{-28,26},{ -28,60},{-48,60}},color={0,0,127})); connect(samtOn.u, tOn) annotation (Line(points={{-72,60},{-94,60},{-94,40},{-120,40}}, color={0,0,127})); connect(samtOn.trigger, triEnd) annotation (Line(points={{-60,48},{-60,-20},{ - -44,-20},{-44,-90},{80,-90},{80,-120}}, - color={255,0,255})); + -44,-20},{-44,-90},{80,-90},{80,-120}}, color={255,0,255})); connect(gai.y, addPar.u) annotation (Line(points={{-14,-60},{-10,-60}}, color={0,0,127})); connect(tau, samtau.u) @@ -162,9 +158,11 @@ equation -60,-90},{-60,-72}}, color={255,0,255})); connect(addPar.y, div.u2) annotation (Line(points={{14,-60},{20,-60},{20,-40}, {6,-40},{6,-26},{10,-26}}, color={0,0,127})); - connect(div.y, timConDel.ratioLT) annotation (Line(points={{34,-20},{36,-20}, - {36,0},{-12,0},{-12,14},{-2,14}}, color={0,0,127})); - annotation ( + connect(div.y, timConDel.rat) annotation (Line(points={{34,-20},{36,-20},{36, + 0},{-12,0},{-12,14},{-2,14}}, color={0,0,127})); + connect(gain.k, samk.u) + annotation (Line(points={{-62,20},{-56,20}}, color={0,0,127})); +annotation ( defaultComponentName = "conProMod", Icon(coordinateSystem(preserveAspectRatio=false), graphics={ Rectangle( @@ -192,7 +190,7 @@ equation 34}}, color={28,108,200}), Line(points={{-58,36},{82,36}}, color={28,108,200}, pattern=LinePattern.Dash)}), - Diagram(coordinateSystem(preserveAspectRatio=false)), + Diagram(coordinateSystem(preserveAspectRatio=false)), Documentation(revisions="
This block calculates the model parameters of a first-order time delayed model.
-Specifically, it employs
-Buildings.Controls.OBC.Utilities.PIDWithAutotuning.SystemIdentification.FirstOrderTimedelayed.BaseClasses.Gain and
+
+This block calculates the model parameters of a first-order time delayed model.
+Specifically, it employs
+
+Buildings.Controls.OBC.Utilities.PIDWithAutotuning.SystemIdentification.FirstOrderTimedelayed.BaseClasses.Gain
+and
+
Buildings.Controls.OBC.Utilities.PIDWithAutotuning.SystemIdentification.FirstOrderTimedelayed.BaseClasses.TimeConstantDelay
-to identify the gain and the time constant/the time delay, respectively. This block is inactive by default and is active once the tuning period starts, i.e.,
+The calculations are disabled by default. They will be enabled once the tuning period starts,
+i.e.,
Refer to
-Buildings.Controls.OBC.Utilities.PIDWithAutotuning.Relay.Controller for detailed explanation of the parameters triSta
becomes true;
-It then calculates the model parameters at the time when the tuning period ends, i.e., triEnd
becomes true.
+to identify the gain, the time constant and the time delay, respectively.
+triSta
becomes true;
+It then calculates the model parameters at the time when the tuning period ends,
+i.e., triEnd
becomes true.
yHig
, yLow
, and deaBan
.
+Buildings.Controls.OBC.Utilities.PIDWithAutotuning.Relay.ControlleryHig
, yLow
, and deaBan
.