From a8a09804e09007cc4b42ac86ba52414d7e2114f8 Mon Sep 17 00:00:00 2001 From: AntoineGautier Date: Wed, 20 Sep 2023 14:42:39 +0200 Subject: [PATCH 1/5] Revert most of the changes from #1782 This is done manually as git apply with diff from d2edb0cae fails. error: IBPSA/Fluid/Interfaces/PartialTwoPort.mo: patch does not apply --- IBPSA/Fluid/Interfaces/PartialFourPort.mo | 31 ++---------- IBPSA/Fluid/Interfaces/PartialTwoPort.mo | 19 +------ .../Fluid/Interfaces/PartialTwoPortVector.mo | 21 +------- .../Storage/BaseClasses/PartialStratified.mo | 43 ++++++++++++++-- IBPSA/Fluid/Storage/Examples/Stratified.mo | 49 +++++++++---------- .../Examples/StratifiedEnhancedInternalHex.mo | 7 ++- .../StratifiedUnloadAtMinimumTemperature.mo | 21 ++++---- .../Validation/HeatExchangerDynamics.mo | 13 ++--- 8 files changed, 91 insertions(+), 113 deletions(-) diff --git a/IBPSA/Fluid/Interfaces/PartialFourPort.mo b/IBPSA/Fluid/Interfaces/PartialFourPort.mo index 524ee257a9..1d5cb458ca 100644 --- a/IBPSA/Fluid/Interfaces/PartialFourPort.mo +++ b/IBPSA/Fluid/Interfaces/PartialFourPort.mo @@ -34,44 +34,26 @@ partial model PartialFourPort "Partial model with four ports" m_flow(min=if allowFlowReversal1 then -Modelica.Constants.inf else 0), h_outflow(start = Medium1.h_default, nominal = Medium1.h_default)) "Fluid connector a1 (positive design flow direction is from port_a1 to port_b1)" - annotation (Placement(transformation(extent={{port_a1_x-10,port_a1_y-10},{port_a1_x+10,port_a1_y+10}}))); + annotation (Placement(transformation(extent={{-110,50},{-90,70}}))); Modelica.Fluid.Interfaces.FluidPort_b port_b1( redeclare final package Medium = Medium1, m_flow(max=if allowFlowReversal1 then +Modelica.Constants.inf else 0), h_outflow(start = Medium1.h_default, nominal = Medium1.h_default)) "Fluid connector b1 (positive design flow direction is from port_a1 to port_b1)" - annotation (Placement(transformation(extent={{port_b1_x-10,port_b1_y-10},{port_b1_x+10,port_b1_y+10}}))); + annotation (Placement(transformation(extent={{110,50},{90,70}}))); Modelica.Fluid.Interfaces.FluidPort_a port_a2( redeclare final package Medium = Medium2, m_flow(min=if allowFlowReversal2 then -Modelica.Constants.inf else 0), h_outflow(start = Medium2.h_default, nominal = Medium2.h_default)) "Fluid connector a2 (positive design flow direction is from port_a2 to port_b2)" - annotation (Placement(transformation(extent={{port_a2_x-10,port_a2_y-10},{port_a2_x+10,port_a2_y+10}}))); + annotation (Placement(transformation(extent={{90,-70},{110,-50}}))); Modelica.Fluid.Interfaces.FluidPort_b port_b2( redeclare final package Medium = Medium2, m_flow(max=if allowFlowReversal2 then +Modelica.Constants.inf else 0), h_outflow(start = Medium2.h_default, nominal = Medium2.h_default)) "Fluid connector b2 (positive design flow direction is from port_a2 to port_b2)" - annotation (Placement(transformation(extent={{port_b2_x-10,port_b2_y-10},{port_b2_x+10,port_b2_y+10}}))); - -protected - constant Integer port_a1_x = -100 - "x-coordinate of port_a1 center"; - constant Integer port_a1_y = 60 - "y-coordinate of port_a1 center"; - constant Integer port_b1_x = 100 - "x-coordinate of port_b1 center"; - constant Integer port_b1_y = 60 - "y-coordinate of port_b1 center"; - constant Integer port_a2_x = 100 - "x-coordinate of port_a2 center"; - constant Integer port_a2_y = -60 - "y-coordinate of port_a2 center"; - constant Integer port_b2_x = -100 - "x-coordinate of port_b2 center"; - constant Integer port_b2_y = -60 - "y-coordinate of port_b2 center"; + annotation (Placement(transformation(extent={{-90,-70},{-110,-50}}))); annotation ( preferredView="info", @@ -101,11 +83,6 @@ are not implemented. ", revisions="