Why Hypermesh completely built using TCL? why not Python
Hi, admins & staff !
Why Hypermesh completely built using TCL? If they built using python, people will get lot of help for CAE automation. why they choose TCL?
Can we expect Hypermesh based on Python in future? /emoticons/default_rolleyes.gif' title=':rolleyes:' />
have a nice day!
thank you
Answers
-
TCL & Python are both good programming languages. So why not TCL?
If you like Python, go for Simulia Abaqus /emoticons/default_tongue.png' srcset='/emoticons/tongue@2x.png 2x' title=':P' width='20' />
0 -
Because it needs many GUI objects (browsers, menus, dialogs,...) . Can python provide them? I think yes, via tkinter - an instance of Tk! So they use Tk directly, it is easier, isn't it?
0 -
I don't like this 'Programming-Language-War' subject /emoticons/default_tongue.png' srcset='/emoticons/tongue@2x.png 2x' title=':P' width='20' />
0 -
TCL was there when Hypermesh initial development started, Python was released later.
0 -
Why Python over TCL? Because people know Python and not TCL.
Googling 'programming languages by popularity' gives you the following
Python: #2
TCL: Didn't make it to top 20
https://www.tiobe.com/tiobe-index/
Python: #3
TCL: Didn't make it to top 20
http://pypl.github.io/PYPL.html
Python: #1
TCL: Didn't make it to top 23
Python: #3
TCL: Didn't make it to top 10
https://raygun.com/blog/programming-languages/
Python: #3
TCL: Didn't make it to top 43
https://www.devsaran.com/blog/10-best-programming-languages-2019-you-should-know
Python: #1
TCL: #18
Even if TCL has a slight advantage over Python (I am not claiming it has), is it really worth using as language people don't know?
0 -
Viva TCL!
Viva Hypermesh!
0 -
/emoticons/default_biggrin.png' srcset='/emoticons/biggrin@2x.png 2x' title=':D' width='20' /> more people will want to know Tcl because they know hypermesh now!
Tcl is small, so write everything by python, and call py.exe from tcl simply.
0 -
Altair Forum User said:
/emoticons/default_biggrin.png' srcset='/emoticons/biggrin@2x.png 2x' title=':D' width='20' /> more people will want to know Tcl because they know hypermesh now!
Tcl is small, so write everything by python, and call py.exe from tcl simply.
could you post an example of this procedure, please? or any relevant material on the subject
0 -
This package will embed a python interp into tcl
0 -
I use both Python(for Simlab customization) and TCL(for HyperMesh).
In my opinion, Python is helpful for data management with OOP (of course it will be faster) and the syntax is easier than TCL.
However, HyperMesh have supported many TCL API to interact with HM. We can use a lot of those API functions easily, no need to create our code again. This helps create script very quickly.
Integrate Python in HyperMesh is easy but write a huge API functions need a lot of effort.
I use Simlab Python but found many limitation because there are not so much API functions.
I use Abaqus/Ansys Python but also found many limitation.
So, Python or TCL does not matter. The important is supported API functions under CAE software.
HW will support Python because they serve some trend.
For me, I do not need. I need API more than Python.
0 -
The new release Hyperworks 2020 is shipped with Python 3.5 for new GUI Hyperworks-X.
But for macro programming, I think we still work with Tcl/Tk
0 -
as described above, all the APIs for HM and HV are written in TCL.
Although Python is the most popular language nowadays, it is very hard to change from one language to another, as you would need to rewrite everything in a new language. It will probably occur only in a completely new HyperWorks environment.
And it is correct: HWx new interfaces will be coming built on Python, but the core is still TCL.
2 -
tinh said:
/emoticons/default_biggrin.png' srcset='/emoticons/biggrin@2x.png 2x' title=':D' width='20' /> more people will want to know Tcl because they know hypermesh now!
Tcl is small, so write everything by python, and call py.exe from tcl simply.
Could you provide more detail to this please? I am actually trying to call Hyperworks from Python (Running the TCL macros from python), this seems like what I need! Do you have some documentation regarding this ? Thank you!
0 -
tinh said:
/emoticons/default_biggrin.png' srcset='/emoticons/biggrin@2x.png 2x' title=':D' width='20' /> more people will want to know Tcl because they know hypermesh now!
Tcl is small, so write everything by python, and call py.exe from tcl simply.
Dear Tinh.
Could you please give more details about this py.exe? I want to run the tcl macro in HyperMesh directly from python. I tried using the tk call function but it did not work.
Let me know,
Cheers
Sanaa
0