31 integer sdim, mdim, stype, mtype, atype
32 integer axis, isize, entype, nquad4
37 character*16 axname(2)
39 character*16 unname(2)
41 character*16 cnames(8)
45 parameter(fname =
"UsesCase_MEDmesh_4.med")
46 parameter(mdesc =
"A 2D structured mesh")
47 parameter(mname =
"2D structured mesh")
48 parameter(sdim = 2, mdim = 2)
49 parameter(stype=med_sort_dtit, mtype=med_structured_mesh)
50 parameter(atype=med_cartesian_grid)
54 data axname /
"x" ,
"y"/
55 data unname /
"cm",
"cm"/
56 data cnames /
"CELL_1",
"CELL_2",
60 data cooxaxis /1.,2.,3.,4.,5./
61 data cooyaxis /1.,2.,3./
65 call mfiope(fid,fname,med_acc_creat,cret)
66 if (cret .ne. 0 )
then 67 print *,
'ERROR : file creation' 73 call mmhcre(fid, mname, sdim, mdim, mtype,mdesc,
74 & dtunit, stype, atype, axname, unname, cret)
75 if (cret .ne. 0 )
then 76 print *,
'ERROR : mesh creation' 82 call mmhgtw(fid,mname,med_cartesian_grid,cret)
83 if (cret .ne. 0 )
then 84 print *,
'ERROR : write grid type' 92 call mmhgcw(fid,mname,med_no_dt,med_no_it,dt,
93 & axis,isize,cooxaxis,cret)
94 if (cret .ne. 0 )
then 95 print *,
'ERROR : write X coordinates' 100 call mmhgcw(fid,mname,med_no_dt,med_no_it,dt,
101 & axis,isize,cooyaxis,cret)
102 if (cret .ne. 0 )
then 103 print *,
'ERROR : write Y coordinates' 110 call mmheaw(fid,mname,med_no_dt,med_no_it,med_cell,med_quad4,
111 & nquad4,cnames,cret)
112 if (cret .ne. 0 )
then 113 print *,
'ERROR : write names for elements' 119 call mfacre(fid,mname,med_no_name,0,0,med_no_group,cret)
120 if (cret .ne. 0 )
then 121 print *,
'ERROR : create family 0' 128 if (cret .ne. 0 )
then 129 print *,
'ERROR : close file' subroutine mficlo(fid, cret)
subroutine mmhgtw(fid, name, gtype, cret)
program usescase_medmesh_4
subroutine mmheaw(fid, mname, numdt, numit, entype, geotype, n, ename, cret)
subroutine mmhcre(fid, name, sdim, mdim, mtype, desc, dtunit, stype, atype, aname, aunit, cret)
subroutine mfacre(fid, name, fname, fnum, ngro, gname, cret)
subroutine mfiope(fid, name, access, cret)
subroutine mmhgcw(fid, name, numdt, numit, dt, axis, size, index, cret)