C**                                                                 ***
C**-----------------------------------------------------------------***
C**                                                                 ***
C**** the mesh is writen to the isvas mesh files :                  ***
C**   -------------------------------------------                   ***
C**                                                                 ***
      IVEM(120)=LOUT
      IVEM(121)=CNTMSH*OUTFLG
      IVEM(125)=8
      IVEM(126)=9
      IF (MYPROC.EQ.1) THEN
	 NAME='%MESH_FILEOUT_'
	 TEXT2=NAME
	 TEXT2(INDEX(NAME,' '):)='.nodes'
         OPEN(8,FILE=TEXT2,STATUS= 'UNKNOWN',FORM='FORMATTED')
	 TEXT2(INDEX(NAME,' '):)='.elements'
         OPEN(9,FILE=TEXT2,STATUS= 'UNKNOWN',FORM='FORMATTED')
      ENDIF
      CALL VEMISV (TEXT1,LIVEM,IVEM,LNEK,NEK,LRPARM,RPARM,LIPARM,IPARM,
     &             LDNOD,DNOD,LRDPRM,RDPARM,LIDPRM,IDPARM,LNODN,
     &             NODNUM,LNOD,NOD,LNOPRM,NOPARM,LBIG,RBIG,IBIG)
      IF (IVEM(2).NE.0) GOTO 9999
      IF (MYPROC.EQ.1) THEN
	 CLOSE(8)
         CLOSE(9)
	 WRITE(1,3010) 2,'isvas'
	 K=INDEX(NAME,' ')-1
	 WRITE(1,*) NAME(:K),'.nodes'
	 WRITE(1,*) NAME(:K),'.elements'
      ENDIF
