SUBROUTINE SUFPDIM

!**** *SUFPDIM*  - INITIALIZE FULL-POS DIMENSIONING FOR DYNAMICS

!     PURPOSE.
!     --------
!        Setup the list of primitive variables for the post-processing

!**   INTERFACE.
!     ----------
!       *CALL* *SUFPDIM*

!        EXPLICIT ARGUMENTS
!        --------------------

!        IMPLICIT ARGUMENTS
!        --------------------
!        YOMFPC

!     METHOD.
!     -------
!        SEE DOCUMENTATION

!     EXTERNALS.
!     ----------

!     REFERENCE.
!     ----------
!        ECMWF Research Department documentation of the IFS

!     AUTHOR.
!     -------
!        RYAD EL KHATIB *METEO-FRANCE*

!     MODIFICATIONS.
!     --------------
!        ORIGINAL : 94-04-08
!        Modified : 95-01-20 Thierry Bergot (spectral filtering for all
!                   fields in PV levels except wind component and Psi/Khi)
!        R. El Khatib : 97-06-02  3 NH fields
!        R. El Khatib : 98-08-14 reestablish missing preliminary scan 'M' if 
!                       post-processing on height or eta levels exists.
!        R. El Khatib 98-08-14 Simplify scan controls
!        R. El Khatib : 99-03-09 Simplify fullpos control
!        D.Dent       99-05-06 Support for log surface pressure
!        R. El Khatib : 00-08-18 derived types
!        D. Dent      00-04-12 Support for computation of Montgomery geopotential
!        R. El Khatib : 01-08-07 Pruning options
!        R. El Khatib : 02-01-22 Substantial cleaning
!        R. El Khatib : 03-08-13 gfl
!        M.Hamrud      01-Oct-2003 CY28 Cleaning
!     ------------------------------------------------------------------

USE PARKIND1  ,ONLY : JPRB
USE YOMHOOK   ,ONLY : LHOOK,   DR_HOOK

USE YOMDIM   , ONLY : NFLEVG
USE YOMFPC   , ONLY : LFPNHPD  ,LFPNHVD  ,LFPNHVW
USE YOMAFN   , ONLY : TFP_VW   ,TFP_WWS  ,TFP_PD   ,TFP_DYNDS

IMPLICIT NONE

! -------------------------------------------------------------------------

REAL(KIND=JPRB) :: ZHOOK_HANDLE
IF (LHOOK) CALL DR_HOOK('SUFPDIM',0,ZHOOK_HANDLE)
IF (LFPNHPD) THEN
! NH Pressure departure
  TFP_PD%ILMOD=NFLEVG ; TFP_DYNDS(TFP_PD%ICOD)%ILMOD=NFLEVG
ENDIF
IF (LFPNHVD.OR.LFPNHVW) THEN
! True vertical velocity ON UPPER HALF LEVELS +  True vertical velocity ON SURFACE
  TFP_VW%ILMOD=NFLEVG ; TFP_DYNDS(TFP_VW%ICOD)%ILMOD=NFLEVG
  TFP_WWS%ILMOD=1 ; TFP_DYNDS(TFP_WWS%ICOD)%ILMOD=1
ENDIF

IF (LHOOK) CALL DR_HOOK('SUFPDIM',1,ZHOOK_HANDLE)
END SUBROUTINE SUFPDIM
