trans_release.F90 Source File


This file depends on

sourcefile~~trans_release.f90~~EfferentGraph sourcefile~trans_release.f90 trans_release.F90 sourcefile~resols_mod.f90 resols_mod.F90 sourcefile~trans_release.f90->sourcefile~resols_mod.f90 sourcefile~tpm_gen.f90 tpm_gen.F90 sourcefile~trans_release.f90->sourcefile~tpm_gen.f90 sourcefile~backends_mod.f90 backends_mod.F90 sourcefile~resols_mod.f90->sourcefile~backends_mod.f90

Source Code

! (C) Copyright 2000- ECMWF.
! (C) Copyright 2000- Meteo-France.
! 
! This software is licensed under the terms of the Apache Licence Version 2.0
! which can be obtained at http://www.apache.org/licenses/LICENSE-2.0.
! In applying this licence, ECMWF does not waive the privileges and immunities
! granted to it by virtue of its status as an intergovernmental organisation
! nor does it submit to any jurisdiction.
!

SUBROUTINE TRANS_RELEASE(KRESOL)

!**** *TRANS_RELEASE* - release a spectral resolution

!     Purpose.
!     --------
!      Release all arrays related to a given resolution tag

!**   Interface.
!     ----------
!     CALL TRANS_RELEASE

!     Explicit arguments : KRESOL : resolution tag
!     --------------------

!     Method.
!     -------

!     Externals.  None
!     ----------

!     Author.
!     -------
!        R. El Khatib *METEO-FRANCE*

!     Modifications.
!     --------------
!        Original : 09-Jul-2013

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

USE EC_PARKIND, ONLY: JPIM

!ifndef INTERFACE

USE RESOLS_MOD, ONLY: Y_RESOLS
USE TPM_GEN, ONLY: LENABLED, NOUT

IMPLICIT NONE

INTEGER(KIND=JPIM), INTENT(IN) :: KRESOL

!endif INTERFACE

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

! Check this resol is less than maximum number of resols
IF (KRESOL <= SIZE(Y_RESOLS)) THEN
  ! Check this resol is actually initialised
  IF (LENABLED(KRESOL)) THEN
    CALL Y_RESOLS(KRESOL)%DESTROY(KRESOL)
  ELSE
    WRITE(NOUT, FMT='(''TRANS_RELEASE: Warning KRESOL = '',I3,'' is already disabled '')') KRESOL
  ENDIF
ENDIF

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

END SUBROUTINE TRANS_RELEASE