I didn’t go through this entire thread. I jumped from here. Just to clarify some related issue about map accessing. The linked post uses Python code injection for map key retrieval, which has been removed during the big merge for obvious security reason. The current expression parser supports similar list/slice/map accessing syntax as Python. And it accepts expression as index or key. For example, the code in the linked post can be changed to (assuming ‘Density’ is a property of the current object)
Panel014.Material.Material[.Density]
It can even be shortened to the following with some small modification to the ‘Material’ property (I don’t know what type exactly), similar to the modification here to sketch’s PropertyConstraintList.
done. compiles on Debian Buster with Py3, but on startup …
hugo@Ahorn:~/Documents/dev/freecad/freecadbhb_dev/build$
hugo@Ahorn:~/Documents/dev/freecad/freecadbhb_dev/build$ ./bin/FreeCAD
Program received signal SIGSEGV, Segmentation fault.
#0 /lib/x86_64-linux-gnu/libc.so.6(+0x37840) [0x7f076e0e0840]
#1 /lib/x86_64-linux-gnu/libpython3.7m.so.1.0(PyTuple_New+0xf7) [0x7f0770969fb7]
#2 /lib/x86_64-linux-gnu/libpython3.7m.so.1.0(PyType_Ready+0x1ab2) [0x7f07707cab62]
#3 /lib/x86_64-linux-gnu/libpython3.7m.so.1.0(PyType_Ready+0x1ee8) [0x7f07707caf98]
#4 0x7f0771367f6e in Py::PythonType::readyType() from /home/hugo/Documents/dev/freecad/freecadbhb_dev/build/lib/libFreeCADBase.so+0x1c
#5 0x7f0772115d0b in Py::SolidMaterialArray::init_type() from /home/hugo/Documents/dev/freecad/freecadbhb_dev/build/lib/libFreeCADApp.so+0x46
#6 0x7f07721157b4 in Py::PropertyPartMaterial::init_type() from /home/hugo/Documents/dev/freecad/freecadbhb_dev/build/lib/libFreeCADApp.so+0x16
#7 0x7f077216aa71 in App::Application::initTypes() from /home/hugo/Documents/dev/freecad/freecadbhb_dev/build/lib/libFreeCADApp.so+0x1ff
#8 0x7f077216a82d in App::Application::init(int, char**) from /home/hugo/Documents/dev/freecad/freecadbhb_dev/build/lib/libFreeCADApp.so+0x35
#9 ./bin/FreeCAD(main+0x6ef) [0x556880aa3d29]
#10 /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xeb) [0x7f076e0cd09b]
#11 ./bin/FreeCAD(_start+0x2a) [0x556880aa34ca]
hugo@Ahorn:~/Documents/dev/freecad/freecadbhb_dev/build$
I’ve been reading this thread with some hope that an update is coming? I’m looking for a way to describe different CTEs at different temperatures for FEM on a material card. I think that this is important enough that it needs to be on someone’s radar. Properties change with temperature. For example, ultimate strength… it may be that your particular material has a higher UTS ultimate tensile strength if its warmer than room temp. Such as refractory materials for example like molybdenum.
Another example is dissimilar CTE bonding of materials. For example soldering two metals with a glass. The glass in this case would melt at low 300-500C while the metal would melt at 1000+C temp. But the glass transition affects the properties of the glass tremendously so it is interesting to investigate the residual stress after the materials have cooled. This is for example used in microchip design, light bulb connectors, vacuum passthroughs, syringe design and really many other use cases where two dissimilar materials are bonded and the temperature is a factor that affects the CTEs.
At the moment, I think the only way is to go into the input file to Calculix and manually add different property changes at different temperatures. It would be nice if that info came from a materials card that I could re-use every time.
Just alerted to your thread. I did read your GSoC proposal.
Right now it looks like materials capabilities will be greatly expanded. I’m prototyping some stuff now for discussion that should be online in my thread shortly.
In the meantime, I’d be happy to do a zoom session so we can spit ball some ideas.