diff --git a/prep_flexpart/mod_prep_command.f90 b/prep_flexpart/mod_prep_command.f90 index 7020fc5fa6f8445c6027b170aa906bb2e9f27015..52451e899bc9e8fe09590ed882502cf1d4c78680 100644 --- a/prep_flexpart/mod_prep_command.f90 +++ b/prep_flexpart/mod_prep_command.f90 @@ -183,7 +183,7 @@ module mod_prep_command lturbulence = 1 lturbulence_meso = 0 lnetcdfout = 0 - nxshift = 1 + nxshift = 0 maxthreadgrid = 1 maxfilesize = 10000 logvertinterp = 0 diff --git a/prep_flexpart/prep_outgrid.f90 b/prep_flexpart/prep_outgrid.f90 index 8d55f9f8bf6199dd8e07c28cd36a39470670038d..4be6291e1e7fdea36680dcbd875888d69c4784ee 100644 --- a/prep_flexpart/prep_outgrid.f90 +++ b/prep_flexpart/prep_outgrid.f90 @@ -84,7 +84,7 @@ subroutine prep_outgrid(settings, jd, nr) if ( settings%windfield.eq.'oper' ) then outlon0 = -179. else if ( settings%windfield.eq.'era5' ) then - outlon0 = -179. + outlon0 = -179.5 else write(*,*) 'ERROR: prep_outgrid: unknown windfield type' stop diff --git a/prep_flexpart/prep_releases.f90 b/prep_flexpart/prep_releases.f90 index 2dd83d173d853b9f1f79cf8ddc0fa862e296f19a..2cd520c7f26a4f129c08d6c5b29d734f532245cc 100644 --- a/prep_flexpart/prep_releases.f90 +++ b/prep_flexpart/prep_releases.f90 @@ -121,7 +121,7 @@ subroutine prep_releases(settings, jd, nr, nobs, obs) if ( settings%FPversion.eq.10 ) then inquire(file=trim(settings%path_flexpart)//'options/SPECIES/spec_overview',exist=lexist) if ( .not.lexist ) then - write(*,*) 'ERROR: cannot find file /options/SPECIES/spec_overview' + write(*,*) 'ERROR: cannot find file '//trim(settings%path_flexpart)//'options/SPECIES/spec_overview' stop endif open(100,file=trim(settings%path_flexpart)//'options/SPECIES/spec_overview',status='old',action='read',iostat=ierr) @@ -138,29 +138,32 @@ subroutine prep_releases(settings, jd, nr, nobs, obs) inquire(file=trim(settings%path_flexpart)//'options/SPECIES/SPECIES_'//to_upper(trim(settings%species)),& exist=lexist) if ( .not.lexist ) then - write(*,*) 'ERROR: cannot find file /options/SPECIES/SPECIES_'//to_upper(trim(settings%species)) + write(*,*) 'ERROR: cannot find file '& + //trim(settings%path_flexpart)//'options/SPECIES/SPECIES_'//to_upper(trim(settings%species)) stop endif write(aspec,fmt='(I3.3)') spec call system('cp '//trim(settings%path_flexpart)//'options/SPECIES/SPECIES_'//to_upper(trim(settings%species))//& ' '//trim(settings%path_flexpart)//'options/SPECIES/SPECIES_'//aspec) write(aspec,fmt='(I3.3)') spec - ! read SPECIES file for reagents info - allocate(preactions(nreagent)) - allocate(pcconst(nreagent)) - allocate(pdconst(nreagent)) - allocate(pnconst(nreagent)) - open(100,file=trim(settings%path_flexpart)//'options/SPECIES/SPECIES_'//to_upper(trim(settings%species)),& - action='read',iostat=ierr) - read(100,species_params,iostat=ierr) - if ( ierr.ne.0 ) then - write(*,*) 'ERROR: reading SPECIES_'//to_upper(trim(settings%species)) - stop - endif - write(*,*) 'Chemical reactions: ',preactions - if (any(preactions.ne."")) then - ! write reagents file - call prep_reagents(settings,preactions,nr,jd) + if (nreagent.gt.0) then + ! read SPECIES file for reagents info + allocate(preactions(nreagent)) + allocate(pcconst(nreagent)) + allocate(pdconst(nreagent)) + allocate(pnconst(nreagent)) + open(100,file=trim(settings%path_flexpart)//'options/SPECIES/SPECIES_'//to_upper(trim(settings%species)),& + action='read',iostat=ierr) + read(100,species_params,iostat=ierr) + if ( ierr.ne.0 ) then + write(*,*) 'ERROR: reading SPECIES_'//to_upper(trim(settings%species)) + stop + endif + write(*,*) 'Chemical reactions: ',preactions + if (any(preactions.ne."")) then + ! write reagents file + call prep_reagents(settings,preactions,nr,jd) + endif endif endif diff --git a/prep_flexpart/prep_releases_reg.f90 b/prep_flexpart/prep_releases_reg.f90 index 1b2f182476535e30bf646a6c5bd507512f88858d..87b7b4e935d97bb6c8a49f7f9c2bb9c8ef3992a4 100644 --- a/prep_flexpart/prep_releases_reg.f90 +++ b/prep_flexpart/prep_releases_reg.f90 @@ -130,7 +130,7 @@ subroutine prep_releases_reg(settings, jd, nr) if ( settings%FPversion.eq.10 ) then inquire(file=trim(settings%path_flexpart)//'options/SPECIES/spec_overview',exist=lexist) if ( .not.lexist ) then - write(*,*) 'ERROR: cannot fine file /options/SPECIES/spec_overview' + write(*,*) 'ERROR: cannot find file '//trim(settings%path_flexpart)//'options/SPECIES/spec_overview' stop endif open(100,file=trim(settings%path_flexpart)//'options/SPECIES/spec_overview',status='old',action='read',iostat=ierr) @@ -147,29 +147,32 @@ subroutine prep_releases_reg(settings, jd, nr) inquire(file=trim(settings%path_flexpart)//'options/SPECIES/SPECIES_'//to_upper(trim(settings%species)),& exist=lexist) if ( .not.lexist ) then - write(*,*) 'ERROR: cannot find file /options/SPECIES/SPECIES_'//to_upper(trim(settings%species)) + write(*,*) 'ERROR: cannot find file '& + //trim(settings%path_flexpart)//'options/SPECIES/SPECIES_'//to_upper(trim(settings%species)) stop endif write(aspec,fmt='(I3.3)') spec call system('cp '//trim(settings%path_flexpart)//'options/SPECIES/SPECIES_'//to_upper(trim(settings%species))//& ' '//trim(settings%path_flexpart)//'options/SPECIES/SPECIES_'//aspec) write(aspec,fmt='(I3.3)') spec - ! read SPECIES file for reagents info - allocate(preactions(nreagent)) - allocate(pcconst(nreagent)) - allocate(pdconst(nreagent)) - allocate(pnconst(nreagent)) - open(100,file=trim(settings%path_flexpart)//'options/SPECIES/SPECIES_'//to_upper(trim(settings%species)),& - action='read',iostat=ierr) - read(100,species_params,iostat=ierr) - if ( ierr.ne.0 ) then - write(*,*) 'ERROR: reading SPECIES_'//to_upper(trim(settings%species)) - stop - endif - write(*,*) 'Chemical reactions: ',preactions - if (any(preactions.ne."")) then - ! write reagents file - call prep_reagents(settings,preactions,nr,jd) + if (nreagent.gt.0) then + ! read SPECIES file for reagents info + allocate(preactions(nreagent)) + allocate(pcconst(nreagent)) + allocate(pdconst(nreagent)) + allocate(pnconst(nreagent)) + open(100,file=trim(settings%path_flexpart)//'options/SPECIES/SPECIES_'//to_upper(trim(settings%species)),& + action='read',iostat=ierr) + read(100,species_params,iostat=ierr) + if ( ierr.ne.0 ) then + write(*,*) 'ERROR: reading SPECIES_'//to_upper(trim(settings%species)) + stop + endif + write(*,*) 'Chemical reactions: ',preactions + if (any(preactions.ne."")) then + ! write reagents file + call prep_reagents(settings,preactions,nr,jd) + endif endif endif