MODULE YOMCOSJR

USE PARKIND1  ,ONLY : JPRB

IMPLICIT NONE

SAVE

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

!*    Cost function management for a reference (for data assimilation)

! FALTSEL  :  1 IF VALUE TO BE CONSIDERED FOR THE MINIMIZATION
!                    0 IF NOT
! FSURSEL  :  AS FALTSEL

! - Cost function splitted by wave number.

! FSPALT(.,.,JM)  :  VALUE OF THE COST-FUNCTION (BY LOCAL WAVE NUMBER)
! FSPSUR(.,JM)    :  AS FSPALT BUT FOR SURFACE FIELDS

!     REAL FALTSEL(NFLEVG,NF3D)
!     REAL FSURSEL(NFD2D)

!     REAL FSPALT(NFLEVL,NF3D,NUMP)
!     REAL FSPSUR(NFD2D,NUMP)

REAL(KIND=JPRB),ALLOCATABLE:: FALTSEL(:,:)
REAL(KIND=JPRB),ALLOCATABLE:: FSURSEL(:)

REAL(KIND=JPRB),ALLOCATABLE:: FSPALT(:,:,:)
REAL(KIND=JPRB),ALLOCATABLE:: FSPSUR(:,:)

!     ------------------------------------------------------------------
END MODULE YOMCOSJR
