Changeset 12591 for NEMO/branches/2020/ticket2377/src/OCE/SBC/sbcfwb.F90
- Timestamp:
- 2020-03-24T11:21:58+01:00 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
NEMO/branches/2020/ticket2377/src/OCE/SBC/sbcfwb.F90
r12489 r12591 24 24 ! 25 25 USE in_out_manager ! I/O manager 26 USE iom ! IOM 26 27 USE lib_mpp ! distribued memory computing library 27 28 USE timing ! Timing … … 115 116 IF( kt == nit000 ) THEN ! initialisation 116 117 ! ! Read the corrective factor on precipitations (fwfold) 117 CALL ctl_opn( inum, 'EMPave_old.dat', 'OLD', 'FORMATTED', 'SEQUENTIAL', -1, numout, .FALSE. ) 118 READ ( inum, "(24X,I8,2ES24.16)" ) iyear, a_fwb_b, a_fwb 119 CLOSE( inum ) 118 IF ( ln_rstart .AND. iom_varid( numror, 'a_fwb_b', ldstop = .FALSE. ) > 0 & 119 & .AND. iom_varid( numror, 'a_fwb', ldstop = .FALSE. ) > 0 ) THEN 120 IF(lwp) WRITE(numout,*) 'sbc_fwb : reading FW-budget adjustment from restart file' 121 CALL iom_get( numror, 'a_fwb_b', a_fwb_b ) 122 CALL iom_get( numror, 'a_fwb', a_fwb ) 123 ELSE 124 CALL ctl_opn( inum, 'EMPave_old.dat', 'OLD', 'FORMATTED', 'SEQUENTIAL', -1, numout, .FALSE. ) 125 READ ( inum, "(24X,I8,2ES24.16)" ) iyear, a_fwb_b, a_fwb 126 CLOSE( inum ) 127 END IF 120 128 fwfold = a_fwb ! current year freshwater budget correction 121 129 ! ! estimate from the previous year budget … … 142 150 qns(:,:) = qns(:,:) - zcoef * sst_m(:,:) * tmask(:,:,1) ! account for change to the heat budget due to fw correction 143 151 ENDIF 152 ! Output restart information 153 IF( lrst_oce ) THEN 154 IF(lwp) WRITE(numout,*) 155 IF(lwp) WRITE(numout,*) 'sbc_fwb : writing FW-budget adjustment to ocean restart file at it = ', kt 156 IF(lwp) WRITE(numout,*) '~~~~' 157 CALL iom_rstput( kt, nitrst, numrow, 'a_fwb_b', a_fwb_b ) 158 CALL iom_rstput( kt, nitrst, numrow, 'a_fwb', a_fwb ) 159 END IF 144 160 ! 145 161 IF( kt == nitend .AND. lwm ) THEN ! save fwfold value in a file (only one required)
Note: See TracChangeset
for help on using the changeset viewer.