Comments (1)
My mistake.
Pressure was not set properly in ramp1
Model is correct this way:
block PipeExternalCO2
extends Tests;
replaceable package Medium = Media.CO2;
Modelica.Blocks.Sources.Ramp ramp1(
duration=0,
startTime=0.5,
height=50000,
offset=system.p_ambient)
annotation (Placement(transformation(extent={{-40,70},{-20,90}})));
Modelica.Fluid.Sources.Boundary_pT boundary4(
nPorts=1,
redeclare package Medium = Medium,
use_p_in=true,
use_T_in=false,
p=system.p_ambient,
T=system.T_ambient) annotation (Placement(
transformation(extent={{10,-10},{-10,10}}, rotation=90,
origin={0,60})));
inner Modelica.Fluid.System system(
energyDynamics=Modelica.Fluid.Types.Dynamics.SteadyStateInitial,
momentumDynamics=Modelica.Fluid.Types.Dynamics.SteadyStateInitial,
p_ambient=9000000,
T_ambient=373.15)
annotation (Placement(transformation(extent={{-90,70},{-70,90}})));
Modelica.Fluid.Pipes.DynamicPipe pipe4(
use_T_start=true,
nNodes=1,
diameter=2.54e-2,
m_flow_start=0.02,
height_ab=50,
length=50,
p_a_start=system.p_ambient+200000,
p_b_start=system.p_ambient,
modelStructure=Modelica.Fluid.Types.ModelStructure.a_v_b,
redeclare package Medium = Medium (singleState=false)) annotation (
Placement(transformation(
extent={{-10,-10},{10,10}},
rotation=90,
origin={0,-12})));
Modelica.Fluid.Sources.Boundary_pT boundary1(
nPorts=1,
redeclare package Medium = Medium,
p=system.p_ambient+500000,
T=system.T_ambient) annotation (Placement(
transformation(extent={{-10,-10},{10,10}}, rotation=90,
origin={0,-80})));
equation
connect(ramp1.y, boundary4.p_in) annotation (Line(points={{-19,80},{-14,80},{-14,
72},{-8,72}}, color={0,0,127}));
connect(boundary4.ports[1], pipe4.port_b)
annotation (Line(points={{0,50},{0,-2},{4.44089e-16,-2}},
color={0,127,255}));
connect(pipe4.port_a, boundary1.ports[1])
annotation (Line(points={{-6.66134e-16,-22},{-6.66134e-16,-30},{0,-30},{0,-70}},
color={0,127,255}));
end PipeExternalCO2;
from externalmedia.
Related Issues (20)
- Incompressible package runs in OpenModelica but not Dymola
- Model fails to execute when using two different fluids
- Model fails to run when using Modelica.Fluid.Sensors.Temperature
- Call ExternalMedia from OMPython HOT 1
- External function could not be found in any of the given shared libraries HOT 1
- External functions in ExternalMedia should be explicitly declared as pure
- Use CoolProp 6.4.4 as soon as it is released, instead of nightly build HOT 1
- support for older gcc versions HOT 4
- Compilation errors in OpenModelica HOT 7
- Selection of different state variables (ph, pt, dT) for a CoolProp 2-phase medium HOT 1
- Cannot compute arbitrary partial derivatives with function `partialDeriv_state` HOT 2
- Wrong version of cmake required to compile the library HOT 1
- Restructuring of the repository HOT 4
- build error using cmake on windows HOT 1
- State functions do not seem to work properly HOT 6
- Compressible mixture support? HOT 2
- Custom fluid property support
- Incompressible CoolProp tests do not compile HOT 3
- Remove experiment annotation from partial models
- how to use fliudprop in external Media?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from externalmedia.