Changeset c0884a8 in flexpart.git for src/FLEXPART.f90


Ignore:
Timestamp:
Jul 20, 2018, 2:40:39 PM (6 years ago)
Author:
pesei <petra seibert at univie ac at>
Branches:
univie
Children:
7ca2ef4
Parents:
f251e57
Message:

replace CTBTO code for checking type of GRIB

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/FLEXPART.f90

    r77778f8 rc0884a8  
    4040  !       detected metdata format                                              *
    4141  !     - Passed metdata format down to timemanager                            *
     42  !                                                                            *
     43  !  Petra Seibert, 2018-06-26: simplified version met data format detection   *
     44  !                                                                            *
    4245  !*****************************************************************************
    4346  !                                                                            *
     
    5457
    5558  use random_mod, only: gasdev1
    56   use class_gribfile
     59  use check_gribfile_mod
    5760
    5861#ifdef USE_NCF
     
    6265  implicit none
    6366
    64   integer :: i,j,ix,jy,inest
     67  integer :: i,j,ix,jy,inest,id_centre
    6568  integer :: idummy = -320
    6669  character(len=256) :: inline_options  !pathfile, flexversion, arg2
    67   integer :: metdata_format = GRIBFILE_CENTRE_UNKNOWN
    68   integer :: detectformat
    69 
    7070
    7171
     
    190190  ! Detect metdata format
    191191  !**********************
    192 
    193   metdata_format = detectformat()
    194 
    195   if (metdata_format.eq.GRIBFILE_CENTRE_ECMWF) then
    196     print *,'ECMWF metdata detected'
    197   elseif (metdata_format.eq.GRIBFILE_CENTRE_NCEP) then
    198     print *,'NCEP metdata detected'
     192 
     193  call cg_get_centre(path(3)(1:length(3)) // trim(wfname(1)), id_centre)
     194  if (id_centre.eq.icg_id_ecmwf) then
     195    print *,'ECMWF met data detected'
     196  elseif (id_centre.eq.icg_id_ncep) then
     197    print *,'NCEP met data detected'
    199198  else
    200     print *,'Unknown metdata format'
     199    print *,'Unknown met data format'
    201200    stop
    202201  endif
     
    220219  endif
    221220
    222   if (metdata_format.eq.GRIBFILE_CENTRE_ECMWF) then
     221  if (id_centre.eq.icg_id_ecmwf) then
    223222    call gridcheck_ecmwf
    224223  else
     
    449448  endif
    450449
    451   call timemanager(metdata_format)
     450  call timemanager(id_centre)
    452451
    453452! NIK 16.02.2005
Note: See TracChangeset for help on using the changeset viewer.
hosted by ZAMG