1

For the model of a heat generating device, I want to have the optional possibility to extract the heat via a fluid flow. This is related to question "conditional component declaration and a following if equation". In my code the model is derived from Modelica.Fluid.Interfaces.PartialTwoPortTransport. I have written an equivalent partial class having conditional fluidport connectors using the 'internalize équation' méthode. Now I must add two equations like:

port_b.h_outflow *m_flow=inStream(port_a.h_outflow)*m_flow+prescribedTemperature.port.Q_flow;

It can be internalized with a division by m_flow, but if I do that it will lose the ability to detect that Q_flow=0.

What other approach can work?

Community
  • 1
  • 1
user3806
  • 19
  • 4
  • Please format your question! – Stefan Falk Jun 29 '15 at 16:36
  • As far as Modelica Language Standard 3.3 is concerned, it seems to me that stream connectors and conditional components are two features which have been developed independently and do not play nicely together. I have done exactly like you to have the possibility to extract heat using a fluid flow through the air gap of an electric motor model. This is intended as a configurable model feature, because the basic motor function must be usable without having to add fluid circuit components. – user3806 Jun 07 '16 at 22:45

0 Answers0