How to Choose Dynamics Options for Dynamic Pipes?

Below is a model of two parallel flows exchanging heat through convection with varying boundary conditions.

The model works fine with steady-state options, which means the mass flow in the pipes is constant. However, the model does not work well with the other options such as “dynamicFreeInitial” etc.

In fact, while the initialization problem is managed correctly with the homotopy method, I encounter a warning indicating that the system is underdetermined.

Additionally, when adding components to this system and using “Modelica.Fluid.Types.Dynamics.FixedInitial” options, the software gets stuck at 0%. even if the initialization is handed correctly.

Questions :

1- Why do I get the warning that the system is under-determined when using “Modelica.Fluid.Types.Dynamics.FixedInitial”?

2- Is it normal, based on your experience, to have a significant difference in simulation time when using steady-state options compared to FixedInitial options?

code :

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
<code>model Model
import Modelica.Constants.pi;
parameter Integer nNodes = 2;
parameter Real d = 11e-3;
parameter Real D = 18e-3;
parameter Real P_start_1 = 10e+5;
parameter Real P_start_2 = 153e+5;
parameter Real T_start_1 = 55 + 273.15;
parameter Real T_start_2 = 38 + 273.15;
parameter Real S_conv_1 = 0.4;
parameter Real S_conv_2 = 0.3;
parameter Real he = 648;
parameter Real h_conv_1 = 300;
parameter Real h_conv_2 = 100;
parameter Real L1 = 1400e-3;
parameter Real L2 = 1300e-3;
parameter Real k_conv_1 = h_conv_1*S_conv_1;
parameter Real k_conv_2 = S_conv_2*h_conv_2;
replaceable package Medium = Modelica.Media.Water.StandardWaterOnePhase constrainedby Modelica.Media.Interfaces.PartialMedium;
replaceable model HeatTransfer_1 = Modelica.Fluid.Pipes.BaseClasses.HeatTransfer.ConstantFlowHeatTransfer(alpha0 = 5000);
Modelica.Fluid.Sources.Boundary_pT Inlet_2(redeclare package Medium = Medium, T = 311.15, nPorts = 1, p = 1074000, use_T_in = false) annotation(
Placement(transformation(origin = {-258, 54}, extent = {{-10, -10}, {10, 10}})));
Modelica.Fluid.Pipes.DynamicPipe pipe_3(redeclare package Medium = Medium, redeclare final model HeatTransfer = HeatTransfer_1, diameter = d, length = L1, nNodes = nNodes, use_HeatTransfer = true, p_a_start = P_start_1, p_b_start = P_start_1, T_start = T_start_1, m_flow_start = 2.5) annotation(
Placement(transformation(origin = {-162, 54}, extent = {{10, -10}, {-10, 10}}, rotation = -180)));
inner Modelica.Fluid.System system(T_start(displayUnit = "degC"), m_flow_start = 0.05, energyDynamics = Modelica.Fluid.Types.Dynamics.FixedInitial, massDynamics = Modelica.Fluid.Types.Dynamics.FixedInitial) annotation(
Placement(transformation(origin = {-258, -1}, extent = {{-12, -11}, {12, 11}})));
Modelica.Fluid.Examples.HeatExchanger.BaseClasses.WallConstProps wall_1(area_h = 0.6, c_wall = 500, k_wall = 14.4, n = nNodes, rho_wall = 7850, s = 3.1e-3, T_start = 311.15, dT = 273.15) annotation(
Placement(transformation(origin = {-162, 30}, extent = {{-10, -10}, {10, 10}}, rotation = 180)));
Modelica.Fluid.Sources.MassFlowSource_T outlet_2(redeclare package Medium = Medium, T = 318.15, nPorts = 1, use_T_in = true, use_m_flow_in = true, m_flow = -0.208333333) annotation(
Placement(transformation(origin = {-82, 54}, extent = {{10, 10}, {-10, -10}})));
Modelica.Thermal.HeatTransfer.Components.Convection convection_serpentin_1[nNodes] annotation(
Placement(transformation(origin = {-162, 6}, extent = {{-10, 10}, {10, -10}}, rotation = -90)));
Modelica.Thermal.HeatTransfer.Components.ThermalCollector thermalCollector(m = nNodes) annotation(
Placement(transformation(origin = {-162, -20}, extent = {{-10, -10}, {10, 10}})));
Modelica.Blocks.Sources.Constant A_1[nNodes](each k = 50) annotation(
Placement(transformation(origin = {-194, 6}, extent = {{-10, -10}, {10, 10}})));
Modelica.Fluid.Pipes.DynamicPipe pipe_2(redeclare package Medium = Medium, diameter = 0.1, length = 130e-3, modelStructure = Modelica.Fluid.Types.ModelStructure.a_v_b, nNodes = 1, use_HeatTransfer = true, isCircular = false, p_a_start = P_start_2, p_b_start = P_start_2, crossArea = Modelica.Constants.pi*(0.474^2 - 0.215^2), perimeter = Modelica.Constants.pi*(0.948 + 0.430), roughness = 3.500000000000001e-05, T_start = T_start_2, m_flow_start = 0.25) annotation(
Placement(transformation(origin = {-122, -50}, extent = {{-10, -10}, {10, 10}})));
Modelica.Fluid.Pipes.DynamicPipe pipe_1(redeclare package Medium = Medium, diameter = 0.1, length = 130e-3, modelStructure = Modelica.Fluid.Types.ModelStructure.a_v_b, nNodes = 1, use_HeatTransfer = true, p_a_start = P_start_2, p_b_start = P_start_2, isCircular = false, crossArea = Modelica.Constants.pi*(0.460^2 - 0.200^2), perimeter = Modelica.Constants.pi*(0.900 + 0.415), roughness = 3.500000000000001e-05, T_start = T_start_2, m_flow_start = 0.25) annotation(
Placement(transformation(origin = {-162, -50}, extent = {{-10, -10}, {10, 10}})));
Modelica.Fluid.Sources.MassFlowSource_T outlet_1(redeclare package Medium = Medium, nPorts = 1, use_T_in = true, use_m_flow_in = true, m_flow = -0.25, T = 318.15) annotation(
Placement(transformation(origin = {-88, -50}, extent = {{10, 10}, {-10, -10}})));
Modelica.Fluid.Sources.Boundary_pT inlet_1(redeclare package Medium = Medium, T = 328.15, nPorts = 1, use_T_in = false, use_p_in = false, p = 15300000) annotation(
Placement(transformation(origin = {-256, -50}, extent = {{-10, -10}, {10, 10}})));
Modelica.Thermal.HeatTransfer.Sensors.TemperatureSensor temperatureSensor annotation(
Placement(transformation(origin = {-44, -42}, extent = {{10, -10}, {-10, 10}})));
Modelica.Blocks.Sources.TimeTable flow_outlet_1(table = [0, -0.05; 116, -0.2475; 128, -0.2052; 136, -0.1647; 144, -0.1287; 152, -0.0972; 158, -0.0756; 164, -0.0549; 264, -0.01; 600, -0.01]) annotation(
Placement(transformation(origin = {-44, -78}, extent = {{10, -10}, {-10, 10}})));
Modelica.Blocks.Sources.TimeTable Flow_outlet_2(table = [0, -0.05; 68, -0.15833333; 74, -0.14166667; 80, -0.12; 108, -0.033; 122, -0.01875; 136, -0.009; 144, -0.006; 164, -0.00083333; 524, -0.00083333; 530, -0.027; 534, -0.051; 538, -0.07575; 548, -0.11925; 558, -0.14625; 570, -0.168; 586, -0.1815; 600, -0.1875]) annotation(
Placement(transformation(origin = {-36, 20}, extent = {{10, -10}, {-10, 10}})));
Modelica.Thermal.HeatTransfer.Sensors.TemperatureSensor temperatureSensor1 annotation(
Placement(transformation(origin = {-44, 50}, extent = {{10, -10}, {-10, 10}})));
Modelica.Fluid.Pipes.StaticPipe pipe(length = 0.1, diameter = 0.1, redeclare package Medium = Medium, p_a_start = P_start_1, p_b_start = P_start_1) annotation(
Placement(transformation(origin = {-210, 54}, extent = {{-10, -10}, {10, 10}})));
Modelica.Fluid.Pipes.StaticPipe pipe1(redeclare package Medium = Medium, diameter = 0.1, length = 0.1, p_a_start = P_start_1, p_b_start = P_start_1) annotation(
Placement(transformation(origin = {-122, 54}, extent = {{-10, -10}, {10, 10}})));
equation
connect(outlet_2.T_in, temperatureSensor1.T) annotation(
Line(points = {{-70, 50}, {-54, 50}}, color = {0, 0, 127}));
connect(pipe_3.heatPorts, wall_1.heatPort_b) annotation(
Line(points = {{-162, 50}, {-162.5, 50}, {-162.5, 35}, {-162, 35}}, color = {127, 0, 0}, thickness = 0.5));
connect(wall_1.heatPort_a, convection_serpentin_1.solid) annotation(
Line(points = {{-162, 25}, {-162, 16}}, color = {191, 0, 0}, thickness = 0.5));
connect(A_1.y, convection_serpentin_1.Gc) annotation(
Line(points = {{-183, 6}, {-178, 6}}, color = {0, 0, 127}, thickness = 0.5));
connect(convection_serpentin_1.fluid, thermalCollector.port_a) annotation(
Line(points = {{-162, -4}, {-162, -10}}, color = {191, 0, 0}, thickness = 0.5));
connect(thermalCollector.port_b, pipe_1.heatPorts[1]) annotation(
Line(points = {{-162, -30}, {-162, -46}}, color = {191, 0, 0}));
connect(outlet_2.m_flow_in, Flow_outlet_2.y) annotation(
Line(points = {{-72, 46}, {-72, 20}, {-47, 20}}, color = {0, 0, 127}));
connect(outlet_1.T_in, temperatureSensor.T) annotation(
Line(points = {{-76, -54}, {-68, -54}, {-68, -42}, {-54, -42}}, color = {0, 0, 127}));
connect(outlet_1.m_flow_in, flow_outlet_1.y) annotation(
Line(points = {{-78, -58}, {-78, -79.5}, {-55, -79.5}, {-55, -78}}, color = {0, 0, 127}));
connect(pipe_2.heatPorts[1], temperatureSensor.port) annotation(
Line(points = {{-122, -46}, {-122, -25.6}, {-21.9, -25.6}, {-21.9, -42}, {-34, -42}}, color = {191, 0, 0}));
connect(pipe_3.heatPorts[nNodes], temperatureSensor1.port) annotation(
Line(points = {{-198, 50}, {-130, 50}, {-130, 76}, {32, 76}, {32, 50}, {16, 50}}, color = {191, 0, 0}));
connect(inlet_1.ports[1], pipe_1.port_a) annotation(
Line(points = {{-246, -50}, {-172, -50}}, color = {0, 127, 255}));
connect(pipe_2.port_b, outlet_1.ports[1]) annotation(
Line(points = {{-112, -50}, {-98, -50}}, color = {0, 127, 255}));
connect(pipe_1.port_b, pipe_2.port_a) annotation(
Line(points = {{-152, -50}, {-132, -50}}, color = {0, 127, 255}));
connect(Inlet_2.ports[1], pipe.port_a) annotation(
Line(points = {{-248, 54}, {-220, 54}}, color = {0, 127, 255}));
connect(pipe.port_b, pipe_3.port_a) annotation(
Line(points = {{-200, 54}, {-172, 54}}, color = {0, 127, 255}));
connect(pipe_3.port_b, pipe1.port_a) annotation(
Line(points = {{-152, 54}, {-132, 54}}, color = {0, 127, 255}));
connect(pipe1.port_b, outlet_2.ports[1]) annotation(
Line(points = {{-112, 54}, {-92, 54}}, color = {0, 127, 255}));
algorithm
annotation(
uses(Modelica(version = "3.2.3")),
Diagram(coordinateSystem(extent = {{-280, 80}, {-20, -100}}, initialScale = 0.1)),
Icon(coordinateSystem(extent = {{-1000, -205}, {425, 100}})),
version = "");
end Model;
</code>
<code>model Model import Modelica.Constants.pi; parameter Integer nNodes = 2; parameter Real d = 11e-3; parameter Real D = 18e-3; parameter Real P_start_1 = 10e+5; parameter Real P_start_2 = 153e+5; parameter Real T_start_1 = 55 + 273.15; parameter Real T_start_2 = 38 + 273.15; parameter Real S_conv_1 = 0.4; parameter Real S_conv_2 = 0.3; parameter Real he = 648; parameter Real h_conv_1 = 300; parameter Real h_conv_2 = 100; parameter Real L1 = 1400e-3; parameter Real L2 = 1300e-3; parameter Real k_conv_1 = h_conv_1*S_conv_1; parameter Real k_conv_2 = S_conv_2*h_conv_2; replaceable package Medium = Modelica.Media.Water.StandardWaterOnePhase constrainedby Modelica.Media.Interfaces.PartialMedium; replaceable model HeatTransfer_1 = Modelica.Fluid.Pipes.BaseClasses.HeatTransfer.ConstantFlowHeatTransfer(alpha0 = 5000); Modelica.Fluid.Sources.Boundary_pT Inlet_2(redeclare package Medium = Medium, T = 311.15, nPorts = 1, p = 1074000, use_T_in = false) annotation( Placement(transformation(origin = {-258, 54}, extent = {{-10, -10}, {10, 10}}))); Modelica.Fluid.Pipes.DynamicPipe pipe_3(redeclare package Medium = Medium, redeclare final model HeatTransfer = HeatTransfer_1, diameter = d, length = L1, nNodes = nNodes, use_HeatTransfer = true, p_a_start = P_start_1, p_b_start = P_start_1, T_start = T_start_1, m_flow_start = 2.5) annotation( Placement(transformation(origin = {-162, 54}, extent = {{10, -10}, {-10, 10}}, rotation = -180))); inner Modelica.Fluid.System system(T_start(displayUnit = "degC"), m_flow_start = 0.05, energyDynamics = Modelica.Fluid.Types.Dynamics.FixedInitial, massDynamics = Modelica.Fluid.Types.Dynamics.FixedInitial) annotation( Placement(transformation(origin = {-258, -1}, extent = {{-12, -11}, {12, 11}}))); Modelica.Fluid.Examples.HeatExchanger.BaseClasses.WallConstProps wall_1(area_h = 0.6, c_wall = 500, k_wall = 14.4, n = nNodes, rho_wall = 7850, s = 3.1e-3, T_start = 311.15, dT = 273.15) annotation( Placement(transformation(origin = {-162, 30}, extent = {{-10, -10}, {10, 10}}, rotation = 180))); Modelica.Fluid.Sources.MassFlowSource_T outlet_2(redeclare package Medium = Medium, T = 318.15, nPorts = 1, use_T_in = true, use_m_flow_in = true, m_flow = -0.208333333) annotation( Placement(transformation(origin = {-82, 54}, extent = {{10, 10}, {-10, -10}}))); Modelica.Thermal.HeatTransfer.Components.Convection convection_serpentin_1[nNodes] annotation( Placement(transformation(origin = {-162, 6}, extent = {{-10, 10}, {10, -10}}, rotation = -90))); Modelica.Thermal.HeatTransfer.Components.ThermalCollector thermalCollector(m = nNodes) annotation( Placement(transformation(origin = {-162, -20}, extent = {{-10, -10}, {10, 10}}))); Modelica.Blocks.Sources.Constant A_1[nNodes](each k = 50) annotation( Placement(transformation(origin = {-194, 6}, extent = {{-10, -10}, {10, 10}}))); Modelica.Fluid.Pipes.DynamicPipe pipe_2(redeclare package Medium = Medium, diameter = 0.1, length = 130e-3, modelStructure = Modelica.Fluid.Types.ModelStructure.a_v_b, nNodes = 1, use_HeatTransfer = true, isCircular = false, p_a_start = P_start_2, p_b_start = P_start_2, crossArea = Modelica.Constants.pi*(0.474^2 - 0.215^2), perimeter = Modelica.Constants.pi*(0.948 + 0.430), roughness = 3.500000000000001e-05, T_start = T_start_2, m_flow_start = 0.25) annotation( Placement(transformation(origin = {-122, -50}, extent = {{-10, -10}, {10, 10}}))); Modelica.Fluid.Pipes.DynamicPipe pipe_1(redeclare package Medium = Medium, diameter = 0.1, length = 130e-3, modelStructure = Modelica.Fluid.Types.ModelStructure.a_v_b, nNodes = 1, use_HeatTransfer = true, p_a_start = P_start_2, p_b_start = P_start_2, isCircular = false, crossArea = Modelica.Constants.pi*(0.460^2 - 0.200^2), perimeter = Modelica.Constants.pi*(0.900 + 0.415), roughness = 3.500000000000001e-05, T_start = T_start_2, m_flow_start = 0.25) annotation( Placement(transformation(origin = {-162, -50}, extent = {{-10, -10}, {10, 10}}))); Modelica.Fluid.Sources.MassFlowSource_T outlet_1(redeclare package Medium = Medium, nPorts = 1, use_T_in = true, use_m_flow_in = true, m_flow = -0.25, T = 318.15) annotation( Placement(transformation(origin = {-88, -50}, extent = {{10, 10}, {-10, -10}}))); Modelica.Fluid.Sources.Boundary_pT inlet_1(redeclare package Medium = Medium, T = 328.15, nPorts = 1, use_T_in = false, use_p_in = false, p = 15300000) annotation( Placement(transformation(origin = {-256, -50}, extent = {{-10, -10}, {10, 10}}))); Modelica.Thermal.HeatTransfer.Sensors.TemperatureSensor temperatureSensor annotation( Placement(transformation(origin = {-44, -42}, extent = {{10, -10}, {-10, 10}}))); Modelica.Blocks.Sources.TimeTable flow_outlet_1(table = [0, -0.05; 116, -0.2475; 128, -0.2052; 136, -0.1647; 144, -0.1287; 152, -0.0972; 158, -0.0756; 164, -0.0549; 264, -0.01; 600, -0.01]) annotation( Placement(transformation(origin = {-44, -78}, extent = {{10, -10}, {-10, 10}}))); Modelica.Blocks.Sources.TimeTable Flow_outlet_2(table = [0, -0.05; 68, -0.15833333; 74, -0.14166667; 80, -0.12; 108, -0.033; 122, -0.01875; 136, -0.009; 144, -0.006; 164, -0.00083333; 524, -0.00083333; 530, -0.027; 534, -0.051; 538, -0.07575; 548, -0.11925; 558, -0.14625; 570, -0.168; 586, -0.1815; 600, -0.1875]) annotation( Placement(transformation(origin = {-36, 20}, extent = {{10, -10}, {-10, 10}}))); Modelica.Thermal.HeatTransfer.Sensors.TemperatureSensor temperatureSensor1 annotation( Placement(transformation(origin = {-44, 50}, extent = {{10, -10}, {-10, 10}}))); Modelica.Fluid.Pipes.StaticPipe pipe(length = 0.1, diameter = 0.1, redeclare package Medium = Medium, p_a_start = P_start_1, p_b_start = P_start_1) annotation( Placement(transformation(origin = {-210, 54}, extent = {{-10, -10}, {10, 10}}))); Modelica.Fluid.Pipes.StaticPipe pipe1(redeclare package Medium = Medium, diameter = 0.1, length = 0.1, p_a_start = P_start_1, p_b_start = P_start_1) annotation( Placement(transformation(origin = {-122, 54}, extent = {{-10, -10}, {10, 10}}))); equation connect(outlet_2.T_in, temperatureSensor1.T) annotation( Line(points = {{-70, 50}, {-54, 50}}, color = {0, 0, 127})); connect(pipe_3.heatPorts, wall_1.heatPort_b) annotation( Line(points = {{-162, 50}, {-162.5, 50}, {-162.5, 35}, {-162, 35}}, color = {127, 0, 0}, thickness = 0.5)); connect(wall_1.heatPort_a, convection_serpentin_1.solid) annotation( Line(points = {{-162, 25}, {-162, 16}}, color = {191, 0, 0}, thickness = 0.5)); connect(A_1.y, convection_serpentin_1.Gc) annotation( Line(points = {{-183, 6}, {-178, 6}}, color = {0, 0, 127}, thickness = 0.5)); connect(convection_serpentin_1.fluid, thermalCollector.port_a) annotation( Line(points = {{-162, -4}, {-162, -10}}, color = {191, 0, 0}, thickness = 0.5)); connect(thermalCollector.port_b, pipe_1.heatPorts[1]) annotation( Line(points = {{-162, -30}, {-162, -46}}, color = {191, 0, 0})); connect(outlet_2.m_flow_in, Flow_outlet_2.y) annotation( Line(points = {{-72, 46}, {-72, 20}, {-47, 20}}, color = {0, 0, 127})); connect(outlet_1.T_in, temperatureSensor.T) annotation( Line(points = {{-76, -54}, {-68, -54}, {-68, -42}, {-54, -42}}, color = {0, 0, 127})); connect(outlet_1.m_flow_in, flow_outlet_1.y) annotation( Line(points = {{-78, -58}, {-78, -79.5}, {-55, -79.5}, {-55, -78}}, color = {0, 0, 127})); connect(pipe_2.heatPorts[1], temperatureSensor.port) annotation( Line(points = {{-122, -46}, {-122, -25.6}, {-21.9, -25.6}, {-21.9, -42}, {-34, -42}}, color = {191, 0, 0})); connect(pipe_3.heatPorts[nNodes], temperatureSensor1.port) annotation( Line(points = {{-198, 50}, {-130, 50}, {-130, 76}, {32, 76}, {32, 50}, {16, 50}}, color = {191, 0, 0})); connect(inlet_1.ports[1], pipe_1.port_a) annotation( Line(points = {{-246, -50}, {-172, -50}}, color = {0, 127, 255})); connect(pipe_2.port_b, outlet_1.ports[1]) annotation( Line(points = {{-112, -50}, {-98, -50}}, color = {0, 127, 255})); connect(pipe_1.port_b, pipe_2.port_a) annotation( Line(points = {{-152, -50}, {-132, -50}}, color = {0, 127, 255})); connect(Inlet_2.ports[1], pipe.port_a) annotation( Line(points = {{-248, 54}, {-220, 54}}, color = {0, 127, 255})); connect(pipe.port_b, pipe_3.port_a) annotation( Line(points = {{-200, 54}, {-172, 54}}, color = {0, 127, 255})); connect(pipe_3.port_b, pipe1.port_a) annotation( Line(points = {{-152, 54}, {-132, 54}}, color = {0, 127, 255})); connect(pipe1.port_b, outlet_2.ports[1]) annotation( Line(points = {{-112, 54}, {-92, 54}}, color = {0, 127, 255})); algorithm annotation( uses(Modelica(version = "3.2.3")), Diagram(coordinateSystem(extent = {{-280, 80}, {-20, -100}}, initialScale = 0.1)), Icon(coordinateSystem(extent = {{-1000, -205}, {425, 100}})), version = ""); end Model; </code>
model Model
  import Modelica.Constants.pi;
  parameter Integer nNodes = 2;
  parameter Real d = 11e-3;
  parameter Real D = 18e-3;
  parameter Real P_start_1 = 10e+5;
  parameter Real P_start_2 = 153e+5;
  parameter Real T_start_1 = 55 + 273.15;
  parameter Real T_start_2 = 38 + 273.15;
  parameter Real S_conv_1 = 0.4;
  parameter Real S_conv_2 = 0.3;
  parameter Real he = 648;
  parameter Real h_conv_1 = 300;
  parameter Real h_conv_2 = 100;
  parameter Real L1 = 1400e-3;
  parameter Real L2 = 1300e-3;
  parameter Real k_conv_1 = h_conv_1*S_conv_1;
  parameter Real k_conv_2 = S_conv_2*h_conv_2;
  replaceable package Medium = Modelica.Media.Water.StandardWaterOnePhase constrainedby Modelica.Media.Interfaces.PartialMedium;
  replaceable model HeatTransfer_1 = Modelica.Fluid.Pipes.BaseClasses.HeatTransfer.ConstantFlowHeatTransfer(alpha0 = 5000);
  Modelica.Fluid.Sources.Boundary_pT Inlet_2(redeclare package Medium = Medium, T = 311.15, nPorts = 1, p = 1074000, use_T_in = false) annotation(
    Placement(transformation(origin = {-258, 54}, extent = {{-10, -10}, {10, 10}})));
  Modelica.Fluid.Pipes.DynamicPipe pipe_3(redeclare package Medium = Medium, redeclare final model HeatTransfer = HeatTransfer_1, diameter = d, length = L1, nNodes = nNodes, use_HeatTransfer = true, p_a_start = P_start_1, p_b_start = P_start_1, T_start = T_start_1, m_flow_start = 2.5) annotation(
    Placement(transformation(origin = {-162, 54}, extent = {{10, -10}, {-10, 10}}, rotation = -180)));
  inner Modelica.Fluid.System system(T_start(displayUnit = "degC"), m_flow_start = 0.05, energyDynamics = Modelica.Fluid.Types.Dynamics.FixedInitial, massDynamics = Modelica.Fluid.Types.Dynamics.FixedInitial) annotation(
    Placement(transformation(origin = {-258, -1}, extent = {{-12, -11}, {12, 11}})));
  Modelica.Fluid.Examples.HeatExchanger.BaseClasses.WallConstProps wall_1(area_h = 0.6, c_wall = 500, k_wall = 14.4, n = nNodes, rho_wall = 7850, s = 3.1e-3, T_start = 311.15, dT = 273.15) annotation(
    Placement(transformation(origin = {-162, 30}, extent = {{-10, -10}, {10, 10}}, rotation = 180)));
  Modelica.Fluid.Sources.MassFlowSource_T outlet_2(redeclare package Medium = Medium, T = 318.15, nPorts = 1, use_T_in = true, use_m_flow_in = true, m_flow = -0.208333333) annotation(
    Placement(transformation(origin = {-82, 54}, extent = {{10, 10}, {-10, -10}})));
  Modelica.Thermal.HeatTransfer.Components.Convection convection_serpentin_1[nNodes] annotation(
    Placement(transformation(origin = {-162, 6}, extent = {{-10, 10}, {10, -10}}, rotation = -90)));
  Modelica.Thermal.HeatTransfer.Components.ThermalCollector thermalCollector(m = nNodes) annotation(
    Placement(transformation(origin = {-162, -20}, extent = {{-10, -10}, {10, 10}})));
  Modelica.Blocks.Sources.Constant A_1[nNodes](each k = 50) annotation(
    Placement(transformation(origin = {-194, 6}, extent = {{-10, -10}, {10, 10}})));
  Modelica.Fluid.Pipes.DynamicPipe pipe_2(redeclare package Medium = Medium, diameter = 0.1, length = 130e-3, modelStructure = Modelica.Fluid.Types.ModelStructure.a_v_b, nNodes = 1, use_HeatTransfer = true, isCircular = false, p_a_start = P_start_2, p_b_start = P_start_2, crossArea = Modelica.Constants.pi*(0.474^2 - 0.215^2), perimeter = Modelica.Constants.pi*(0.948 + 0.430), roughness = 3.500000000000001e-05, T_start = T_start_2, m_flow_start = 0.25) annotation(
    Placement(transformation(origin = {-122, -50}, extent = {{-10, -10}, {10, 10}})));
  Modelica.Fluid.Pipes.DynamicPipe pipe_1(redeclare package Medium = Medium, diameter = 0.1, length = 130e-3, modelStructure = Modelica.Fluid.Types.ModelStructure.a_v_b, nNodes = 1, use_HeatTransfer = true, p_a_start = P_start_2, p_b_start = P_start_2, isCircular = false, crossArea = Modelica.Constants.pi*(0.460^2 - 0.200^2), perimeter = Modelica.Constants.pi*(0.900 + 0.415), roughness = 3.500000000000001e-05, T_start = T_start_2, m_flow_start = 0.25) annotation(
    Placement(transformation(origin = {-162, -50}, extent = {{-10, -10}, {10, 10}})));
  Modelica.Fluid.Sources.MassFlowSource_T outlet_1(redeclare package Medium = Medium, nPorts = 1, use_T_in = true, use_m_flow_in = true, m_flow = -0.25, T = 318.15) annotation(
    Placement(transformation(origin = {-88, -50}, extent = {{10, 10}, {-10, -10}})));
  Modelica.Fluid.Sources.Boundary_pT inlet_1(redeclare package Medium = Medium, T = 328.15, nPorts = 1, use_T_in = false, use_p_in = false, p = 15300000) annotation(
    Placement(transformation(origin = {-256, -50}, extent = {{-10, -10}, {10, 10}})));
  Modelica.Thermal.HeatTransfer.Sensors.TemperatureSensor temperatureSensor annotation(
    Placement(transformation(origin = {-44, -42}, extent = {{10, -10}, {-10, 10}})));
  Modelica.Blocks.Sources.TimeTable flow_outlet_1(table = [0, -0.05; 116, -0.2475; 128, -0.2052; 136, -0.1647; 144, -0.1287; 152, -0.0972; 158, -0.0756; 164, -0.0549; 264, -0.01; 600, -0.01]) annotation(
    Placement(transformation(origin = {-44, -78}, extent = {{10, -10}, {-10, 10}})));
  Modelica.Blocks.Sources.TimeTable Flow_outlet_2(table = [0, -0.05; 68, -0.15833333; 74, -0.14166667; 80, -0.12; 108, -0.033; 122, -0.01875; 136, -0.009; 144, -0.006; 164, -0.00083333; 524, -0.00083333; 530, -0.027; 534, -0.051; 538, -0.07575; 548, -0.11925; 558, -0.14625; 570, -0.168; 586, -0.1815; 600, -0.1875]) annotation(
    Placement(transformation(origin = {-36, 20}, extent = {{10, -10}, {-10, 10}})));
  Modelica.Thermal.HeatTransfer.Sensors.TemperatureSensor temperatureSensor1 annotation(
    Placement(transformation(origin = {-44, 50}, extent = {{10, -10}, {-10, 10}})));
  Modelica.Fluid.Pipes.StaticPipe pipe(length = 0.1, diameter = 0.1, redeclare package Medium = Medium, p_a_start = P_start_1, p_b_start = P_start_1)  annotation(
    Placement(transformation(origin = {-210, 54}, extent = {{-10, -10}, {10, 10}})));
  Modelica.Fluid.Pipes.StaticPipe pipe1(redeclare package Medium = Medium, diameter = 0.1, length = 0.1, p_a_start = P_start_1, p_b_start = P_start_1) annotation(
    Placement(transformation(origin = {-122, 54}, extent = {{-10, -10}, {10, 10}})));
equation
  connect(outlet_2.T_in, temperatureSensor1.T) annotation(
    Line(points = {{-70, 50}, {-54, 50}}, color = {0, 0, 127}));
  connect(pipe_3.heatPorts, wall_1.heatPort_b) annotation(
    Line(points = {{-162, 50}, {-162.5, 50}, {-162.5, 35}, {-162, 35}}, color = {127, 0, 0}, thickness = 0.5));
  connect(wall_1.heatPort_a, convection_serpentin_1.solid) annotation(
    Line(points = {{-162, 25}, {-162, 16}}, color = {191, 0, 0}, thickness = 0.5));
  connect(A_1.y, convection_serpentin_1.Gc) annotation(
    Line(points = {{-183, 6}, {-178, 6}}, color = {0, 0, 127}, thickness = 0.5));
  connect(convection_serpentin_1.fluid, thermalCollector.port_a) annotation(
    Line(points = {{-162, -4}, {-162, -10}}, color = {191, 0, 0}, thickness = 0.5));
  connect(thermalCollector.port_b, pipe_1.heatPorts[1]) annotation(
    Line(points = {{-162, -30}, {-162, -46}}, color = {191, 0, 0}));
  connect(outlet_2.m_flow_in, Flow_outlet_2.y) annotation(
    Line(points = {{-72, 46}, {-72, 20}, {-47, 20}}, color = {0, 0, 127}));
  connect(outlet_1.T_in, temperatureSensor.T) annotation(
    Line(points = {{-76, -54}, {-68, -54}, {-68, -42}, {-54, -42}}, color = {0, 0, 127}));
  connect(outlet_1.m_flow_in, flow_outlet_1.y) annotation(
    Line(points = {{-78, -58}, {-78, -79.5}, {-55, -79.5}, {-55, -78}}, color = {0, 0, 127}));
  connect(pipe_2.heatPorts[1], temperatureSensor.port) annotation(
    Line(points = {{-122, -46}, {-122, -25.6}, {-21.9, -25.6}, {-21.9, -42}, {-34, -42}}, color = {191, 0, 0}));
  connect(pipe_3.heatPorts[nNodes], temperatureSensor1.port) annotation(
    Line(points = {{-198, 50}, {-130, 50}, {-130, 76}, {32, 76}, {32, 50}, {16, 50}}, color = {191, 0, 0}));
  connect(inlet_1.ports[1], pipe_1.port_a) annotation(
    Line(points = {{-246, -50}, {-172, -50}}, color = {0, 127, 255}));
  connect(pipe_2.port_b, outlet_1.ports[1]) annotation(
    Line(points = {{-112, -50}, {-98, -50}}, color = {0, 127, 255}));
  connect(pipe_1.port_b, pipe_2.port_a) annotation(
    Line(points = {{-152, -50}, {-132, -50}}, color = {0, 127, 255}));
  connect(Inlet_2.ports[1], pipe.port_a) annotation(
    Line(points = {{-248, 54}, {-220, 54}}, color = {0, 127, 255}));
  connect(pipe.port_b, pipe_3.port_a) annotation(
    Line(points = {{-200, 54}, {-172, 54}}, color = {0, 127, 255}));
  connect(pipe_3.port_b, pipe1.port_a) annotation(
    Line(points = {{-152, 54}, {-132, 54}}, color = {0, 127, 255}));
  connect(pipe1.port_b, outlet_2.ports[1]) annotation(
    Line(points = {{-112, 54}, {-92, 54}}, color = {0, 127, 255}));
algorithm

  annotation(
    uses(Modelica(version = "3.2.3")),
    Diagram(coordinateSystem(extent = {{-280, 80}, {-20, -100}}, initialScale = 0.1)),
    Icon(coordinateSystem(extent = {{-1000, -205}, {425, 100}})),
    version = "");
end Model;

Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa Dịch vụ tổ chức sự kiện 5 sao Thông tin về chúng tôi Dịch vụ sinh nhật bé trai Dịch vụ sinh nhật bé gái Sự kiện trọn gói Các tiết mục giải trí Dịch vụ bổ trợ Tiệc cưới sang trọng Dịch vụ khai trương Tư vấn tổ chức sự kiện Hình ảnh sự kiện Cập nhật tin tức Liên hệ ngay Thuê chú hề chuyên nghiệp Tiệc tất niên cho công ty Trang trí tiệc cuối năm Tiệc tất niên độc đáo Sinh nhật bé Hải Đăng Sinh nhật đáng yêu bé Khánh Vân Sinh nhật sang trọng Bích Ngân Tiệc sinh nhật bé Thanh Trang Dịch vụ ông già Noel Xiếc thú vui nhộn Biểu diễn xiếc quay đĩa Dịch vụ tổ chức tiệc uy tín Khám phá dịch vụ của chúng tôi Tiệc sinh nhật cho bé trai Trang trí tiệc cho bé gái Gói sự kiện chuyên nghiệp Chương trình giải trí hấp dẫn Dịch vụ hỗ trợ sự kiện Trang trí tiệc cưới đẹp Khởi đầu thành công với khai trương Chuyên gia tư vấn sự kiện Xem ảnh các sự kiện đẹp Tin mới về sự kiện Kết nối với đội ngũ chuyên gia Chú hề vui nhộn cho tiệc sinh nhật Ý tưởng tiệc cuối năm Tất niên độc đáo Trang trí tiệc hiện đại Tổ chức sinh nhật cho Hải Đăng Sinh nhật độc quyền Khánh Vân Phong cách tiệc Bích Ngân Trang trí tiệc bé Thanh Trang Thuê dịch vụ ông già Noel chuyên nghiệp Xem xiếc khỉ đặc sắc Xiếc quay đĩa thú vị
Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa
Thiết kế website Thiết kế website Thiết kế website Cách kháng tài khoản quảng cáo Mua bán Fanpage Facebook Dịch vụ SEO Tổ chức sinh nhật