The modeling tool that I have developed over the past couple of years is written in C ++ and currently has a tcl interface that is interpreted as front-end. It was written so that it can be run either in an interactive shell or by transferring an input file. In any case, the input file is written to tcl (with many additional modeling commands that I added). This allows you to use quite powerful input files (for example, when you run sim-sim-carlo sims, random distributions can be programmed as tcl-procedures directly in the input file).
Unfortunately, I find that the tcl interpreter is becoming somewhat limited compared to what more modern interpreted languages ββcan offer, and its syntax seems a bit cryptic. Since the computing engine was written as a library with a c-compatible API, it should just write alternative interfaces, and I am thinking about moving to a new interpreter, however I have a little time choosing (mainly because I do not have much experience working with many interpreted languages). The options I started exploring are as follows:
Left with tcl:
Pros:
- No need to change existing code.
- Existing input files remain unchanged. (although I would probably keep the front of tcl as an option)
- Mature language with lots of community support.
Minuses:
- A sense of limited syntax of the language.
- Receiving complaints from users about the difficulty of learning tcl.
Python:
Pros:
- A modern translator, which, as you know, is quite effective.
- A large, active community.
- Well-known scientific and mathematical modules such as scipy.
- Commonly used in the academic scientific / engineering community (typical users of my code)
Minuses:
- I never used it, and therefore it will take time to learn the language (this is also a professional, since I have long wanted to learn python)
- Strict formatting of input files (indentation, etc.)
Matlab:
Pros:
- A very powerful and widely used math tool
- Powerful integrated visualization / printing.
- Extensible, through community-transmitted code, as well as commercial toolbars.
- Many in science / engineering are familiar with MATLAB and are comfortable with them. Minuses:
- Cannot be distributed as an executable file - there must be an extension / toolkit.
- Requires (?) The matlab compiler (which is expensive).
- Requires Matlab, which is also expensive.
These pros and cons are what I could come up with, although I have very little experience with interpreted languages ββin general. I would like to hear any thoughts on all the interpreters that I suggested here, if these pros and cons are listed legit, and any other interpreters that I did not think about (for example, if php were suitable for something like this? Lua?). The initial experience of implementing an interpreter in your code is definitely a plus!
c ++ python matlab tcl interpreter
Markd
source share