MED fichier
f/2.3.6/test12.f
1 C* This file is part of MED.
2 C*
3 C* COPYRIGHT (C) 1999 - 2019 EDF R&D, CEA/DEN
4 C* MED is free software: you can redistribute it and/or modify
5 C* it under the terms of the GNU Lesser General Public License as published by
6 C* the Free Software Foundation, either version 3 of the License, or
7 C* (at your option) any later version.
8 C*
9 C* MED is distributed in the hope that it will be useful,
10 C* but WITHOUT ANY WARRANTY; without even the implied warranty of
11 C* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 C* GNU Lesser General Public License for more details.
13 C*
14 C* You should have received a copy of the GNU Lesser General Public License
15 C* along with MED. If not, see <http://www.gnu.org/licenses/>.
16 C*
17 
18 
19 C ******************************************************************************
20 C * - Nom du fichier : test12.f
21 C *
22 C * - Description : ecriture d'une equivalence dans un maillage MED
23 C *
24 C ******************************************************************************
25  program test12
26 C
27  implicit none
28  include 'med.hf'
29 C
30 C
31  integer*8 fid
32  integer cret
33  character*32 maa , equ
34  character*200 des
35  integer mdim ,ncor
36  integer cor(6)
37 
38  parameter(maa ="maa1",mdim = 3,ncor = 3 )
39  data cor /1,2,3,4,5,6/, equ / "equivalence"/
40  data des / "equivalence sur les mailles MED_TRIA3" /
41 
42 C ** Creation du fichier test12.med **
43  call efouvr(fid,'test12.med',med_lecture_ecriture, cret)
44  print *,cret
45  if (cret .ne. 0 ) then
46  print *,'Erreur creation du fichier'
47  call efexit(-1)
48  endif
49 
50 
51 C ** Creation du maillage **
52  call efmaac(fid,maa,mdim,med_non_structure,
53  & 'Un maillage pour test12',cret)
54  print *,cret
55  if (cret .ne. 0 ) then
56  print *,'Erreur creation du maillage'
57  call efexit(-1)
58  endif
59 
60 C ** Creation de l'equivalence **
61  call efequc(fid,maa,equ,des,cret)
62  print *,cret
63  if (cret .ne. 0 ) then
64  print *,'Erreur creation equivalence'
65  call efexit(-1)
66  endif
67 
68 C ** Ecriture des correspondances sur les mailles MED_TRIA3 **
69  call efeque(fid,maa,equ,cor,ncor,
70  & med_maille,med_tria3,cret)
71  print *,cret
72  if (cret .ne. 0 ) then
73  print *,'Erreur ecriture de correspondances'
74  call efexit(-1)
75  endif
76 
77 C ** Fermeture du fichier **
78  call efferm (fid,cret)
79  print *,cret
80  if (cret .ne. 0 ) then
81  print *,'Erreur fermeture du fichier'
82  call efexit(-1)
83  endif
84 C
85  end
test12
program test12
Definition: test12.f:25