Elmer module for Salomé

Discussion about coding and new developments
RaJa
Posts: 77
Joined: 22 Oct 2014, 09:48
Antispam: Yes

Re: Elmer module for Salomé

Post by RaJa »

mzenker wrote:In that case, would it be possible to organise the repository so that others (e.g. me ;) ) can see which is the last version known to work, and which is "work in progress"
I assume that this is the purpose of Git :D

I have updated the Git rep with a new version of the files. I have also moved the failing xml-file. So just delete your local copy and then copy all the files from the rep to your local drive and test it. Or just copy and manually remove the "linearelasticity.xml" from the edf-folder. Should work now. And I will work with branches now, so that the master is always a working file set.

Regards,
Rainer
RaJa
Posts: 77
Joined: 22 Oct 2014, 09:48
Antispam: Yes

Re: Elmer module for Salomé

Post by RaJa »

Hi Matthias,

I have finalized the GUI-code. All windows/dialogs are now in the git repository.

Now we have to think about functionality. There are certain issues that we have to reinvent due to the limitations of Salome. For example, it seems that the dynamically changed menu items are not working. Hence, we need to find another way to show the equations, materials, ... and of course we have to keep in mind that the user wants to edit them.

Any ideas?

Cheers,
Rainer
mzenker
Posts: 1999
Joined: 07 Dec 2009, 11:49
Location: Germany

Re: Elmer module for Salomé

Post by mzenker »

Hi Rainer,

I will have a closer look at your work as soon as I find the time, hopefully this week.

Cheers,

Matthias
Timo Siltala
Posts: 4
Joined: 03 Nov 2016, 14:30
Antispam: Yes

Re: Elmer module for Salomé

Post by Timo Siltala »

Hello,

I am just finalizing an Elmerplugin module to Salome. It exports Salome meshes, submeshes and groups to Elmer generating .nodes, .elements, .boundary .header and .names files. There are still some minor issues I have to solve with Elmer staff since all details are not absolutely.

Best regards,

Timo
mzenker
Posts: 1999
Joined: 07 Dec 2009, 11:49
Location: Germany

Re: Elmer module for Salomé

Post by mzenker »

Hi Timo,

what does your plugin do apart from exporting the Salomé mesh to Elmer? Does it do more than export to unv and call elmergrid?

Matthias
Timo Siltala
Posts: 4
Joined: 03 Nov 2016, 14:30
Antispam: Yes

Re: Elmer module for Salomé

Post by Timo Siltala »

Hello Matthias,

ElmerPlugin writes out straight from Salome to Elmer format. Currently recognized Elmer element types are:

0-D: 101
1-D: 202, 203
2-D: 303, 306, 404, 408, 409
3-D: 504, 510, 605, 613, 706, 715, 808, 820, 827

Others to be added when I need them in my analysis or someone friendly asks.

Node ordering of elements is adjusted according to Elmer node order. Elements are written out to .elements with intermediate comment lines consisting of group names (ElmerGUI has a minor input problem here).

Groups, meshes and submeshes can be exported. I recommend use of groups because the others include lots of unnecessary stuff (lower order elements) which are impossible to get rid of in ElmerGUI. Mesh and submesh possibilities are included for future purposes.

Nodes are written out in Elmer format to .nodes as well with group names as comments lines.

Boundaries are written out in Elmer format, second parent currently always 0 (I need boundaries for loads, constraints and contacts, not for gluing solids together). Boundary element parents are solved on request (some lower order elements can be part of structural mesh) and written to .boundary. Also boundary names are written to .boundary as comment lines.

Mesh, submesh and group names are written to .names.

Overall number of nodes and different element types are written to .header.

The mesh can be read into ElmerGUI as is. ElmerGUI does not recognize the names currently but I made a request for that feature to Elmer team. It would be a big benefit to have descriptive names coming straight from Salome. Also there is an issue of elements getting renumbered in ElmerGUI, that's under discussion now. In Salome I can not help that because typically from large models, some elements are not exported and the numbering is not therefore continuous. Salome renumbers automatically. For efficient and sensible use, element and node numbers should always be the same through the entire chain of tools from meshing to post processing. Let's see what Elmerteam manages to do.

I am testing the code heavily now in real cases, chewing my fingernails and removing bugs. I will publish my code soon, lets see where it can be easily done.

Next step is to add some very often used things like material input to Salome feature tree when I get mad in adding them manually.

Timo
Attachments
Groups picked for ElmerPlugin export.
Groups picked for ElmerPlugin export.
image005.jpg (38.87 KiB) Viewed 8413 times
Possible boundaries parent's solved.
Possible boundaries parent's solved.
image007.jpg (15 KiB) Viewed 8413 times
mzenker
Posts: 1999
Joined: 07 Dec 2009, 11:49
Location: Germany

Re: Elmer module for Salomé

Post by mzenker »

Hi Timo,

I am sure you are doing good work here.
However, the benefit is not totally clear to me. If I understand correctly, you have implemented the Elmergrid functionality into your module and still want to use ElmerGUI as frontend for mesh display and sif file building.

AFAIK all the features that you decribe are covered by exporting the mesh to unv and use Elmergrid to convert to Elmer format.

The approach of the project of Rainer and me (well, Rainer did all the work so far, and I hope to be able to contribute to it some time soon) is basically to implement the ElmerGUI functionality in a Salomé module. The main reason from my point of view is that ElmerGUI, although already a nice piece of software, is still lacking usability and stability, and that the Elmer team has very little manpower to devote to the GUI. Mesh transfer from Salomé to Elmer is not the main problem here, as Elmergrid does a very good job converting the unv format. And Elmergrid is actively maintained by the Elmer team, so I see no benefit in rewriting it.
The final goal for me would be to be able to have all the workflow inside the Salomé platform, using the software actively maintained by the Elmer team, which are ElmerSolver and ElmerGrid.

If we could agree on what functionality would make sense in an Elmer module for Salomé, maybe we could join forces to build it together, so we would reach the goal more quickly...

Matthias
Timo Siltala
Posts: 4
Joined: 03 Nov 2016, 14:30
Antispam: Yes

Re: Elmer module for Salomé

Post by Timo Siltala »

Hi Matthias,

as far as I know, .unv is missing pyramid elements and several other possibilities regarding Elmer element types. Pyramids are essential to fill a gaps between mapped mesh with hexas and free mesh with tetras. MPC:s hardly work satisfying way with plasticity material models having compaction included or coupled analysis cases. Also I don't know either if it could be possible to nominate lots of mechanical contact pairs in .unv method, I am not familiar with that route. Just now I have several large analyses to be made and writing own tool was the most straight forward method, which I can expand in future. ElmerGUI is just an intermediate step for the time being, I will bypass it soon in standard cases, adding materials, loads and constraints into feature tree. Not having time for that just now. Therefore ElmerGUI is for me an alternative route for many complicated cases.

My intention is to use Distene hex mesher in addition to Salome built-in ones, not using ElmerGrid at all. It seems to be quite good and reasonably priced for industrial use.

Reading your messages, I didn't understand how you are going to deal with the special element types. But let's see if there is an opportunity to have some co-operation in future. Sounds possible.

Timo
mzenker
Posts: 1999
Joined: 07 Dec 2009, 11:49
Location: Germany

Re: Elmer module for Salomé

Post by mzenker »

Hi Timo,

I wasn't aware of .unv missing element types. I am using tetrahedral meshes where the unv-> ElmerGrid route works very well. You might try it once to see what happens. Just export your mesh to e.g. mymesh.unv from within Salomé and do

Code: Select all

elmergrid 8 2 mymesh.unv -autoclean
I understand that you develop your module so as to fit your most urgent needs (which is what everyone would do), planning a ElmerGUI replacement in the future - while we intend to implement just that.
I will have to start helping Rainer with our module really soon now...!!
When we have something usable, we could see if a merge is possible.
BTW do you use C++ or Python for your module?

Matthias
Timo Siltala
Posts: 4
Joined: 03 Nov 2016, 14:30
Antispam: Yes

Re: Elmer module for Salomé

Post by Timo Siltala »

Hi Matthias,

it's C++ only.

Timo
Post Reply