C
      SUBROUTINE NVP1
C
C     ------------------------------------------------------------------
C
C       SUBROUTINE PURPOSE:
C       EVALUATION OF NVP THROUGH MANIPULATION OF INPUT JUNCTION DATA
C       IN TEMP. AND ELEVATION.
C
C     ------------------------------------------------------------------
C
      INCLUDE 'CMMNW.DAT'
C
      MBEGW=1
      DO 30 K=1,MNO
         IF (NVPN.GE.1) GO TO 30
         MENDW=MEND(K)
         TZ=0.0
         ZOT=0.0
C
         DO 20 J=MBEGW,MENDW
            N=MSL(J)
            NX=N
            IF (NX.LT.0) NX=-NX
            DO 10 L=1,NJ
               IF (JS(NX).EQ.JNO(L)) THEN
                  T0=T(L)+460.
                  Z0=Z(L)
               ELSE IF (JF(NX).EQ.JNO(L)) THEN
                  T1=T(L)+460.
                  Z1=Z(L)
               ENDIF
10          CONTINUE
            DZZ=(Z1-Z0)
            IF (N.LT.0) DZZ=-DZZ
            TZ=TZ+0.5*(T0+T1)*DZZ
            ZOT=ZOT+DZZ/(0.5*(T0+T1))
20       CONTINUE
C
         IF (ABS(ZOT).LE.0.000001) THEN
            TM=TR+460.0
         ELSE
            TM=ABS(SQRT(ABS(TZ/ZOT)))
         ENDIF
C
         IF (ABS(TM).LE.0.000001) TM=TR+460.0
         FNVP(K)=TZ*DR/(5.2*TM)
         MBEGW=MENDW+1
30    CONTINUE
C
      RETURN
      END
C
