Skip to content
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

Tick off "Investigate need for 'final'" #2994

Merged
merged 2 commits into from
Oct 2, 2021

Conversation

henrikt-ma
Copy link
Collaborator

@henrikt-ma henrikt-ma commented Sep 7, 2021

According to today's web meeting, I'm setting up this PR for documenting why we're ticking off this item on the road map.

All occurrences of final in the https://github.com/modelica/ModelicaSpecification/blob/MCP/0031%2Beliminate-final/RationaleMCP/0031/grammar.md, and things that have made this possible include:

  • Flat Modelica describes a state of affairs where all checking for modifications that violate final should have taken place during reduction from full Modelica to Flat Modelica.
  • One thing one cannot check during reduction to Flat Modelica is that a final modification of start in full Modelica won't be modified at the time of simulation initialization. For this we needed something else in Flat Modelica, and we now instead have the new parameter equations that allows expressing that something can be modified at the time of initialization. That is, to express that the original Full Modelica modification of start was final, one should simply use a normal initial equation instead of a parameter equation.

Borrowing examples from https://github.com/modelica/ModelicaSpecification/blob/MCP/0031%2Beliminate-final/RationaleMCP/0031/differences.md:

  Real 'x';
  parameter equation guess('x') = 1.5; /* Coming from Full Modelica non-final modification of 'start'. */
  Real 'y';
initial equation
  guess('y') - 1.5 = 0; /* Coming from Full Modelica final modification of 'start'. */

Comments explaining why we can tick off this item at this time will be given in the PR for merging this.
@henrikt-ma henrikt-ma added the MCP0031 Base Modelica and MLS modularization (MCP-0031) label Sep 7, 2021
@olivleno
Copy link
Collaborator

olivleno commented Oct 1, 2021

Web Meeting: (Hans, Martin, Gerd, Kai, Henrik, Oliver)
approved

@henrikt-ma henrikt-ma merged commit a2fd60d into MCP/0031 Oct 2, 2021
@henrikt-ma henrikt-ma deleted the MCP/0031+eliminate-final branch October 2, 2021 20:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
MCP0031 Base Modelica and MLS modularization (MCP-0031)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants