Unittest_MEDlocalization_3.f

Aller à la documentation de ce fichier.
00001 C*  This file is part of MED.
00002 C*
00003 C*  COPYRIGHT (C) 1999 - 2015  EDF R&D, CEA/DEN
00004 C*  MED is free software: you can redistribute it and/or modify
00005 C*  it under the terms of the GNU Lesser General Public License as published by
00006 C*  the Free Software Foundation, either version 3 of the License, or
00007 C*  (at your option) any later version.
00008 C*
00009 C*  MED is distributed in the hope that it will be useful,
00010 C*  but WITHOUT ANY WARRANTY; without even the implied warranty of
00011 C*  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00012 C*  GNU Lesser General Public License for more details.
00013 C*
00014 C*  You should have received a copy of the GNU Lesser General Public License
00015 C*  along with MED.  If not, see <http://www.gnu.org/licenses/>.
00016 C*
00017 
00018 C******************************************************************************
00019 C * Tests for localization module
00020 C *
00021 C *****************************************************************************
00022       program MEDloc3
00023 C     
00024       implicit none
00025       include 'med.hf'
00026 C
00027 C     
00028       integer cret
00029       integer fid
00030       character*64  fname,lname1,giname1,isname1
00031       character*64  giname,isname
00032       parameter (fname="Unittest_MEDlocalization_1.med")  
00033       integer it,n,nloc
00034       parameter (nloc=1)
00035       parameter (giname1=MED_NO_INTERPOLATION)
00036       parameter (isname1=MED_NO_MESH_SUPPORT)
00037       integer gtype1,sdim1,nip1
00038       integer gtype,sdim,nip
00039       parameter(gtype1=MED_TRIA3)
00040       parameter(sdim1=2)
00041       parameter(nip1=3)
00042       integer sgtype,sgtype1
00043       parameter (sgtype1=MED_UNDEF_GEOTYPE)
00044       integer nsmc, nsmc1
00045       parameter (nsmc1=0)
00046 C 
00047 C
00048 C     open file
00049       call mfiope(fid,fname,MED_ACC_RDONLY,cret)
00050       print *,cret
00051       if (cret .ne. 0 ) then
00052          print *,'ERROR : open file'
00053          call efexit(-1)
00054       endif  
00055 C
00056 C
00057 C     number of localization
00058       call mlcnlc(fid,n,cret)
00059       print *,cret
00060       if ((cret .ne. 0) .or.
00061      &    (n .ne. nloc) )then
00062          print *,'ERROR : number of localization'
00063          call efexit(-1)
00064       endif  
00065 C
00066 C
00067 C     informations bt iteration
00068       do it=1,n
00069          call mlclci(fid,it,lname1,gtype,sdim,nip,
00070      &               giname,isname,nsmc,sgtype,cret)
00071          print *,cret
00072          if (cret .ne. 0 ) then
00073             print *,'ERROR : read information'
00074             call efexit(-1)
00075          endif  
00076 c
00077          if ((gtype .ne. gtype1) .or.
00078      &        (sdim .ne. sdim1) .or.
00079      &        (nip .ne. nip1) .or.
00080      &        (giname .ne. giname1) .or.
00081      &        (isname .ne. isname1) .or.
00082      &        (nsmc .ne. nsmc1) .or.
00083      &        (sgtype .ne. sgtype1) ) then
00084             print *,cret
00085             print *,'ERROR : read information'
00086             call efexit(-1)
00087          endif  
00088       enddo
00089 C
00090 C
00091 C     close file
00092       call mficlo(fid,cret)
00093       print *,cret
00094       if (cret .ne. 0 ) then
00095          print *,'ERROR :  close file'
00096          call efexit(-1)
00097       endif        
00098 C
00099 C
00100 C
00101       end
00102 

Généré le Thu Oct 8 14:26:17 2015 pour MED fichier par  doxygen 1.6.1