150 likes | 273 Views
Formalizing Material Flow Diagrams. Robert-Jan Bijl. Introduction. The Falcon Project Vanderlande Industries Embedded Systems Institute Material Flow Diagrams ‘building plans’ for distribution centers give an idea of the material flow through setup purely pictures, mostly in Visio.
E N D
Formalizing Material Flow Diagrams Robert-Jan Bijl
Introduction • The Falcon Project • Vanderlande Industries • Embedded Systems Institute • Material Flow Diagrams • ‘building plans’ for distribution centers • give an idea of the material flow through setup • purely pictures, mostly in Visio
Project Goals • Formalize MFD’s to give them a central role in development process • create a meta-model • create tooling • derive artifacts from the created models • Get insight in the involved processes • design of meta-models • evolution of meta-models (when already in use) • creation/availability of tooling
The Final Idea General Hierarchy Pattern Abstract from unit type Abstract from positional information Introduce connections as part of the MFD Allow different libraries for different domains
The Final Idea (cnt’d) / Department of Mathematics and Computer Science
Libraries • Contain information about the building blocks of an MFD • unit types • connector types • constraints • Merging a library with the abstract meta-model results in an instantiated meta-model, aimed at a (more) specific domain
Libraries (cnt’d) / Department of Mathematics and Computer Science
‘Instantiated’ Meta-Model / Department of Mathematics and Computer Science
Validation • Formal models can be checked for correctness, consistency and other properties • Using ‘Check’, a language to specify constraints that the model has to fulfill in order to be correct • context MFD ERROR "The MFD must have valid MId and MName": • this.MName != null && this.MName != '' && this.MId != null && this.MId != ''; • context MFD ERROR "Every component must have a unique CId (no distinction in caps)": • let s = getAllComponents(this): s.forAll(s1 | !s.exists(s2|(s1 != s2) && (s1.CId.toLowerCase() == s2.CId.toLowerCase())));
Transformations • Transforming a model conforming to meta-model A to a model conforming the meta-model B • Atlas Transformation Language, ATL rule createRoot{ from a : MM!MFD to p : MM1!Planner( PName <- 'Planner' + a.MName, PId <- 'P' + a.MId ) }
Code Generation • From a formal model we can generate all sorts of artifacts, e.g. source code • Using ‘Xpand’, a statically-typed template language, part of the Eclipse M2T-project «DEFINE main FOR Planner» «LET removeSpace(PName) AS name» «FILE name + “.dot”» digraph «name» { «EXPAND createNode FOR firstNode()» «EXPAND createNodeLinks FOR firstNode()» } «ENDFILE» «ENDLET» «ENDDEFINE»
Further Steps Generate a graphical editor (using GMF), look into automating this Research into (co-)evolution of models en meta-models Generation of High Level Controller Software with techniques as described earlier Typing, typing, typing