Ignore:
Timestamp:
2018-12-14T17:51:51+01:00 (23 months ago)
Author:
clem
Message:

BGC restart should now work in the nesting tool. All of that must of course be tested in realistic simulations. Waiting for the feedbacks…

File:
1 edited

Legend:

Unmodified
Added
Removed
  • utils/tools/NESTING/src/agrif_create_restart.f90

    r10393 r10398  
    4040  CHARACTER*1 :: posvar 
    4141  CHARACTER*100 :: Child_file,Childcoordinates,varname,Child_Bathy_Level,Child_Bathy_Meter    
    42   REAL*8, POINTER, DIMENSION(:,:) :: lonChild,latChild => NULL() 
    43   REAL*8, POINTER, DIMENSION(:,:) :: lonParent,latParent => NULL() 
    44   REAL*8, POINTER, DIMENSION(:,:,:) :: tabvar3d,tabinterp3d,mask => NULL() 
    45   REAL*8, POINTER, DIMENSION(:,:,:) :: fmask,fse3u,fse3v,fse3t => NULL() 
     42  REAL*8, POINTER, DIMENSION(:,:,:) :: tabvar3d => NULL() 
    4643  REAL*8, POINTER, DIMENSION(:,:,:,:) :: un,ub,vn,vb,tn,tb,sn,sb,e3t_n,e3t_b => NULL() 
    4744  REAL*8, POINTER, DIMENSION(:,:,:) :: sshn,sshb => NULL()       
    4845  REAL*8, POINTER, DIMENSION(:,:,:,:) :: tabinterp4d,tabvar1,tabvar2,tabvar3 => NULL() 
    49   REAL*8, POINTER, DIMENSION(:) :: timedepth_temp => NULL() 
    5046  REAL*8, POINTER, DIMENSION(:) :: tabtemp1D,nav_lev => NULL() 
    51   INTEGER, POINTER, DIMENSION(:) :: tabtemp1DInt => NULL() 
    52   REAL*8, POINTER, DIMENSION(:,:) :: tabtemp2D,zwf => NULL() 
    53   REAL*8, POINTER, DIMENSION(:,:) :: e1f,e2f,e1v,e2v,e1u,e2u,e1t,e2t => NULL() 
     47  REAL*8, POINTER, DIMENSION(:,:) :: tabtemp2D => NULL() 
    5448  REAL*8, POINTER, DIMENSION(:,:,:,:) :: tabtemp4D => NULL() 
    5549  INTEGER,DIMENSION(:),POINTER :: src_add,dst_add  => NULL() 
    56   REAL*8,DIMENSION(:,:),POINTER :: matrix,bathy_G0 => NULL() 
    57   LOGICAL,DIMENSION(:,:,:),POINTER :: Tmask => NULL() 
     50  REAL*8,DIMENSION(:,:),POINTER :: matrix => NULL() 
    5851  LOGICAL,DIMENSION(:,:),POINTER :: masksrc => NULL() 
    5952  LOGICAL, DIMENSION(:,:,:), POINTER :: detected_pts 
    60   LOGICAL :: Interpolation,Extrapolation,Pacifique,op 
    61   REAL*8 :: za1,za0,zsur,zacr,zkth,zdepth,zdepwp,zmin,zmax,zdiff,ze3tp,ze3wp        
    62   INTEGER :: narg,iargc,ncid,x,y,z,z_a,x_a,y_a,z_b,nbvert_lev,m 
     53  LOGICAL :: Interpolation,Extrapolation,Pacifique 
     54  INTEGER :: narg,iargc,ncid,x,y,z,z_a,x_a,y_a,z_b,nbvert_lev 
    6355  REAL*8 :: now_wght,before_wght 
    64   INTEGER :: i,j,k,status,ji,jj 
     56  INTEGER :: status,ii,jk 
    6557  CHARACTER(len=20),DIMENSION(4) :: dimnames 
    6658  CHARACTER(len=80) :: namelistname 
    6759  TYPE(Coordinates) :: G0,G1 
    68   INTEGER :: jpi,jpj,jpk,jpni,jpnj,jpnij,jpiglo,jpjglo,nlcit,nlcjt,nldit 
    69   INTEGER :: nldjt,nleit,nlejt,nimppt,njmppt 
    7060  REAL*8 :: tabtemp0dreal 
    71   INTEGER :: tabtemp0dint 
    7261  CHARACTER(len=20) :: timedimname 
    7362 
    7463  LOGICAL, PARAMETER :: conservation = .FALSE. 
    7564  !       
    76   ! Variables for dimg 
    77   !  
    78 !  INTEGER :: ino0, it0, ipcg0, isor0, itke0,nfice,nfbulk 
    79 !  INTEGER :: irecl8, irec,ndastp,narea,nsolv 
    80 !  INTEGER :: jk,kt            ! dummy loop indices 
    81 !  INTEGER :: inum             ! temporary logical unit 
    82 !  INTEGER :: ios1 , ios2      ! flag for ice and bulk in the current run 
    83 !  INTEGER :: ios3             ! flag for free surface.  0 = none 1 = yes.  0 = none 1 = yes 
    84 !  INTEGER :: ios4             ! flag for coupled (1) or not (0)     
    8565  !        
    8666  narg = iargc() 
     
    182162  G0%tmask = 1.     
    183163 
    184   DO k=1,z 
     164  DO jk=1,z 
    185165     ALLOCATE(tabvar1(x,y,1,1)) 
    186      CALL Read_Ncdf_var('sn',TRIM(restart_file),tabvar1,1,k) 
     166     CALL Read_Ncdf_var('sn',TRIM(restart_file),tabvar1,1,jk) 
    187167     WHERE( tabvar1(:,:,1,1) == 0. )  
    188         G0%tmask(:,:,k) = 0. 
     168        G0%tmask(:,:,jk) = 0. 
    189169     END WHERE 
    190170     DEALLOCATE(tabvar1) 
     
    219199  ! 
    220200  ! 
    221   DO ji = 1,SIZE(Ncdf_varname)       
     201  DO ii = 1,SIZE(Ncdf_varname)       
    222202     !       
    223203     ! loop on variables names 
    224      varname = TRIM(Ncdf_varname(ji)) 
     204     varname = TRIM(Ncdf_varname(ii)) 
    225205     WRITE(*,*) 'var = ',TRIM(varname)      
    226206     !       
Note: See TracChangeset for help on using the changeset viewer.