SUBROUTINE AROCLDIA(KIDIA,KFDIA, KLON,&
                   & PUCLS, PVCLS, PTKE, &
                   & PUGST, PVGST)

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

#ifdef DOC

!**** *AROCLDIA*  - Compute some PBL Diags  -

!     PURPOSE.
!     --------
!        To Compute some PBl diags 
!                   * Wind gusts from PBL wind and Tke
!**   INTERFACE.
!     ----------
!       *CALL* *AROCLDIA*

!        EXPLICIT ARGUMENTS
!        --------------------
!            INPUT :
!        KIDIA   : start of work
!        KFDIA   : end of work
!        KLON    : depth of work
!        PUCLS   : X-CLS WIND (KLON)
!        PVCLS   : Y-CLS WIND (KLON)
!        PTKE    : TKE (last model level) (KLON)
!            OUTPUT:
!        PUGST    : X- WIND GUST (KLON)
!        PVGST    : Y- WIND GUST (KLON)

!        IMPLICIT ARGUMENTS
!        --------------------
!           NONE

!     METHOD.
!     -------
!        Consider That winds gust are // to cls wind. Consider Tke to
!        increment the cls wind to obtain wind gust. Formulation first
!        implemented and tested in the meso-Nh diags for the 1999
!        storms.

!     EXTERNALS.
!     ----------
   
!     REFERENCE.
!     ----------
!        None

!     AUTHOR.
!     -------
!        Gwenaelle Hello *METEO-FRANCE*

!     MODIFICATIONS.
!     --------------
!        ORIGINAL : 07-04-18
!     ------------------------------------------------------------------
#endif

IMPLICIT NONE

INTEGER(KIND=JPIM),INTENT(IN) :: KIDIA,KFDIA,KLON
REAL(KIND=JPRB), INTENT(IN) :: PUCLS(KLON), PVCLS(KLON), PTKE(KLON)
REAL(KIND=JPRB), INTENT(OUT) :: PUGST(KLON), PVGST(KLON)

INTEGER (KIND=JPIM) :: JLON
REAL(KIND=JPRB) :: ZHOOK_HANDLE, ZALPHA, ZVCLS

IF (LHOOK) CALL DR_HOOK('AROCLDIA',0,ZHOOK_HANDLE)
!      ----------------------------------------------------------------

DO JLON=KIDIA, KFDIA
    ZVCLS=PUCLS(JLON)**2+PVCLS(JLON)**2
    IF (ZVCLS /= 0._JPRB) THEN
      ZALPHA = PTKE(JLON)/(PUCLS(JLON)**2+PVCLS(JLON)**2)
      ZALPHA =1.0_JPRB + 4.0_JPRB * SQRT(ZALPHA)
    ELSE
      ZALPHA=0._JPRB 
    ENDIF
    PUGST(JLON)=ZALPHA * PUCLS(JLON)
    PVGST(JLON)=ZALPHA * PVCLS(JLON)
ENDDO        
IF (LHOOK) CALL DR_HOOK('AROCLDIA',1,ZHOOK_HANDLE)

END SUBROUTINE AROCLDIA

