New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
Changeset 1955 – NEMO

Changeset 1955


Ignore:
Timestamp:
2010-06-25T09:58:46+02:00 (14 years ago)
Author:
sga
Message:

NEMO trunk: fldread.F90
change extent of data read in from weights file to jpi,jpj so output array has valid value everywhere
see ticket #583

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/NEMO/OPA_SRC/SBC/fldread.F90

    r1826 r1955  
    815815            WRITE(aname,'(a3,i2.2)') 'src',jn 
    816816            data_tmp(:,:) = 0 
    817             CALL iom_get ( inum, jpdom_unknown, aname, data_tmp(1:nlci,1:nlcj), & 
    818                            kstart=(/nimpp,njmpp/), kcount=(/nlci,nlcj/) ) 
     817            CALL iom_get ( inum, jpdom_data, aname, data_tmp(:,:) ) 
    819818            data_src(:,:) = INT(data_tmp(:,:)) 
    820819            ref_wgts(nxt_wgt)%data_jpj(:,:,jn) = 1 + (data_src(:,:)-1) / ref_wgts(nxt_wgt)%ddims(1) 
     
    825824            aname = ' ' 
    826825            WRITE(aname,'(a3,i2.2)') 'wgt',jn 
    827             ref_wgts(nxt_wgt)%data_wgt(1:nlci,1:nlcj,jn) = 0.0 
    828             CALL iom_get ( inum, jpdom_unknown, aname, ref_wgts(nxt_wgt)%data_wgt(1:nlci,1:nlcj,jn), & 
    829                            kstart=(/nimpp,njmpp/), kcount=(/nlci,nlcj/) ) 
     826            ref_wgts(nxt_wgt)%data_wgt(:,:,jn) = 0.0 
     827            CALL iom_get ( inum, jpdom_data, aname, ref_wgts(nxt_wgt)%data_wgt(:,:,jn) ) 
    830828         END DO 
    831829         CALL iom_close (inum) 
    832830  
    833831         ! find min and max indices in grid 
    834          ref_wgts(nxt_wgt)%botleft(1) = MINVAL(ref_wgts(nxt_wgt)%data_jpi(1:nlci,1:nlcj,:)) 
    835          ref_wgts(nxt_wgt)%botleft(2) = MINVAL(ref_wgts(nxt_wgt)%data_jpj(1:nlci,1:nlcj,:)) 
    836          ref_wgts(nxt_wgt)%topright(1) = MAXVAL(ref_wgts(nxt_wgt)%data_jpi(1:nlci,1:nlcj,:)) 
    837          ref_wgts(nxt_wgt)%topright(2) = MAXVAL(ref_wgts(nxt_wgt)%data_jpj(1:nlci,1:nlcj,:)) 
     832         ref_wgts(nxt_wgt)%botleft(1) = MINVAL(ref_wgts(nxt_wgt)%data_jpi(:,:,:)) 
     833         ref_wgts(nxt_wgt)%botleft(2) = MINVAL(ref_wgts(nxt_wgt)%data_jpj(:,:,:)) 
     834         ref_wgts(nxt_wgt)%topright(1) = MAXVAL(ref_wgts(nxt_wgt)%data_jpi(:,:,:)) 
     835         ref_wgts(nxt_wgt)%topright(2) = MAXVAL(ref_wgts(nxt_wgt)%data_jpj(:,:,:)) 
    838836 
    839837         ! and therefore dimensions of the input box 
Note: See TracChangeset for help on using the changeset viewer.