      SUBROUTINE SATVP1 ( A,B,C,D,T,TLO,THI,LM)
C     ROUTINE TO COMPUTE INTERPOLATION TABLES FOR SAT VAP PRESS
C     THAT WILL BE USED BY SUBROUTINE SATVAP
C     PHYSICAL CONSTANTS USED ARE FOR LIQUID WHEN T IS G.T.E. T3=
C         TRIPLE POINT = 273.16, AND FOR ICE WHEN T IS L.T.E.
C     TF = -30 DEG CELSIUS.  BETWEEN T3 AND TF A SMOOTH MIXTURE
C         IS USED.
CJPB  REAL*4 A(LM),B(LM),C(LM),D(LM),T(LM)
      REAL   A(LM),B(LM),C(LM),D(LM),T(LM)
CJPB  REAL*8 R,CP,CI,CL,LATI,LATL,T3,TF,E3,DT,AI,AL,BI,BL,
      DOUBLE PRECISION
     *       R,CP,CI,CL,LATI,LATL,T3,TF,E3,DT,AI,AL,BI,BL,
     C  TD,TAU,PL,PI,PDL,PDI,TEE,AA,AD,P1,PP1,P2,PP2
      DATA R/461.5/,CP/1876.5/,E3/.611/,T3/273.16/,TF/243.16/,
     C  CI/1922./,CL/4187./,LATI/2.835D6/,LATL/2.501D6/
C
C     ********  THE FLWG TWO CARDS MAKE ICE SAME AS WATER***************
      CI=CL
      LATI=LATL
      DT=(THI-TLO)/(LM-1.)
      AI=(CI-CP)/R
      AL=(CL-CP)/R
      BI=LATI/(R*T3)
      BL=LATL/(R*T3)
      T(1)=TLO
      TD=TLO
      DO 18 L=2,LM
      TAU=T3/TD
      PL=E3*(TAU**AL)*DEXP( (AL+BL)*(1.-TAU) )
      PI=E3*(TAU**AI)*DEXP( (AI+BI)*(1.-TAU) )
      PDL=(PL/(R*TD*TD) )*(LATL-(CL-CP)*(TD-T3) )
      PDI=(PI/(R*TD*TD) )*(LATI-(CI-CP)*(TD-T3) )
      TEE=(TD-TF)/(T3-TF)
      AA=TEE*TEE*(3.-2.*TEE)
      AD=6.*TEE*(1.-TEE)/(T3-TF)
      IF(TEE) 10,10,11
   10 AA=0.
      AD=0.
      GO TO 13
   11 IF(TEE-1.) 13,12,12
   12 AA=1.
      AD=0.
   13 P1=AA*PL+(1.-AA)*PI
      PP1=AD*(PL-PI)+AA*PDL+(1.-AA)*PDI
      TD=TD+DT
      T(L)=TD
      TAU=T3/TD
      PL=E3*(TAU**AL)*DEXP( (AL+BL)*(1.-TAU) )
      PI=E3*(TAU**AI)*DEXP( (AI+BI)*(1.-TAU) )
      PDL=(PL/(R*TD*TD) )*(LATL-(CL-CP)*(TD-T3) )
      PDI=(PI/(R*TD*TD) )*(LATI-(CI-CP)*(TD-T3) )
      TEE=(TD-TF)/(T3-TF)
      AA=TEE*TEE*(3.-2.*TEE)
      AD=6.*TEE*(1.-TEE)/(T3-TF)
      IF(TEE)  14,14,15
   14 AA=0.
      AD=0.
      GO TO 17
   15 IF(TEE-1.) 17,16,16
   16 AA=1.
      AD=0.
   17 P2=AA*PL+(1.-AA)*PI
      PP2=AD*(PL-PI)+AA*PDL+(1.-AA)*PDI
      A(L)=P1
      B(L)=PP1
      C(L)=(3.*(P2-P1)-DT*(2.*PP1+PP2) )/(DT*DT)
      D(L)=(2.*(P1-P2)+DT*(PP1+PP2) )/(DT*DT*DT)
   18 CONTINUE
      A(1)=0.
      B(1)=0.
      C(1)=0.
      D(1)=0.
      RETURN
      END
