Welcome to the forums. Please post in English or French.

You are not logged in.

#1 2021-12-14 11:19:40

jonas loenartz
Member
Registered: 2021-10-01
Posts: 51

MED documentation

Hello,

I'm looking for a documentation of the .med file-format in order to write a mesh-output-template for a preprocessor.

Jonas

Last edited by jonas loenartz (2021-12-14 11:20:17)

Offline

#2 2021-12-16 09:48:35

JanBlokes
Member
From: Ostrava
Registered: 2018-09-06
Posts: 34

Re: MED documentation

Hello Jonas,

I think the *.med file is coded and you cannot open it like for example *.mail or *.nas format. Anyway, you can install Python modul 'meshio' (pip install meshio) and there is code for it.

You can create macro directly in Salome - for geometry, mesh, etc. with Python.

Jan

Offline

#3 2021-12-16 10:26:47

nicolas_p
Member
Registered: 2020-04-14
Posts: 56

Re: MED documentation

med is a binary format

There is a C or fortran interface to create a med file directly or use medcoupling in python or c++ which allows to manipulate med files. Both are in salome

Offline

#4 2021-12-16 11:55:33

jonas loenartz
Member
Registered: 2021-10-01
Posts: 51

Re: MED documentation

Thank you for your answers. Following nicolas_ps suggestion I found the following information on several APIs to read/write MED-files.

h_ttps://docs.salome-platform.org/7/dev/MEDCoupling/index.html

Sadly I won't be able to utilize these because I can't access these APIs in Hyperworks TCL-interface. I will work with the .unv or .mail file format and convert them to .med using Code Aster.

But thank you JanBlokes for the information on meshio. I did not know about his tool and it seems to be very useful!

Jonas

Offline