      SUBROUTINE VRCPK(VECR, NVEC, CONST)
C
C***********************************************************************
C
C   NAME- VRCPK
C
C   LANGUAGE- FORTRAN 77     TYPE- SUBROUTINE        COMPUTER- CRAY    
C
C   VERSION- 1.0    DATE- 07/13/89   PROGRAMMER- S.SWEETLAND (SMSRC)
C   VERSION- 3.0    DATE- 05/10/96   PROGRAMMER- A.POZDNYAK (FDC)   
C     FOR REHOSTING TO THE CRAY, CHANGED ALL I*4 DECLARATIONS TO
C      INTEGER AND ALL R*4 DECLARATIONS TO REAL.
C   VERSION- 4.0    DATE- 02/27/03   PROGRAMMER- Rickey Rollins (CSC)
C        Replace R4SPV equivalence test with ISR4SPV function    
C
C   FUNCTION- MULTIPLIES THE RECIPROCAL OF EACH ELEMENT OF THE INPUT
C             VECTOR (VECR) BY A CONSTANT AND PLACES THE RESULT IN
C             CORRESPONDING ELEMENT OF THE OUTPUT VECTOR (VECR).
C
C   CALLING SEQUENCE PARAMETERS-
C
C     NAME   TYPE  I/O    DESCRIPTION
C     ----   ----  ---    ------------
C
C     VECR    REAL  I/O    I/O VECTOR OF DIMENSION NVEC.
C
C     NVEC    INT   I      NUMBER OF ELEMENTS IN I/O VECTOR VECR.
C
C     CONST   REAL  I      REAL CONSTANT.
C
C   LOCAL PARAMETERS-
C
C     NAME   TYPE  I/O    DESCRIPTION
C     ----   ----  ---    ------------
C     J      INT   N/A    DO LOOP INDEX.
C
C   EXIT STATES- NONE.
C
C***********************************************************************
C
      INTEGER  NVEC
      REAL     VECR(NVEC), CONST
      LOGICAL   ISR4SPV
C
      INTEGER  J
C
      INCLUDE 'SPVAL'
C
      DO 10 J = 1,NVEC
        IF(ISR4SPV(VECR(J))) GOTO 10
        IF(VECR(J) .NE. 0.)THEN
           VECR(J) = CONST * (1/ VECR(J))
        ELSE
C
C   SPECIAL VALUE WAS PUT IN FOR INVALID DATA.
C
           VECR(J) = R4SPV
        ENDIF
   10 CONTINUE
C
      RETURN
      END
