Thank you, Jmhervouet.
The fortran file is as following(making use of most sentences in the readgeo1.f)
INTEGER :: NPOIN ! NUMBER OF MESH NODES
INTEGER :: NELEM ! NUMBER OF ELEMENTS
INTEGER :: NDP ! NUMBER OF ELEMENT FACES
INTEGER :: IB(10) ! INTEGER ARRAY
INTEGER :: NPTFR ! NUMBER OF BOUNDARY NODES
INTEGER :: NFIC ! FILE TO READ
INTEGER :: NELEBD ! NUMBER OF BOUNDARY ELEMENTS
!
!+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
!
DOUBLE PRECISION :: XB(2)
REAL :: RB(2)
INTEGER :: ISTAT
INTEGER :: NVAR
INTEGER :: I,IB6(6)
CHARACTER(LEN=2) :: CB
CHARACTER(LEN=80) :: TITLE
C CHARACTER(LEN=8) :: FORMATT
!
!
!
! GOES TO THE BEGINNING OF THE FILE
rewind(10)
open(10,file='wq3.res',form='unformatted')
WRITE(*,*)'OK1'
!
! 1: TITLE
c CALL LIT(XB,RB,IB,TITRE,72,'CH',NFIC,'STD',ISTAT)
READ(10,END=100,ERR=101) TITLE(1:80)
WRITE(*,*)'OK2'
WRITE(*,*) TITLE(1:80)
!
! 2: NUMBER OF ARRAYS IN THE RESULT FILE
C CALL LIT(XB,RB,IB,CB,2,'I ',NFIC,'STD',ISTAT)
READ(10,END=100,ERR=101)(IB(J),J=1,2)
WRITE(*,*)(IB(J),J=1,2)
NVAR = IB(1) + IB(2)
! 3: NAMES AND UNITS OF VARIABLES
IF(NVAR.GE.1) THEN
DO I=1,NVAR
C CALL LIT(XB,RB,IB,CB,2,'CH',NFIC,'STD',ISTAT)
READ(10,END=100,ERR=101) CB(1:2)
WRITE(*,*)CB(1:2)
ENDDO
ENDIF
!
! 4: LIST OF 10 INTEGER PARAMETERS
C CALL LIT(XB,RB,IB,CB,10,'I ',NFIC,'STD',ISTAT)
READ(10,END=100,ERR=101)(IB(J),J=1,10)
WRITE(*,*)(IB(J),J=1,10)
!
! CASE WHERE DATE AND TIME ARE IN THE FILE
IF(IB(10).EQ.1)READ(10,END=100,ERR=101)(IB6(J),J=1,6)
WRITE(*,*)(IB6(J),J=1,6)
!CALL LIT(XB,RB,IB6,CB,6,'I ',NFIC,'STD',ISTAT)
!
! READS THE NUMBER OF BOUNDARY ELEMENTS FOR 3D MESH
IF(IB(7).NE.0) THEN
NELEBD = IB(7)
END IF
! CASE WHERE KNOLG IS GIVEN INSTEAD OF IPOBO (PARALLEL MODE)
IF(IB(8).NE.0) THEN
NPTFR=IB(8)
! NOTE JMH : NEXT LINE MOVED AFTER ENDIF ON 22/07/02
! SUBDOMAINS MAY HAVE NPTFR=0
! NPTIR=IB(9)
ENDIF
NPTIR=IB(9)
!
! 5: 4 INTEGERS
C CALL LIT(XB,RB,IB6,CB,4,'I ',NFIC,'STD',ISTAT)
READ(10,END=100,ERR=101)(IB6(J),J=1,4)
WRITE(*,*)(IB6(J),J=1,4)
!
NELEM = IB6(1)
NPOIN = IB6(2)
NDP = IB6(3)
100 CONTINUE
WRITE(*,'(1X,A)') 'ABNORMAL END OF FILE'
WRITE(*,'(1X,A)') 'ONE INTENDED TO READ'
STOP
101 CONTINUE
WRITE(*,'(1X,A)') ' READ ERROR'
STOP
WRITE(*,300) TITRE
WRITE(*,500) NELEM,NPOIN
WRITE(*,301) TITRE
WRITE(*,501) NELEM,NPOIN
!
IF(NPOIN.LT.3) THEN
WRITE(*,24) NPOIN
STOP
ENDIF
!
24 FORMAT(1X,' NUMBER OF POINTS IN THE MESH: ',1I9,/,1X,
& ' NUMBER OF BOUNDARY POINTS: ',1I8,/,1X,
& ' WRONG DATA, PROGRAMME STOPPED')
300 FORMAT(1X,//,1X,'TITRE= ',A72,/)
301 FORMAT(1X,//,1X,'TITLE= ',A72,/)
500 FORMAT(1X,'NOMBRE D''ELEMENTS:',1I9,/,
& 1X,'NOMBRE REEL DE POINTS:',1I9)
501 FORMAT(1X,'NUMBER OF ELEMENTS:',1I9,/,
& 1X,'NUMBER OF POINTS:',1I9)
!
!
!
END