DIAG_EVAP_ISBA_NP_INIT Subroutine

public subroutine DIAG_EVAP_ISBA_NP_INIT(YNDIAG_EVAP_ISBA, KPATCH)

Arguments

Type IntentOptional AttributesName
type(DIAG_EVAP_ISBA_NP_t), intent(inout) :: YNDIAG_EVAP_ISBA
integer, intent(in) :: KPATCH

Contents


Source Code

SUBROUTINE DIAG_EVAP_ISBA_NP_INIT(YNDIAG_EVAP_ISBA,KPATCH)
TYPE(DIAG_EVAP_ISBA_NP_t), INTENT(INOUT) :: YNDIAG_EVAP_ISBA
INTEGER, INTENT(IN) :: KPATCH
INTEGER :: JP
REAL(KIND=JPRB) :: ZHOOK_HANDLE
IF (LHOOK) CALL DR_HOOK("MODD_DIAG_EVAP_ISBA_N:DIAG_EVAP_ISBA_NP_INIT",0,ZHOOK_HANDLE)
IF (.NOT.ASSOCIATED(YNDIAG_EVAP_ISBA%AL)) THEN
  ALLOCATE(YNDIAG_EVAP_ISBA%AL(KPATCH))
  DO JP=1,KPATCH
    CALL DIAG_EVAP_ISBA_INIT(YNDIAG_EVAP_ISBA%AL(JP))
  ENDDO
ELSE
  DO JP=1,KPATCH
    CALL DIAG_EVAP_ISBA_INIT(YNDIAG_EVAP_ISBA%AL(JP))
  ENDDO
  DEALLOCATE(YNDIAG_EVAP_ISBA%AL)
ENDIF  
IF (LHOOK) CALL DR_HOOK("MODD_DIAG_EVAP_ISBA_N:DIAG_EVAP_ISBA_NP_INIT",1,ZHOOK_HANDLE)
END SUBROUTINE DIAG_EVAP_ISBA_NP_INIT