-
Notifications
You must be signed in to change notification settings - Fork 41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Equations with connectors #2235
Comments
Comment by hansolsson on 28 Feb 2018 10:39 UTC
I will need to investigate this more, but these are preliminary answers:
For non-expandable connectors there are two cases:
For expandable connectors I do see major problem. The reason is that they are expandable and thus may get additional contents. But this non-connect equation is not considered for the elaboration, meaning that other connections might make the sides unequal. Additionally it seems this introduces an equation for potentially present variables - which contradicts the idea in 9.1.3 of not referring to them.
Interesting point. For c1 and c2 one would assume that 'a' and 'b' get causality due to other connections (as specified), and thus there is no problem - and if there is no connection to 'a' and 'b' they are removed, and thus no problem. (Looking more this is specified in 9.1.3.) Thus it is only a problem for expandable connector classes, not expandable connector components, and this restriction should be lifted for expandable connector (classes).
Continuing from above. |
Comment by kurzbach on 28 Feb 2018 11:52 UTC
Yes, in this case the connector components get causality from other connectors via connect statements. |
Comment by hansolsson on 22 Mar 2018 13:20 UTC 9.3.1 should say that expandable connectors are excluded from this restriction, since the elements are only constraints. |
Comment by eshmoylova on 22 Mar 2018 14:27 UTC The sentence in bold implies that the variables inside expandable connectors can be used in non-connect equations. There is even a test for that in the Modelica Compliance library: There are three more models that use potential variables in other expressions but they all should not pass (for different reasons). The quoted paragraph and the models in the Compliance library would need to be update to reflect the new restriction. |
I don't see that we considered that restriction for expandable connector in that detail, and thus I didn't add it to the PR yet. I also noticed that the overall description of allowed expressions was unclear so I tried to add that. |
Reported by kurzbach on 28 Feb 2018 09:36 UTC
In a library of a customer following construct is used:
There are following questions:
Migrated-From: https://trac.modelica.org/Modelica/ticket/2235
The text was updated successfully, but these errors were encountered: