MODULE SUSRAD_MOD
CONTAINS
SUBROUTINE SUSRAD(KSW,KSIL,KTSW,&
 & LD_LLCCNL,LD_LLCCNO,LD_LLE4ALB,&
 & PTSTAND,PXP,PRCCNSEA,PRCCNLND,PRSUN)

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

USE YOS_RAD   , ONLY : RCCNSEA,RCCNLND,LCCNL,LCCNO,LE4ALB,NTSW,NSW
USE YOS_RDI   , ONLY : RALBSFO,RALBSEAD,REMISD,REMISL,REMISN,&
 & REMISS,REPALB  

#ifdef DOC
!**   *SUSRAD* IS THE DRIVER TO ROUTINES SETTING-UP RADIATION CONSTANTS
!              This contains the fundamental model constants

!     INTERFACE.
!     ----------
!     CALL *SUSRAD* FROM *SUSURF*

!     METHOD.
!     -------

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

!     REFERENCE.
!     ----------

!     Original    P. Viterbo      May 2005

#endif

USE SURWN_MOD

IMPLICIT NONE

INTEGER(KIND=JPIM),INTENT(IN)    :: KSW 
INTEGER(KIND=JPIM),INTENT(IN)    :: KSIL
INTEGER(KIND=JPIM),INTENT(IN)    :: KTSW 
LOGICAL           ,INTENT(IN)    :: LD_LLCCNL 
LOGICAL           ,INTENT(IN)    :: LD_LLCCNO  
LOGICAL           ,INTENT(IN)    :: LD_LLE4ALB
REAL(KIND=JPRB)   ,INTENT(IN)    :: PTSTAND 
REAL(KIND=JPRB)   ,INTENT(IN)    :: PXP(6,6) 
REAL(KIND=JPRB)   ,INTENT(IN)    :: PRCCNSEA 
REAL(KIND=JPRB)   ,INTENT(IN)    :: PRCCNLND 
REAL(KIND=JPRB)   ,INTENT(IN)    :: PRSUN(:) 

REAL(KIND=JPRB) :: ZHOOK_HANDLE

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

IF (LHOOK) CALL DR_HOOK('SUSRAD_MOD:SUSRAD',0,ZHOOK_HANDLE)

!  DEFINE RADIATION GENERAL SETTINGS

RCCNSEA=PRCCNSEA
RCCNLND=PRCCNLND

NTSW=KTSW
NSW=KSW

LCCNL=LD_LLCCNL
LCCNO=LD_LLCCNO
LE4ALB=LD_LLE4ALB

! Define radiation lower boundary conditions settings

RALBSEAD = 0.05_JPRB
REPALB=1.E-12_JPRB
RALBSFO=0.15_JPRB
REMISD  = 0.93_JPRB
REMISL  = 0.96_JPRB
REMISN  = 0.98_JPRB
REMISS  = 0.99_JPRB

! Initialise radiation SW and LW constants

CALL SURWN(KSIL,PTSTAND,PXP,PRSUN)

IF (LHOOK) CALL DR_HOOK('SUSRAD_MOD:SUSRAD',1,ZHOOK_HANDLE)

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

END SUBROUTINE SUSRAD
END MODULE SUSRAD_MOD
