Re: [Gmsh] how do we do to export a mesh in med 3.3 from Gmsh 4.2.3

2019-04-11 Thread G. D. McBain

> So it seems like you cannot create a MED3 file when using the MED4 library.
>
> Maybe you could escalade this to the MED developers?

There was some discussion of this over at

   https://github.com/nschloe/meshio/issues/347#issuecomment-474367765

and it had been raised before that at

   https://www.salome-platform.org/forum/forum_10/835834708

The makeshift proposed in the meshio thread was:

…MED file, where the version is changed from 4.0.0 to 3.0.0, by modifying 
manually INFOS_GENERALES.  …This file can be loaded by gmsh


___
gmsh mailing list
gmsh@onelab.info
http://onelab.info/mailman/listinfo/gmsh


Re: [Gmsh] how do we do to export a mesh in med 3.3 from Gmsh 4.2.3

2019-04-11 Thread Christophe Geuzaine


> On 11 Apr 2019, at 11:20, jean pierre aubry  
> wrote:
> 
> hello
> 
> how do we do to export a mesh in med 3.3 from Gmsh 4.2.3

Unfortunately I think it's impossible. Gmsh is now linked with MED4, and uses 
"MEDfileVersionOpen" to create MED files. From the MED documentation (see the 
first "remarque"):

```
med_idt MEDfileVersionOpen (const char *const   filename, 
const med_access_mode accessmode, 
const med_int   major, 
const med_int   minor, 
const med_int   release 
)   
Ouverture d'un fichier MED en indiquant la version du modèle à utiliser en cas 
de création d'un nouveau fichier. 

Paramètres
filenameNom du fichier. 
accessmode  Mode d'acces au fichier. 
major   Numéro de version majeur. 
minor   Numéro de version mineur. 
release Numéro de release. 
Valeurs retournées
med_idt résultat i.e. l'identificateur entier (ID) retourné sera utilisé par 
les routines de l'API pour accéder au contenu du fichier.
Ouverture d'un fichier MED. 

Remarques
• Le numéro major ne peut être que le numéro majeur utilisé par 
la bibliothèque. 
• Le numéro minor ne peut être que dans la plage des versions 
mineurs des bibliothèques distribuées avec le numéro majeur égal à celui de la 
bibliothèque utilisé. 
• Le numéro release n'est pas pris en compte. Le numéro release 
utilisé sera le numéro le plus élévé associé à la version mineure demandée. 
• Si aucun fichier de nom filename n'existe, il est crée dans 
les modes MED_ACC_RDWR et MED_ACC_RDEXT. 
• En mode MED_ACC_CREAT un nouveau fichier filename est crée 
qu'il en existe déjà un ou non. 
Définition à la ligne 44 du fichier MEDfileVersionOpen.c.
```

So it seems like you cannot create a MED3 file when using the MED4 library.

Maybe you could escalade this to the MED developers?

Christophe


> 
> thanks
> 
> jean pierre aubry
> 
> -- 
> jean pierre aubry
> jeanpierreaubry[at]ouvaton.org
> 33 688 670 795
> 
> 
> 
> ___
> gmsh mailing list
> gmsh@onelab.info
> http://onelab.info/mailman/listinfo/gmsh

— 
Prof. Christophe Geuzaine
University of Liege, Electrical Engineering and Computer Science 
http://www.montefiore.ulg.ac.be/~geuzaine




___
gmsh mailing list
gmsh@onelab.info
http://onelab.info/mailman/listinfo/gmsh


[Gmsh] how do we do to export a mesh in med 3.3 from Gmsh 4.2.3

2019-04-11 Thread jean pierre aubry
hello

how do we do to export a mesh in med 3.3 from Gmsh 4.2.3

thanks

jean pierre aubry

-- 
jean pierre aubry
jeanpierreaubry[at]ouvaton.org
33 688 670 795



___
gmsh mailing list
gmsh@onelab.info
http://onelab.info/mailman/listinfo/gmsh