FUNCTION SNOW_FRAC_VEG(PPSNG,PWSNOW,PZ0VEG,PRHOS) RESULT(PPSNV)
! #########################################################
!
USE MODD_SNOW_PAR, ONLY : XWSNV
IMPLICIT NONE
!
REAL, DIMENSION(:), INTENT(IN) :: PPSNG ! snow fraction over bare ground
REAL, DIMENSION(:), INTENT(IN) :: PWSNOW ! snow amount over natural areas (kg/m2)
REAL, DIMENSION(:), INTENT(IN) :: PZ0VEG ! vegetation roughness length for momentum
REAL, DIMENSION(:), INTENT(IN) :: PRHOS ! snow density (kg/m3)
REAL, DIMENSION(SIZE(PWSNOW)) :: PPSNV ! snow fraction over vegetation
REAL(KIND=JPRB) :: ZHOOK_HANDLE
!
IF (LHOOK) CALL DR_HOOK('MODE_SURF_SNOW_FRAC:SNOW_FRAC_VEG',0,ZHOOK_HANDLE)
PPSNV(:) = PWSNOW(:) / (PWSNOW(:)+PRHOS(:)*XWSNV*PZ0VEG(:))
! Make sure PPSNV <= PPSNG
PPSNV(:) = MIN(PPSNV(:),PPSNG(:))
IF (LHOOK) CALL DR_HOOK('MODE_SURF_SNOW_FRAC:SNOW_FRAC_VEG',1,ZHOOK_HANDLE)
!
END FUNCTION SNOW_FRAC_VEG