*"$@I=Bj(J $@%Y%/%H%kIA2h(J GTOOL3(GGMVCT)
*
*"$@MzNr(J 90/08/17 $@>B8}(J  $@FX(J
*"$@MzNr(J 90/10/17 $@>B8}(J  $@FX(J
*
*
*********************************************************************
*"         << $@%Y%/%H%kIA2h(J >>
*********************************************************************
      SUBROUTINE GGMVCT
     I         ( HHEADU, GDATAU,
     I           HHEADV, GDATAV )
*
      CHARACTER  HHEADU ( * )*(*)        !" $@%X%C%@!<(J(u$@@.J,(J)
      CHARACTER  HHEADV ( * )*(*)        !" $@%X%C%@!<(J(v$@@.J,(J)
      REAL       GDATAU ( * )            !" $@%G!<%?(J(u$@@.J,(J)
      REAL       GDATAV ( * )            !" $@%G!<%?(J(v$@@.J,(J)
*
      LOGICAL    OUNIT
      LOGICAL    OEQRAT
*
      CALL GUSMIS ( HHEADU )
*
      CALL GUQSIZ
     I         ( HHEADU,
     O           IXSTR , IXEND , IXDIM ,
     O           IYSTR , IYEND , IYDIM ,
     O           IZSTR , IZEND , IZDIM  )
*
      CALL GHPGET ( HHEADU, 'MISS' , UMISS  )
      CALL GHPGET ( HHEADU, 'DMIN' , UMIN   )
      CALL GHPGET ( HHEADU, 'DMAX' , UMAX   )
      CALL GHPGET ( HHEADU, 'STYP' , ISTYPU )
*
      CALL GHPGET ( HHEADV, 'MISS' , VMISS  )
      CALL GHPGET ( HHEADV, 'DMIN' , VMIN   )
      CALL GHPGET ( HHEADV, 'DMAX' , VMAX   )
      CALL GHPGET ( HHEADV, 'STYP' , ISTYPV )
*
      CALL GGPGET ( 'VXINT'  , IXINT )
      CALL GGPGET ( 'VYINT'  , IYINT )
      CALL UVPSET ( 'IXINT'  , IXINT )
      CALL UVPSET ( 'IYINT'  , IYINT )
*
      CALL GGPGET ( 'LUNIT'  , OUNIT   )
      CALL UVPSET ( 'LUNIT'  , OUNIT   )
      CALL GGPGET ( 'VXULOC' , VXULOC  )
      CALL GGPGET ( 'VYULOC' , VYULOC  )
      CALL UVPSET ( 'VXULOC' , VXULOC  )
      CALL UVPSET ( 'VYULOC' , VYULOC  )
      CALL GGPGET ( 'SREMK'  , SREMK   )
      CALL UVPSET ( 'RSIZET' , SREMK   )
      CALL UVPSET ( 'RSIZEUT', SREMK   )
*
      CALL GGPGET ( 'LEQRAT' , OEQRAT  )
      CALL UVPSET ( 'LEQRAT' , OEQRAT  )
      CALL UVPSET ( 'LNRMAL' , .FALSE. )
*
      CALL GGPGET ( 'VECFCT' , VECFCT )
*
      CALL SGQVPT ( VXMIN , VXMAX , VYMIN , VYMAX )
*
      IF ( UMIN .EQ. UMISS ) UMIN = RMIN( GDATAU, IXDIM*IYDIM, 1 )
      IF ( UMAX .EQ. UMISS ) UMAX = RMAX( GDATAU, IXDIM*IYDIM, 1 )
      AUMAX = MAX( ABS( UMIN ), ABS( UMAX ) )
      XFACT = VECFCT/AUMAX
     &        * ( VXMAX-VXMIN )/MAX( 1,IXDIM-1 ) * IXINT
      XFACT = RGNLE ( XFACT )
*
      IF ( VMIN .EQ. VMISS ) VMIN = RMIN( GDATAV, IXDIM*IYDIM, 1 )
      IF ( VMAX .EQ. VMISS ) VMAX = RMAX( GDATAV, IXDIM*IYDIM, 1 )
      AVMAX = MAX( ABS( VMIN ), ABS( VMAX ) )
      YFACT = VECFCT/AVMAX
     &        * ( VYMAX-VYMIN )/MAX( 1,IYDIM-1 ) * IYINT
      YFACT = RGNLE ( YFACT )
*
      IF ( OEQRAT ) THEN
         XFACT = MIN( XFACT, YFACT )
         YFACT = XFACT
      ENDIF
      IF ( ISTYPU .LT. 0 ) XFACT = - XFACT
      IF ( ISTYPV .LT. 0 ) YFACT = - YFACT
*
      CALL UVPSET ( 'XFACT1', XFACT )
      CALL UVPSET ( 'YFACT1', YFACT )
*
      CALL GGMGET ( 'IARLEN',IARLEN )
      CALL UVPSET ( 'IARLEN',IARLEN )
      CALL GGMGET ( 'ICENT' ,ICENT  )
      CALL UVPSET ( 'ICENT', ICENT  )
*
      CALL UVPSET ( 'INDEX', 1 )
      CALL UVPSET ( 'LMSG', .FALSE. )
      CALL UVPSET ( 'LUMSG', .TRUE. )
*
      CALL UVVECT ( GDATAU, IXEND-IXSTR+1,
     &              GDATAV, IXEND-IXSTR+1,
     &              IXEND-IXSTR+1, IYEND-IYSTR+1 )
*
      RETURN
      END
