      SUBROUTINE MSLP(PMSL,TL,PRESSG,PHIS,SHJL,ILG,IL1,IL2)
c
c     * JULY 27, 2005 - M.LAZARE.
C
C     * COMPUTES M.S.L. PRESSURE (IN MBS).
C     * THE CODE IS PULLED FROM THE DIAGNOSTIC CALCULATION TO MAINTAIN
C     * CONSISTENCY (PROGRAM GSMSLPH CALLED BY DECK MSLPR_ETA).
C
C     * WE ASSUME A UNIFORM LAPSE RATE OF (DT/DZ)=-GAM, FROM REFERENCE
C     * LEVEL (LOWEST LAYER) TO THE SURFACE, AND THEN FROM THE SURFACE TO SEA LEVEL.
C     * THE HYDROSTATIC EQUATION AND CONSTANT-LAPSE RATE EQUATION ARE
C     * USED FIRST TO DETERMINE "SURFACE TEMPERATURE".
C
      IMPLICIT REAL (A-H,O-Z),
     +INTEGER (I-N)
C
      REAL PMSL(ILG), TL(ILG), PRESSG(ILG), PHIS(ILG), SHJL(ILG)
C
      COMMON /PARAMS/ WW,TW,RAYON,ASQ,GRAV,RGAS,RGOCP,RGOASQ,CPRES
      COMMON /PARAMS/ RGASV,CPRESV
C  
      DATA GAM/0.0065/
C==========================================================================
      GAMRGOG = GAM*RGAS/GRAV
      FACT    = 0.5*GAM /GRAV
      DO 200 IL=IL1,IL2
        TS       = TL(IL) / SHJL(IL)**GAMRGOG
        TBAR     = TS + FACT*PHIS(IL)
        PMSL(IL) = 0.01 * PRESSG(IL) * EXP(PHIS(IL)/(RGAS*TBAR))
  200 CONTINUE
C
      RETURN
      END
