- Index
- » Usage and Applications
- » OpenModelica Usage and Applications
- » Simulation Failure OMEdit
Simulation Failure OMEdit
Simulation Failure OMEdit
I was trying to simulate a simple fluids model that i built up with OMEdit
The Simulation-Output-window says that the Simulation process failed and the grid shows no results. Why does that happen?
Here's my sourcecode:
model Test_Abfueller
Modelica.Fluid.Vessels.OpenTank tank(redeclare package Medium = Modelica.Media.CompressibleLiquids.LinearColdWater, crossArea = 1, height = 1, level_start = 23, nPorts = 1) annotation(
Placement(visible = true, transformation(origin = {62, 4}, extent = {{-20, -20}, {20, 20}}, rotation = 0)));
Modelica.Fluid.Pipes.StaticPipe pipe(redeclare package Medium = Modelica.Media.CompressibleLiquids.LinearColdWater, diameter = 0.05, length = 1) annotation(
Placement(visible = true, transformation(origin = {-30, -28}, extent = {{-10, -10}, {10, 10}}, rotation = 0)));
inner Modelica.Fluid.System system annotation(
Placement(visible = true, transformation(origin = {-70, 70}, extent = {{-10, -10}, {10, 10}}, rotation = 0)));
Modelica.Fluid.Sources.Boundary_pT boundary(redeclare package Medium = Modelica.Media.CompressibleLiquids.LinearColdWater, T = 278, nPorts = 1, p = 600000) annotation(
Placement(visible = true, transformation(origin = {-92, -28}, extent = {{-10, -10}, {10, 10}}, rotation = 0)));
equation
connect(pipe.port_b, tank.ports[1]) annotation(
Line(points = {{-20, -28}, {28, -28}, {28, -46}, {62, -46}, {62, -16}}, color = {0, 127, 255}));
connect(boundary.ports[1], pipe.port_a) annotation(
Line(points = {{-82, -28}, {-40, -28}, {-40, -28}, {-40, -28}}, color = {0, 127, 255}, thickness = 0.5));
annotation(
uses(Modelica(version = "3.2.2")));
end Test_Abfueller;
I hope someone can help me with this. I'd appreciate any help.
- lwinklmann
- 17 Posts
Re: Simulation Failure OMEdit
Hallo,
Below issues found in Initializing parameters for the tank:
- <Height> of the tank (1m) cannot be lower than the <level_start> (23m) which you defined. please Switch the values for these variables ie, <Height>=23m, <level_start> =1m
- You opted <true> for portdata and forgot to define its data below. Port data is used when pressure loss calculation across the ports of tank needed to be included. I suggest you to opt portdata <false> and leave blank the portdata section below.
Your simulation fails after 239 secs which logically proves the condition of overflow in tank.
Best Regards
Joel
Re: Simulation Failure OMEdit
Hello,
thanks for the quick answer! Now it works, thank you!
best regards,
lwinklmann
- lwinklmann
- 17 Posts
- Index
- » Usage and Applications
- » OpenModelica Usage and Applications
- » Simulation Failure OMEdit