FrontWay PaperFront to OpenModelica Translator
Many companies in the domain of modeling and simulation are showing interest in the new emerging OpenModelica, an object oriented modeling and simulation platform based on Modelica language. The purpose of this thesis is to study if and how simulation libraries written in ExtendSim such as PaperFron...
Main Authors: | , |
---|---|
Format: | Others |
Language: | English |
Published: |
Linköpings universitet, PELAB - Laboratoriet för programmeringsomgivningar
2011
|
Subjects: | |
Online Access: | http://urn.kb.se/resolve?urn=urn:nbn:se:liu:diva-72085 |
id |
ndltd-UPSALLA1-oai-DiVA.org-liu-72085 |
---|---|
record_format |
oai_dc |
spelling |
ndltd-UPSALLA1-oai-DiVA.org-liu-720852018-01-13T05:16:19ZFrontWay PaperFront to OpenModelica TranslatorengHalim, RoohulShaharyar, Syed AtifLinköpings universitet, PELAB - Laboratoriet för programmeringsomgivningarLinköpings universitet, PELAB - Laboratoriet för programmeringsomgivningar2011OpenModelicaExtendSimTranslatorANTLRASTStringTemplateParserSoftware EngineeringProgramvaruteknikMany companies in the domain of modeling and simulation are showing interest in the new emerging OpenModelica, an object oriented modeling and simulation platform based on Modelica language. The purpose of this thesis is to study if and how simulation libraries written in ExtendSim such as PaperFront, can be semi-automatically converted to equivalent Modelica libraries. The ExtendSim tool is based upon a C like language called ModL that is used for designing models. A prototype translator is developed for translating ModL to Modelica. One difficulty that had to be overcome was the fact that ExtendSim is a commercial tool which hides part of its model information in a binary format. The generated code from prototype translator can be viewed using any text editor or using the textual view of Modelica graphical editors such as OMEdit or Dymola. The implementation of the prototype translator is done using the Java based ANTLR tool, which generates a parser and a lexer from the defined grammar rules. Moreover, a set of templates is written using the StringTemplate language for the code generation. The prototype translator takes ModL code of an ExtendSim library file and generates an Abstract Syntax Tree (AST), which is then converted to an equivalent Modelica AST. This Modelica AST is later converted to textual Modelica code. Subject to limited resource availability and time constraints of the thesis work, the basic constructs of ModL language are supported by the translator e.g. data types, if-else statements, loops, procedures etc. The enhancements in the translator can be made in the future by adding support for remaining language features such as support for tracing and additional ModL built-in functions etc. Student thesisinfo:eu-repo/semantics/bachelorThesistexthttp://urn.kb.se/resolve?urn=urn:nbn:se:liu:diva-72085application/pdfinfo:eu-repo/semantics/openAccess |
collection |
NDLTD |
language |
English |
format |
Others
|
sources |
NDLTD |
topic |
OpenModelica ExtendSim Translator ANTLR AST StringTemplate Parser Software Engineering Programvaruteknik |
spellingShingle |
OpenModelica ExtendSim Translator ANTLR AST StringTemplate Parser Software Engineering Programvaruteknik Halim, Roohul Shaharyar, Syed Atif FrontWay PaperFront to OpenModelica Translator |
description |
Many companies in the domain of modeling and simulation are showing interest in the new emerging OpenModelica, an object oriented modeling and simulation platform based on Modelica language. The purpose of this thesis is to study if and how simulation libraries written in ExtendSim such as PaperFront, can be semi-automatically converted to equivalent Modelica libraries. The ExtendSim tool is based upon a C like language called ModL that is used for designing models. A prototype translator is developed for translating ModL to Modelica. One difficulty that had to be overcome was the fact that ExtendSim is a commercial tool which hides part of its model information in a binary format. The generated code from prototype translator can be viewed using any text editor or using the textual view of Modelica graphical editors such as OMEdit or Dymola. The implementation of the prototype translator is done using the Java based ANTLR tool, which generates a parser and a lexer from the defined grammar rules. Moreover, a set of templates is written using the StringTemplate language for the code generation. The prototype translator takes ModL code of an ExtendSim library file and generates an Abstract Syntax Tree (AST), which is then converted to an equivalent Modelica AST. This Modelica AST is later converted to textual Modelica code. Subject to limited resource availability and time constraints of the thesis work, the basic constructs of ModL language are supported by the translator e.g. data types, if-else statements, loops, procedures etc. The enhancements in the translator can be made in the future by adding support for remaining language features such as support for tracing and additional ModL built-in functions etc. |
author |
Halim, Roohul Shaharyar, Syed Atif |
author_facet |
Halim, Roohul Shaharyar, Syed Atif |
author_sort |
Halim, Roohul |
title |
FrontWay PaperFront to OpenModelica Translator |
title_short |
FrontWay PaperFront to OpenModelica Translator |
title_full |
FrontWay PaperFront to OpenModelica Translator |
title_fullStr |
FrontWay PaperFront to OpenModelica Translator |
title_full_unstemmed |
FrontWay PaperFront to OpenModelica Translator |
title_sort |
frontway paperfront to openmodelica translator |
publisher |
Linköpings universitet, PELAB - Laboratoriet för programmeringsomgivningar |
publishDate |
2011 |
url |
http://urn.kb.se/resolve?urn=urn:nbn:se:liu:diva-72085 |
work_keys_str_mv |
AT halimroohul frontwaypaperfronttoopenmodelicatranslator AT shaharyarsyedatif frontwaypaperfronttoopenmodelicatranslator |
_version_ |
1718608967771357184 |