Buildings.Fluid.HydronicConfigurations.PassiveNetworks.Examples

Example models

Information

This package contains examples for the use of models that can be found in Buildings.Fluid.HydronicConfigurations.PassiveNetworks.

Extends from Modelica.Icons.ExamplesPackage (Icon for packages containing runnable examples).

Package Content

Name Description
Buildings.Fluid.HydronicConfigurations.PassiveNetworks.Examples.DualMixing DualMixing Model illustrating the operation of a dual mixing circuit
Buildings.Fluid.HydronicConfigurations.PassiveNetworks.Examples.SingleMixing SingleMixing Model illustrating the operation of single mixing circuits
Buildings.Fluid.HydronicConfigurations.PassiveNetworks.Examples.SingleMixingOpenLoop SingleMixingOpenLoop Model illustrating the operation of single mixing circuits with primary back pressure
Buildings.Fluid.HydronicConfigurations.PassiveNetworks.Examples.BaseClasses BaseClasses Package with base classes

Buildings.Fluid.HydronicConfigurations.PassiveNetworks.Examples.DualMixing Buildings.Fluid.HydronicConfigurations.PassiveNetworks.Examples.DualMixing

Model illustrating the operation of a dual mixing circuit

Buildings.Fluid.HydronicConfigurations.PassiveNetworks.Examples.DualMixing

Information

This model represents a heating system where the configuration Buildings.Fluid.HydronicConfigurations.PassiveNetworks.DualMixing serves as the interface between a variable flow primary circuit and a constant flow secondary circuit. The secondary supply temperature is constant and lower than the primary circuit.

The fixed bypass of the dual mixing circuit is balanced at design conditions if kSizBal=1. Selecting a lower value such as kSizBal=0.6 illustrates the operation with an oversized balancing valve, yielding a lower pressure drop. One can observe that the secondary supply temperature set point cannot be met despite the control valve being fully open. The secondary distribution pump operates with sufficient head as the design flow rate is met in the consumer circuit. This is the low pressure differential at the boundaries of the control valve due to the oversized balancing valve that creates the primary flow shortage and prevents from serving the load properly.

Extends from BaseClasses.PartialPassivePrimary (Partial model of passive primary network).

Parameters

TypeNameDefaultDescription
ControltypBuildings.Fluid.HydronicConf...Load type
IntegernTer2Number of terminal units
Pressurep_min200000Circuit minimum pressure [Pa]
TemperatureTLiqEnt_nominal35 + 273.15Liquid entering temperature at design conditions [K]
TemperatureTLiqLvg_nominal25 + 273.15Liquid leaving temperature at design conditions [K]
TemperatureTLiqEntChg_nominal60 + 273.15Liquid entering temperature in change-over mode [K]
TemperatureTLiqSup_nominal60 + 273.15Liquid primary supply temperature at design conditions [K]
TemperatureTLiqSupChg_nominalTLiqEntChg_nominalLiquid primary supply temperature in change-over mode [K]
MassFlowRatemAir_flow_nominalabs(loa.loa.Q_flow_nominal)/...Air mass flow rate at design conditions [kg/s]
TemperatureTAirEnt_nominal24 + 273.15Air entering temperature at design conditions [K]
MassFractionphiAirEnt_nominal0.5Air entering relative humidity at design conditions [1]
Nominal condition
MassFlowRatemTer_flow_nominal1Terminal unit mass flow rate at design conditions [kg/s]
MassFlowRatem1_flow_nominalif abs(TLiqSup_nominal - TLi...Mass flow rate in primary circuit at design conditions [kg/s]
PressureDifferencedpTer_nominal3E4Terminal unit pressure drop at design conditions [Pa]
PressureDifferencedpPip_nominal0.5E4Pipe section pressure drop at design conditions [Pa]
MassFlowRatem2_flow_nominalnTer*mTer_flow_nominalMass flow rate in consumer circuit at design conditions [kg/s]
Configuration
RealkSizBal1.0Sizing factor for bypass balancing valve (1 means balanced)
Dynamics
Conservation equations
DynamicsenergyDynamicsModelica.Fluid.Types.Dynamic...Type of energy balance: dynamic (3 initialization options) or steady state

Modelica definition

model DualMixing "Model illustrating the operation of a dual mixing circuit" extends BaseClasses.PartialPassivePrimary( typ=Buildings.Fluid.HydronicConfigurations.Types.Control.Heating, m1_flow_nominal=if abs(TLiqSup_nominal - TLiqEnt_nominal) > Modelica.Constants.eps then m2_flow_nominal*(TLiqEnt_nominal - TLiqLvg_nominal)/(TLiqSup_nominal - TLiqLvg_nominal) else 0.95*m2_flow_nominal, TLiqEnt_nominal=35 + 273.15, TLiqLvg_nominal=25 + 273.15, TLiqSup_nominal=60 + 273.15, del1(nPorts=2), ref(use_T_in=true)); parameter Real kSizBal(final min=0) = 1.0 "Sizing factor for bypass balancing valve (1 means balanced)"; parameter Modelica.Units.SI.MassFlowRate m2_flow_nominal(final min=0)= nTer * mTer_flow_nominal "Mass flow rate in consumer circuit at design conditions"; parameter Modelica.Units.SI.MassFlowRate mAir_flow_nominal= abs(loa.loa.Q_flow_nominal) / 3 / 1015 "Air mass flow rate at design conditions"; parameter Modelica.Units.SI.Temperature TAirEnt_nominal= 24 + 273.15 "Air entering temperature at design conditions"; parameter Modelica.Units.SI.MassFraction phiAirEnt_nominal = 0.5 "Air entering relative humidity at design conditions"; Buildings.Fluid.HydronicConfigurations.PassiveNetworks.DualMixing con( typPum=Buildings.Fluid.HydronicConfigurations.Types.Pump.NoVariableInput, final typCtl=typ, redeclare final package Medium=MediumLiq, final energyDynamics=energyDynamics, final m2_flow_nominal=m2_flow_nominal, final m1_flow_nominal=m1_flow_nominal, dp1_nominal=res1.dp_nominal, final dp2_nominal=dpPip_nominal + loa1.dpTer_nominal + loa1.dpValve_nominal, final dpBal3_nominal=kSizBal * (con.dpValve_nominal + res1.dp_nominal)) "Hydronic connection"; ActiveNetworks.Examples.BaseClasses.LoadThreeWayValveControl loa( redeclare final package MediumLiq = MediumLiq, final typ=typ, final energyDynamics=energyDynamics, final mLiq_flow_nominal=mTer_flow_nominal, final mAir_flow_nominal=mAir_flow_nominal, final TAirEnt_nominal=TAirEnt_nominal, final phiAirEnt_nominal=phiAirEnt_nominal, final TLiqEnt_nominal=TLiqEnt_nominal, final TLiqLvg_nominal=TLiqLvg_nominal, final TLiqEntChg_nominal=TLiqEntChg_nominal) "Load"; Buildings.Controls.OBC.CDL.Integers.Sources.TimeTable mode( table=[0,0; 6,0; 6,1; 15,1; 15,1; 22,1; 22,0; 24,0], timeScale=3600, period=86400) "Operating mode (time schedule)"; Buildings.Controls.OBC.CDL.Reals.Sources.TimeTable fraLoa(table=[0,0,0; 6, 0,0; 6.1,1,1; 8,1,1; 9,1,0; 14,0.5,0; 14.5,0,0; 16,0,0; 17,0,1; 21,0,1; 22,0,0; 24,0,0], timeScale=3600) "Load modulating signal"; Buildings.Controls.OBC.CDL.Reals.Sources.Constant T2Set( y(final unit="K", displayUnit="degC"), final k=TLiqEnt_nominal) "Consumer circuit temperature set point"; Buildings.Controls.OBC.CDL.Reals.Sources.Constant T1Set( y(final unit="K", displayUnit="degC"), final k=TLiqSup_nominal) "Primary circuit temperature set point"; ActiveNetworks.Examples.BaseClasses.LoadThreeWayValveControl loa1( redeclare final package MediumLiq = MediumLiq, final typ=typ, final energyDynamics=energyDynamics, final mLiq_flow_nominal=mTer_flow_nominal, final mAir_flow_nominal=mAir_flow_nominal, final TAirEnt_nominal=TAirEnt_nominal, final phiAirEnt_nominal=phiAirEnt_nominal, final TLiqEnt_nominal=TLiqEnt_nominal, final TLiqLvg_nominal=TLiqLvg_nominal, final TLiqEntChg_nominal=TLiqEntChg_nominal) "Load"; FixedResistances.PressureDrop res2( redeclare final package Medium = MediumLiq, final m_flow_nominal=con.pum.m_flow_nominal - loa.mLiq_flow_nominal, final dp_nominal=dpPip_nominal) "Pipe pressure drop"; Delays.DelayFirstOrder del2( redeclare final package Medium = MediumLiq, final energyDynamics=energyDynamics, final m_flow_nominal=m2_flow_nominal, nPorts=3) "Fluid transport delay"; equation connect(con.port_b2, loa.port_a); connect(con.port_b1, del1.ports[2]); connect(mode.y[1], loa.mode); connect(mode.y[1], con.mode); connect(fraLoa.y[1], loa.u); connect(res1.port_b, con.port_a1); connect(con.port_b2, res2.port_a); connect(res2.port_b, loa1.port_a); connect(del2.ports[1], con.port_a2); connect(loa.port_b, del2.ports[2]); connect(loa1.port_b, del2.ports[3]); connect(mode.y[1], loa1.mode); connect(fraLoa.y[2], loa1.u); connect(T1Set.y, ref.T_in); connect(T2Set.y, con.set); end DualMixing;

Buildings.Fluid.HydronicConfigurations.PassiveNetworks.Examples.SingleMixing Buildings.Fluid.HydronicConfigurations.PassiveNetworks.Examples.SingleMixing

Model illustrating the operation of single mixing circuits

Buildings.Fluid.HydronicConfigurations.PassiveNetworks.Examples.SingleMixing

Information

This model represents a change-over system where the configuration Buildings.Fluid.HydronicConfigurations.PassiveNetworks.SingleMixing serves as the interface between a variable flow primary circuit at constant supply temperature and two consumer circuits: the first one is a constant flow circuit, the second one is a variable flow circuit. For each circuit, the secondary supply temperature is reset with an open loop, representing for instance a reset logic based on the outdoor air temperature. The pump model for the second circuit is an ideal Δp-controlled model, its input being computed to mimic the tracking of a pressure differential at the boundaries of the terminal unit.

Extends from BaseClasses.PartialPassivePrimary (Partial model of passive primary network).

Parameters

TypeNameDefaultDescription
ControltypBuildings.Fluid.HydronicConf...Load type
IntegernTer2Number of terminal units
Pressurep_min200000Circuit minimum pressure [Pa]
TemperatureTLiqEnt_nominalif typ == Buildings.Fluid.Hy...Liquid entering temperature at design conditions [K]
TemperatureTLiqLvg_nominalTLiqEnt_nominal + (if typ ==...Liquid leaving temperature at design conditions [K]
TemperatureTLiqEntChg_nominal60 + 273.15Liquid entering temperature in change-over mode [K]
TemperatureTLiqSup_nominalTLiqEnt_nominalLiquid primary supply temperature at design conditions [K]
TemperatureTLiqSupChg_nominalTLiqEntChg_nominalLiquid primary supply temperature in change-over mode [K]
Nominal condition
MassFlowRatemTer_flow_nominal1Terminal unit mass flow rate at design conditions [kg/s]
MassFlowRatem1_flow_nominalnTer*mTer_flow_nominalMass flow rate in primary circuit at design conditions [kg/s]
PressureDifferencedpTer_nominal3E4Terminal unit pressure drop at design conditions [Pa]
PressureDifferencedpPip_nominal0.5E4Pipe section pressure drop at design conditions [Pa]
Controls
PressureDifferencedp2Setloa1.dpTer_nominal + loa1.dp...Secondary pressure differential set point [Pa]
Dynamics
Conservation equations
DynamicsenergyDynamicsModelica.Fluid.Types.Dynamic...Type of energy balance: dynamic (3 initialization options) or steady state

Modelica definition

model SingleMixing "Model illustrating the operation of single mixing circuits" extends BaseClasses.PartialPassivePrimary( typ=Buildings.Fluid.HydronicConfigurations.Types.Control.ChangeOver, del1(nPorts=3), ref(use_T_in=true)); parameter Modelica.Units.SI.PressureDifference dp2Set( final min=0, displayUnit="Pa") = loa1.dpTer_nominal + loa1.dpValve_nominal "Secondary pressure differential set point"; Buildings.Fluid.HydronicConfigurations.PassiveNetworks.SingleMixing con( typPum=Buildings.Fluid.HydronicConfigurations.Types.Pump.NoVariableInput, final typCtl=typ, redeclare final package Medium=MediumLiq, final energyDynamics=energyDynamics, final m2_flow_nominal=loa.m_flow_nominal, dp1_nominal=0, final dp2_nominal=loa.dpTer_nominal + loa.dpValve_nominal) "Hydronic connection"; ActiveNetworks.Examples.BaseClasses.LoadThreeWayValveControl loa( redeclare final package MediumLiq = MediumLiq, final typ=typ, final energyDynamics=energyDynamics, final mLiq_flow_nominal=mTer_flow_nominal, final TLiqEnt_nominal=TLiqEnt_nominal, final TLiqLvg_nominal=TLiqLvg_nominal, final TLiqEntChg_nominal=TLiqEntChg_nominal) "Load"; Buildings.Fluid.HydronicConfigurations.PassiveNetworks.SingleMixing con1( typPumMod=Buildings.Fluid.HydronicConfigurations.Types.PumpModel.Head, typPum=Buildings.Fluid.HydronicConfigurations.Types.Pump.VariableInput, final typCtl=typ, redeclare final package Medium = MediumLiq, final energyDynamics=energyDynamics, final m2_flow_nominal=loa1.m_flow_nominal / 0.9, dp1_nominal=0, final dp2_nominal=dp2Set) "Hydronic connection"; ActiveNetworks.Examples.BaseClasses.LoadTwoWayValveControl loa1( redeclare final package MediumLiq = MediumLiq, final typ=typ, final energyDynamics=energyDynamics, final mLiq_flow_nominal=mTer_flow_nominal, final TLiqEnt_nominal=TLiqEnt_nominal, final TLiqLvg_nominal=TLiqLvg_nominal, final TLiqEntChg_nominal=TLiqEntChg_nominal) "Load"; Sensors.RelativePressure dp2(redeclare final package Medium = MediumLiq) "Differential pressure"; FixedResistances.PressureDrop resEnd2( redeclare final package Medium = MediumLiq, final m_flow_nominal=0.1*con1.pum.m_flow_nominal, final dp_nominal=dp2Set) "Pipe pressure drop"; Buildings.Controls.OBC.CDL.Integers.Sources.TimeTable mode( table=[0,0; 6,0; 6,2; 15,2; 15,1; 22,1; 22,0; 24,0], timeScale=3600, period=86400) "Operating mode (time schedule)"; Buildings.Controls.OBC.CDL.Reals.Sources.TimeTable fraLoa(table=[0,0,0; 6, 0,0; 6.1,1,1; 8,1,1; 9,1,0; 14,0.5,0; 14.5,0,0; 16,0,0; 17,0,1; 21,0,1; 22,0,0; 24,0,0], timeScale=3600) "Load modulating signal"; Buildings.Controls.OBC.CDL.Reals.Sources.TimeTable setOff(table=[0,0; 10, 0; 13,-8; 13,0; 18,0; 22,+5; 22,0; 24,0], timeScale=3600) "Offset applied to design supply temperature to compute set point"; Buildings.Controls.OBC.CDL.Reals.Add T2Set(y(final unit="K", displayUnit="degC")) "Consumer circuit temperature set point"; Buildings.Controls.OBC.CDL.Routing.RealExtractor T2SetMod(nin=3, y(final unit="K", displayUnit="degC")) "Select consumer circuit temperature set point based on operating mode"; Buildings.Controls.OBC.CDL.Reals.Sources.Constant T2SetVal[3](final k={ MediumLiq.T_default,TLiqEnt_nominal,TLiqEntChg_nominal}) "Consumer circuit temperature set point values"; Buildings.Controls.OBC.CDL.Reals.Sources.Constant T1SetVal[3](final k={ MediumLiq.T_default,TLiqSup_nominal,TLiqSupChg_nominal}) "Primary circuit temperature set point values"; Buildings.Controls.OBC.CDL.Routing.RealExtractor T1Set(nin=3, y(final unit="K", displayUnit="degC")) "Primary circuit temperature set point"; Modelica.Blocks.Sources.RealExpression uPum(y=(dp2Set + con1.val.dp3)/con1.pum.dp_nominal) "Pump control signal"; Buildings.Controls.OBC.CDL.Integers.AddParameter addPar(final p=1) "Convert mode index to array index"; equation connect(con.port_b2, loa.port_a); connect(loa.port_b, con.port_a2); connect(con.port_b1, del1.ports[2]); connect(con1.port_b1, del1.ports[3]); connect(loa1.port_a, dp2.port_a); connect(loa1.port_b, dp2.port_b); connect(dp2.port_a, con1.port_b2); connect(dp2.port_b, con1.port_a2); connect(resEnd2.port_b, loa1.port_b); connect(resEnd2.port_a, loa1.port_a); connect(mode.y[1], loa.mode); connect(mode.y[1], loa1.mode); connect(mode.y[1], con.mode); connect(fraLoa.y[1], loa.u); connect(fraLoa.y[2], loa1.u); connect(mode.y[1], con1.mode); connect(T2SetVal.y, T2SetMod.u); connect(T2SetMod.y, T2Set.u1); connect(setOff.y[1], T2Set.u2); connect(T2Set.y, con.set); connect(T2Set.y, con1.set); connect(T1SetVal.y, T1Set.u); connect(T1Set.y, ref.T_in); connect(res1.port_b, con.port_a1); connect(res1.port_b, con1.port_a1); connect(uPum.y, con1.yPum); connect(mode.y[1], addPar.u); connect(addPar.y, T1Set.index); connect(addPar.y, T2SetMod.index); end SingleMixing;

Buildings.Fluid.HydronicConfigurations.PassiveNetworks.Examples.SingleMixingOpenLoop Buildings.Fluid.HydronicConfigurations.PassiveNetworks.Examples.SingleMixingOpenLoop

Model illustrating the operation of single mixing circuits with primary back pressure

Buildings.Fluid.HydronicConfigurations.PassiveNetworks.Examples.SingleMixingOpenLoop

Information

This model illustrates the disturbance caused on the three-way valve operation by an induced negative pressure differential at the circuit boundaries. Two consumer circuits are connected to a primary loop by means of Buildings.Fluid.HydronicConfigurations.PassiveNetworks.SingleMixing. The primary loop is configured with a flow resistance that generates a negative pressure differential at the boundaries of the consumer circuits (representing for instance a boiler with a high pressure drop and no minimum flow requirement). Each consumer circuit is equipped with a circulation pump that is sized to cover the primary pressure differential. When the parameter is_bal is false no bypass balancing valve is considered. When this parameter is true a bypass balancing valve is considered with the same design pressure drop as the one in the primary loop. The pump design head remains unchanged whatever the value of the parameter is_bal. The model is configured in steady-state with open loop control. The load on each consumer circuit is constant. The control valve of the first circuit is modulated from fully open to fully closed position while the control valve of the remote circuit is kept fully open.

When the bypass is not balanced, the flow reverses in the primary branch when the valve opening is below 20% which means that the load cannot be served any more.

When the bypass is balanced, no flow reversal occurs and the mixing function of the three-way valve is preserved over its whole opening range.

Note that the setting of this model represents an oversized control valve with a low authority β = 0.14. Setting a higher valve design pressure drop to reach an authority close to 0.5 alleviates the risk of primary flow reversal and reduces the need for a bypass balancing valve.

Extends from BaseClasses.PartialPassivePrimary (Partial model of passive primary network).

Parameters

TypeNameDefaultDescription
ControltypBuildings.Fluid.HydronicConf...Load type
IntegernTer2Number of terminal units
Pressurep_min200000Circuit minimum pressure [Pa]
TemperatureTLiqEnt_nominal60 + 273.15Liquid entering temperature at design conditions [K]
TemperatureTLiqLvg_nominalTLiqEnt_nominal - 10Liquid leaving temperature at design conditions [K]
TemperatureTLiqEntChg_nominal60 + 273.15Liquid entering temperature in change-over mode [K]
TemperatureTLiqSup_nominalTLiqEnt_nominalLiquid primary supply temperature at design conditions [K]
TemperatureTLiqSupChg_nominalTLiqEntChg_nominalLiquid primary supply temperature in change-over mode [K]
PressureDifferencedpValve_nominal5e3Control valve pressure drop at design conditions [Pa]
Nominal condition
MassFlowRatemTer_flow_nominal1Terminal unit mass flow rate at design conditions [kg/s]
MassFlowRatem1_flow_nominalnTer*mTer_flow_nominalMass flow rate in primary circuit at design conditions [kg/s]
PressureDifferencedpTer_nominal3E4Terminal unit pressure drop at design conditions [Pa]
PressureDifferencedpPip_nominal0.5E4Pipe section pressure drop at design conditions [Pa]
Configuration
Booleanis_balfalseSet to true for balanced bypass branch
Dynamics
Conservation equations
DynamicsenergyDynamicsModelica.Fluid.Types.Dynamic...Type of energy balance: dynamic (3 initialization options) or steady state

Modelica definition

model SingleMixingOpenLoop "Model illustrating the operation of single mixing circuits with primary back pressure" extends BaseClasses.PartialPassivePrimary( typ=Buildings.Fluid.HydronicConfigurations.Types.Control.Heating, TLiqEnt_nominal=60 + 273.15, TLiqLvg_nominal=TLiqEnt_nominal - 10, TLiqSup_nominal=TLiqEnt_nominal, energyDynamics=Modelica.Fluid.Types.Dynamics.SteadyState, del1(nPorts=3), res1(dp_nominal=3e4)); parameter Boolean is_bal=false "Set to true for balanced bypass branch"; parameter Modelica.Units.SI.PressureDifference dpValve_nominal( displayUnit="Pa") = 5e3 "Control valve pressure drop at design conditions"; Buildings.Fluid.HydronicConfigurations.PassiveNetworks.SingleMixing con( typPum=Buildings.Fluid.HydronicConfigurations.Types.Pump.NoVariableInput, redeclare final package Medium=MediumLiq, val(fraK=1.0), final typCtl=Buildings.Fluid.HydronicConfigurations.Types.Control.None, final energyDynamics=energyDynamics, final m2_flow_nominal=loa.m_flow_nominal, dp1_nominal=res1.dp_nominal, final dp2_nominal=loa.dpLiq_nominal, final dpValve_nominal=dpValve_nominal, final dpBal3_nominal=if is_bal then res1.dp_nominal else 0) "Hydronic connection"; Buildings.Fluid.HydronicConfigurations.ActiveNetworks.Examples.BaseClasses.Load loa( redeclare final package MediumLiq = MediumLiq, final typ=typ, final energyDynamics=energyDynamics, final mLiq_flow_nominal=mTer_flow_nominal, final dpLiq_nominal=dpTer_nominal, final TLiqEnt_nominal=TLiqEnt_nominal, final TLiqLvg_nominal=TLiqLvg_nominal) "Load"; Buildings.Fluid.HydronicConfigurations.PassiveNetworks.SingleMixing con1( typPum=Buildings.Fluid.HydronicConfigurations.Types.Pump.NoVariableInput, redeclare final package Medium = MediumLiq, val(fraK=1.0), final typCtl=Buildings.Fluid.HydronicConfigurations.Types.Control.None, final energyDynamics=energyDynamics, final m2_flow_nominal=loa1.m_flow_nominal, dp1_nominal=res1.dp_nominal, final dp2_nominal=loa1.dpLiq_nominal, final dpValve_nominal=dpValve_nominal, final dpBal3_nominal=if is_bal then res1.dp_nominal else 0) "Hydronic connection"; Buildings.Fluid.HydronicConfigurations.ActiveNetworks.Examples.BaseClasses.Load loa1( redeclare final package MediumLiq = MediumLiq, final typ=typ, final energyDynamics=energyDynamics, final mLiq_flow_nominal=mTer_flow_nominal, final dpLiq_nominal=dpTer_nominal, final TLiqEnt_nominal=TLiqEnt_nominal, final TLiqLvg_nominal=TLiqLvg_nominal) "Load"; Buildings.Controls.OBC.CDL.Integers.Sources.Constant mode(k=1) "Operating mode"; Buildings.Controls.OBC.CDL.Reals.Sources.Constant fraLoa(k=1) "Load modulating signal"; Buildings.Controls.OBC.CDL.Reals.Sources.TimeTable ope( table=[0,1,1; 1,0,1], extrapolation=Buildings.Controls.OBC.CDL.Types.Extrapolation.HoldLastPoint, timeScale=100) "Valve opening signal"; equation connect(con.port_b2, loa.port_a); connect(loa.port_b, con.port_a2); connect(con.port_b1, del1.ports[2]); connect(con1.port_b1, del1.ports[3]); connect(mode.y, loa.mode); connect(mode.y, loa1.mode); connect(mode.y, con.mode); connect(fraLoa.y, loa.u); connect(fraLoa.y, loa1.u); connect(mode.y, con1.mode); connect(res1.port_b, con.port_a1); connect(res1.port_b, con1.port_a1); connect(con1.port_b2, loa1.port_a); connect(loa1.port_b, con1.port_a2); connect(ope.y[1], con.yVal); connect(ope.y[2], con1.yVal); end SingleMixingOpenLoop;