Changeset 623
- Timestamp:
- 2007-02-26T18:26:08+01:00 (17 years ago)
- Location:
- trunk/NEMO/OPA_SRC
- Files:
-
- 11 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/NEMO/OPA_SRC/DIA/diafwb.F90
r474 r623 67 67 68 68 !! * Local declarations 69 INTEGER :: inum ! temporary logical unit 69 70 INTEGER :: ji, jj, jk, jt ! dummy loop indices 70 71 INTEGER :: ii0, ii1, ij0, ij1 … … 387 388 IF ( kt == nitend ) THEN 388 389 389 OPEN(111,FILE='STRAIT.dat') 390 WRITE(111,*) 391 WRITE(111,*) 'Net freshwater budget ' 392 WRITE(111,9010) ' emp = ',a_emp, ' m3 =', a_emp /(FLOAT(nitend-nit000+1)*rdttra(1)) * 1.e-6,' Sv' 393 WRITE(111,9010) ' precip = ',a_precip,' m3 =', a_precip/(FLOAT(nitend-nit000+1)*rdttra(1)) * 1.e-6,' Sv' 394 WRITE(111,9010) ' a_rnf = ',a_rnf, ' m3 =', a_rnf /(FLOAT(nitend-nit000+1)*rdttra(1)) * 1.e-6,' Sv' 395 WRITE(111,*) 396 WRITE(111,9010) ' zarea =',zarea 397 WRITE(111,9010) ' zvol =',zvol 398 WRITE(111,*) 399 WRITE(111,*) 'Mean sea level : ' 400 WRITE(111,9010) ' at nit000 = ',a_sshb ,' m3 ' 401 WRITE(111,9010) ' at nitend = ',a_sshn ,' m3 ' 402 WRITE(111,9010) ' diff = ',(a_sshn-a_sshb),' m3 =', (a_sshn-a_sshb)/(FLOAT(nitend-nit000+1)*rdt) * 1.e-6,' Sv' 403 WRITE(111,9020) ' mean sea level elevation =', a_sshn/zarea,' m' 404 WRITE(111,*) 405 WRITE(111,*) 'Anomaly of salinity content : ' 406 WRITE(111,9010) ' at nit000 = ',a_salb ,' psu.m3 ' 407 WRITE(111,9010) ' at nitend = ',a_saln ,' psu.m3 ' 408 WRITE(111,9010) ' diff = ',(a_saln-a_salb),' psu.m3' 409 WRITE(111,*) 410 WRITE(111,*) 'Mean salinity : ' 411 WRITE(111,9020) ' at nit000 =',a_salb/zvol+zsm0 ,' psu ' 412 WRITE(111,9020) ' at nitend =',a_saln/zvol+zsm0 ,' psu ' 413 WRITE(111,9020) ' diff =',(a_saln-a_salb)/zvol,' psu' 414 WRITE(111,9020) ' S-SLevitus=',a_saln/zvol,' psu' 415 WRITE(111,*) 416 WRITE(111,*) 'Coeff : ' 417 WRITE(111,9030) ' Alpha+ = ', a_aplus 418 WRITE(111,9030) ' Alpha- = ', a_aminus 419 WRITE(111,*) 420 WRITE(111,*) 421 WRITE(111,*) 'Gibraltar : ' 422 WRITE(111,9030) ' Flux entrant (Sv) :', a_flxi(1) 423 WRITE(111,9030) ' Flux sortant (Sv) :', a_flxo(1) 424 WRITE(111,9030) ' T entrant (deg) :', a_temi(1) 425 WRITE(111,9030) ' T sortant (deg) :', a_temo(1) 426 WRITE(111,9030) ' S entrant (psu) :', a_sali(1) 427 WRITE(111,9030) ' S sortant (psu) :', a_salo(1) 428 WRITE(111,*) 429 WRITE(111,*) 'Cadiz : ' 430 WRITE(111,9030) ' Flux entrant (Sv) :', a_flxi(2) 431 WRITE(111,9030) ' Flux sortant (Sv) :', a_flxo(2) 432 WRITE(111,9030) ' T entrant (deg) :', a_temi(2) 433 WRITE(111,9030) ' T sortant (deg) :', a_temo(2) 434 WRITE(111,9030) ' S entrant (psu) :', a_sali(2) 435 WRITE(111,9030) ' S sortant (psu) :', a_salo(2) 436 WRITE(111,*) 437 WRITE(111,*) 'Bab el Mandeb : ' 438 WRITE(111,9030) ' Flux entrant (Sv) :', a_flxi(3) 439 WRITE(111,9030) ' Flux sortant (Sv) :', a_flxo(3) 440 WRITE(111,9030) ' T entrant (deg) :', a_temi(3) 441 WRITE(111,9030) ' T sortant (deg) :', a_temo(3) 442 WRITE(111,9030) ' S entrant (psu) :', a_sali(3) 443 WRITE(111,9030) ' S sortant (psu) :', a_salo(3) 444 WRITE(111,*) 445 WRITE(111,*) 'Baltic : ' 446 WRITE(111,9030) ' Flux entrant (Sv) :', a_flxi(4) 447 WRITE(111,9030) ' Flux sortant (Sv) :', a_flxo(4) 448 WRITE(111,9030) ' T entrant (deg) :', a_temi(4) 449 WRITE(111,9030) ' T sortant (deg) :', a_temo(4) 450 WRITE(111,9030) ' S entrant (psu) :', a_sali(4) 451 WRITE(111,9030) ' S sortant (psu) :', a_salo(4) 452 CLOSE(111) 390 CALL ctlopn( inum, 'STAIT.dat', 'UNKNOWN', 'FORMATTED', 'SEQUENTIAL', & 391 & 1, numout, .TRUE., 1 ) 392 WRITE(inum,*) 393 WRITE(inum,*) 'Net freshwater budget ' 394 WRITE(inum,9010) ' emp = ',a_emp, ' m3 =', a_emp /(FLOAT(nitend-nit000+1)*rdttra(1)) * 1.e-6,' Sv' 395 WRITE(inum,9010) ' precip = ',a_precip,' m3 =', a_precip/(FLOAT(nitend-nit000+1)*rdttra(1)) * 1.e-6,' Sv' 396 WRITE(inum,9010) ' a_rnf = ',a_rnf, ' m3 =', a_rnf /(FLOAT(nitend-nit000+1)*rdttra(1)) * 1.e-6,' Sv' 397 WRITE(inum,*) 398 WRITE(inum,9010) ' zarea =',zarea 399 WRITE(inum,9010) ' zvol =',zvol 400 WRITE(inum,*) 401 WRITE(inum,*) 'Mean sea level : ' 402 WRITE(inum,9010) ' at nit000 = ',a_sshb ,' m3 ' 403 WRITE(inum,9010) ' at nitend = ',a_sshn ,' m3 ' 404 WRITE(inum,9010) ' diff = ',(a_sshn-a_sshb),' m3 =', (a_sshn-a_sshb)/(FLOAT(nitend-nit000+1)*rdt) * 1.e-6,' Sv' 405 WRITE(inum,9020) ' mean sea level elevation =', a_sshn/zarea,' m' 406 WRITE(inum,*) 407 WRITE(inum,*) 'Anomaly of salinity content : ' 408 WRITE(inum,9010) ' at nit000 = ',a_salb ,' psu.m3 ' 409 WRITE(inum,9010) ' at nitend = ',a_saln ,' psu.m3 ' 410 WRITE(inum,9010) ' diff = ',(a_saln-a_salb),' psu.m3' 411 WRITE(inum,*) 412 WRITE(inum,*) 'Mean salinity : ' 413 WRITE(inum,9020) ' at nit000 =',a_salb/zvol+zsm0 ,' psu ' 414 WRITE(inum,9020) ' at nitend =',a_saln/zvol+zsm0 ,' psu ' 415 WRITE(inum,9020) ' diff =',(a_saln-a_salb)/zvol,' psu' 416 WRITE(inum,9020) ' S-SLevitus=',a_saln/zvol,' psu' 417 WRITE(inum,*) 418 WRITE(inum,*) 'Coeff : ' 419 WRITE(inum,9030) ' Alpha+ = ', a_aplus 420 WRITE(inum,9030) ' Alpha- = ', a_aminus 421 WRITE(inum,*) 422 WRITE(inum,*) 423 WRITE(inum,*) 'Gibraltar : ' 424 WRITE(inum,9030) ' Flux entrant (Sv) :', a_flxi(1) 425 WRITE(inum,9030) ' Flux sortant (Sv) :', a_flxo(1) 426 WRITE(inum,9030) ' T entrant (deg) :', a_temi(1) 427 WRITE(inum,9030) ' T sortant (deg) :', a_temo(1) 428 WRITE(inum,9030) ' S entrant (psu) :', a_sali(1) 429 WRITE(inum,9030) ' S sortant (psu) :', a_salo(1) 430 WRITE(inum,*) 431 WRITE(inum,*) 'Cadiz : ' 432 WRITE(inum,9030) ' Flux entrant (Sv) :', a_flxi(2) 433 WRITE(inum,9030) ' Flux sortant (Sv) :', a_flxo(2) 434 WRITE(inum,9030) ' T entrant (deg) :', a_temi(2) 435 WRITE(inum,9030) ' T sortant (deg) :', a_temo(2) 436 WRITE(inum,9030) ' S entrant (psu) :', a_sali(2) 437 WRITE(inum,9030) ' S sortant (psu) :', a_salo(2) 438 WRITE(inum,*) 439 WRITE(inum,*) 'Bab el Mandeb : ' 440 WRITE(inum,9030) ' Flux entrant (Sv) :', a_flxi(3) 441 WRITE(inum,9030) ' Flux sortant (Sv) :', a_flxo(3) 442 WRITE(inum,9030) ' T entrant (deg) :', a_temi(3) 443 WRITE(inum,9030) ' T sortant (deg) :', a_temo(3) 444 WRITE(inum,9030) ' S entrant (psu) :', a_sali(3) 445 WRITE(inum,9030) ' S sortant (psu) :', a_salo(3) 446 WRITE(inum,*) 447 WRITE(inum,*) 'Baltic : ' 448 WRITE(inum,9030) ' Flux entrant (Sv) :', a_flxi(4) 449 WRITE(inum,9030) ' Flux sortant (Sv) :', a_flxo(4) 450 WRITE(inum,9030) ' T entrant (deg) :', a_temi(4) 451 WRITE(inum,9030) ' T sortant (deg) :', a_temo(4) 452 WRITE(inum,9030) ' S entrant (psu) :', a_sali(4) 453 WRITE(inum,9030) ' S sortant (psu) :', a_salo(4) 454 CLOSE(inum) 453 455 ENDIF 454 456 -
trunk/NEMO/OPA_SRC/FLO/floats.F90
r247 r623 99 99 100 100 !! * Local declarations 101 NAMELIST/namflo/ ln_rstflo, nwritefl, nstockfl 101 NAMELIST/namflo/ ln_rstflo, nwritefl, nstockfl, ln_argo, ln_flork4 102 102 !!--------------------------------------------------------------------- 103 103 ! Namelist namflo : floats … … 118 118 WRITE(numout,*) ' frequency of float output file nwritefl = ', nwritefl 119 119 WRITE(numout,*) ' frequency of float restart file nstockfl = ', nstockfl 120 WRITE(numout,*) ' Argo type floats ln_argo = ', ln_argo 121 WRITE(numout,*) ' Computation of T trajectories ln_flork4 = ', ln_flork4 120 122 WRITE(numout,*) ' ' 121 123 ENDIF -
trunk/NEMO/OPA_SRC/FLO/floblk.F90
r466 r623 25 25 !! * Accessibility 26 26 PUBLIC flo_blk ! routine called by floats.F90 27 28 !! * Substitutions 29 # include "domzgr_substitute.h90" 27 30 !!---------------------------------------------------------------------- 28 31 !! OPA 9.0 , LOCEAN-IPSL (2005) … … 127 130 ! for a isobar float zsurfz is put to zero. The vertical velocity will be zero too. 128 131 zsurfz = e1t(iiloc(jfl),ijloc(jfl)) * e2t(iiloc(jfl),ijloc(jfl)) 129 zvol = zsurfz * fse3t(iiloc(jfl),ijloc(jfl),-ikl(jfl)) )132 zvol = zsurfz * fse3t(iiloc(jfl),ijloc(jfl),-ikl(jfl)) 130 133 131 134 ! -
trunk/NEMO/OPA_SRC/FLO/flodom.F90
r283 r623 50 50 INTEGER :: ji, jj, jk ! DO loop index on 3 directions 51 51 INTEGER :: jfl, jfl1 ! number of floats 52 INTEGER :: inum = 11! logical unit for file read52 INTEGER :: inum ! logical unit for file read 53 53 INTEGER, DIMENSION ( jpnfl ) :: & 54 54 iimfl, ijmfl, ikmfl, & ! index mesh of floats … … 69 69 ! open the restart file 70 70 clname='restart_float' 71 OPEN (inum,FILE=clname,FORM='UNFORMATTED') 71 CALL ctlopn( inum, clname, 'OLD', 'FORMATTED', 'SEQUENTIAL', & 72 & 1, numout, .TRUE., 1 ) 72 73 REWIND inum 73 74 … … 94 95 ! open the init file 95 96 clname='init_float' 96 OPEN(inum,FILE=clname,FORM='FORMATTED') 97 CALL ctlopn( inum, clname, 'OLD', 'FORMATTED', 'SEQUENTIAL', & 98 & 1, numout, .TRUE., 1 ) 97 99 DO jfl = jpnrstflo+1, jpnfl 98 100 READ(inum,*) flxx(jfl),flyy(jfl),flzz(jfl), nisobfl(jfl),ngrpfl(jfl),jfl1 … … 225 227 ! open the init file 226 228 clname='init_float' 227 OPEN(inum,FILE=clname,FORM='FORMATTED') 229 CALL ctlopn( inum, clname, 'OLD', 'FORMATTED', 'SEQUENTIAL', & 230 & 1, numout, .TRUE., 1 ) 228 231 READ(inum) (flxx(jfl) , jfl=1, jpnfl), & 229 232 (flyy(jfl) , jfl=1, jpnfl), & -
trunk/NEMO/OPA_SRC/FLO/flowri.F90
r247 r623 56 56 !! * Local declarations 57 57 CHARACTER (len=21) :: clname 58 INTEGER :: inum = 11! temporary logical unit for restart file58 INTEGER :: inum ! temporary logical unit for restart file 59 59 INTEGER :: & 60 60 iafl,ibfl,icfl,ia1fl,ib1fl,ic1fl,jfl,irecflo, & … … 81 81 ! open the file numflo 82 82 clname='trajec_float' 83 OPEN (numflo,FILE=clname,FORM='UNFORMATTED') 83 CALL ctlopn( numflo, clname, 'UNKNOWN', 'UNFORMATTED', 'SEQUENTIAL', & 84 & 1, numout, .FALSE., 1 ) 84 85 ! REWIND numflo 85 86 … … 141 142 ! these 2 lines have accendentaly been removed from ATL6-V8 run hence 142 143 ! giving 0 salinity and temperature on the float trajectory 143 CALL mpp_sum( ztemp, jpk*jpnfl ) 144 CALL mpp_sum( zsal , jpk*jpnfl ) 144 !bug RB 145 !compilation failed in mpp 146 ! CALL mpp_sum( ztemp, jpk*jpnfl ) 147 ! CALL mpp_sum( zsal , jpk*jpnfl ) 145 148 146 149 ELSE … … 266 269 END DO 267 270 268 OPEN (inum,FILE=clname,FORM='UNFORMATTED') 271 CALL ctlopn( inum, clname, 'UNKNOWN', 'FORMATTED', 'SEQUENTIAL', & 272 & 1, numout, .FALSE., 0 ) 269 273 REWIND inum 270 274 ! -
trunk/NEMO/OPA_SRC/IOM/in_out_manager.F90
r596 r623 58 58 INTEGER :: numstp = 1 !: logical unit for time step 59 59 INTEGER :: numout = 2 !: logical unit for output print 60 INTEGER :: numid !: logical unit for debug print 60 61 INTEGER :: numnam = 3 !: logical unit for namelist 61 62 INTEGER :: numnam_ice = 4 !: logical unit for ice namelist -
trunk/NEMO/OPA_SRC/LDF/ldfdyn_c2d.h90
r247 r623 139 139 !! * Local variables 140 140 INTEGER :: ji, jj, jn ! dummy loop indices 141 INTEGER :: inum = 11! temporary logical unit142 INTEGER :: i ost, iim, ijm141 INTEGER :: inum ! temporary logical unit 142 INTEGER :: iim, ijm 143 143 INTEGER :: ifreq, il1, il2, ij, ii 144 144 INTEGER, DIMENSION(jpidta,jpidta) :: idata … … 165 165 ! ===================== equatorial strip (20N-20S) defined at t-points 166 166 167 OPEN( UNIT=inum, FILE='ahmcoef', STATUS='OLD', & 168 & FORM='FORMATTED', ACCESS='SEQUENTIAL', ERR=111 , & 169 & IOSTAT= iost ) 170 IF( iost == 0 ) THEN 171 IF(lwp) WRITE(numout,*) ' file : ahmcoef open ok' 172 IF(lwp) WRITE(numout,*) ' unit = ', inum 173 IF(lwp) WRITE(numout,*) ' status = OLD' 174 IF(lwp) WRITE(numout,*) ' form = FORMATTED' 175 IF(lwp) WRITE(numout,*) ' access = SEQUENTIAL' 176 IF(lwp) WRITE(numout,*) 177 ENDIF 178 111 CONTINUE 179 IF( iost /= 0 ) THEN 180 IF(lwp) WRITE(numout,*) 181 IF(lwp) WRITE(numout,*) ' ===>>>> : bad opening file: ahmcoef' 182 IF(lwp) WRITE(numout,*) ' ======= === ' 183 IF(lwp) WRITE(numout,*) ' we stop. verify the file ' 184 IF(lwp) WRITE(numout,*) 185 STOP 'ldfdyn_c2d.h90' 186 ENDIF 187 167 CALL ctlopn( inum, 'ahmcoef', 'UNKNOWN', 'FORMATTED', 'SEQUENTIAL', & 168 & 1, numout, .TRUE., 1 ) 188 169 REWIND inum 189 170 READ(inum,9101) clexp, iim, ijm -
trunk/NEMO/OPA_SRC/LDF/ldfdyn_c3d.h90
r473 r623 197 197 INTEGER :: ji, jj, jk, jn ! dummy loop indices 198 198 INTEGER :: ii0, ii1, ij0, ij1 ! temporary integers 199 INTEGER :: inum = 11! temporary logical unit200 INTEGER :: i ost, iim, ijm199 INTEGER :: inum ! temporary logical unit 200 INTEGER :: iim, ijm 201 201 INTEGER :: ifreq, il1, il2, ij, ii 202 202 INTEGER, DIMENSION(jpidta, jpjdta) :: idata … … 223 223 ! ===================== equatorial strip (20N-20S) defined at t-points 224 224 225 OPEN( UNIT=inum, FILE='ahmcoef', STATUS='OLD', & 226 & FORM='FORMATTED', ACCESS='SEQUENTIAL', ERR=111 , & 227 & IOSTAT= iost) 228 IF( iost == 0 ) THEN 229 IF(lwp) THEN 230 WRITE(numout,*) ' file : ahmcoef open ok' 231 WRITE(numout,*) ' unit = ', inum 232 WRITE(numout,*) ' status = OLD' 233 WRITE(numout,*) ' form = FORMATTED' 234 WRITE(numout,*) ' access = SEQUENTIAL' 235 WRITE(numout,*) 236 ENDIF 237 ENDIF 238 111 CONTINUE 239 IF( iost /= 0 ) CALL ctl_stop( ' ', & 240 & ' ===>>>> : bad opening file: ahmcoef, verify the file ahmcoef', & 241 & ' ======= === ' ) 225 CALL ctlopn( inum, 'ahmcoef', 'UNKNOWN', 'FORMATTED', 'SEQUENTIAL', & 226 & 1, numout, .TRUE., 1 ) 242 227 REWIND inum 243 228 READ(inum,9101) clexp, iim, ijm -
trunk/NEMO/OPA_SRC/OBC/obcdta.F90
r591 r623 608 608 !! * Local declarations 609 609 INTEGER :: ji, jj, jnic, jip ! dummy loop indices 610 INTEGER :: inum = 11! temporary logical unit610 INTEGER :: inum ! temporary logical unit 611 611 INTEGER :: ip, ii, ij, iii, ijj 612 612 INTEGER :: kbsfstart … … 673 673 674 674 IF( kt == nit000 .OR. kt <= kbsfstart ) THEN 675 OPEN(inum,file='obceastbsf.dta') 675 CALL ctlopn( inum, 'obceastbsf.dta', 'UNKNOWN', 'FORMATTED', 'SEQUENTIAL', & 676 & 1, numout, .TRUE., 1 ) 676 677 READ(inum,*) 677 678 READ(inum,*) … … 691 692 692 693 IF( kt == nit000 .OR. kt <= kbsfstart ) then 693 OPEN(inum,file='obcwestbsf.dta') 694 CALL ctlopn( inum, 'obcwestbsf.dta', 'UNKNOWN', 'FORMATTED', 'SEQUENTIAL', & 695 & 1, numout, .TRUE., 1 ) 694 696 READ(inum,*) 695 697 READ(inum,*) … … 709 711 710 712 IF( kt == nit000 .OR. kt <= kbsfstart ) THEN 711 OPEN(inum,file='obcsouthbsf.dta') 713 CALL ctlopn( inum, 'obcsouthbsf.dta', 'UNKNOWN', 'FORMATTED', 'SEQUENTIAL', & 714 & 1, numout, .TRUE., 1 ) 712 715 READ(inum,*) 713 716 READ(inum,*) … … 726 729 IF( lpnorthobc) THEN 727 730 IF( kt == nit000 .OR. kt <= kbsfstart ) THEN 728 OPEN(inum,file='obcnorthbsf.dta') 731 CALL ctlopn( inum, 'obcnorthbsf.dta', 'UNKNOWN', 'FORMATTED', 'SEQUENTIAL', & 732 & 1, numout, .TRUE., 1 ) 729 733 READ(inum,*) 730 734 READ(inum,*) -
trunk/NEMO/OPA_SRC/OBC/obcrst.F90
r474 r623 66 66 67 67 !! * Local declarations 68 INTEGER :: ji, jj, jk , ios69 INTEGER :: inum = 11! temporary logical unit68 INTEGER :: ji, jj, jk 69 INTEGER :: inum ! temporary logical unit 70 70 INTEGER :: ibloc, nreclo, jrec, jt, jb 71 71 INTEGER :: jfoe, jfow, ifon, ifos … … 96 96 ! 1.1 Open file 97 97 ! ------------- 98 OPEN( UNIT = inum, & 99 IOSTAT = ios, & 100 FILE = 'restart.obc.output', & 101 ACCESS = 'DIRECT', & 102 RECL = nreclo, & 103 FORM = 'UNFORMATTED' ) 104 IF( ios > 0 ) CALL ctl_stop( ' Pbm to OPEN the restart.obc.output file ' ) 98 99 CALL ctlopn( inum, 'restart.obc.output', 'UNKNOWN', 'UNFORMATTED', 'DIRECT', & 100 & nreclo, numout, .TRUE., 1 ) 105 101 106 102 ! 1.2 Write header … … 352 348 ! 0.1 Open files 353 349 ! --------------- 354 OPEN( UNIT = inum, & 355 IOSTAT = ios, & 356 FILE = 'restart.obc', & 357 ACCESS = 'DIRECT', & 358 RECL = nreclo, & 359 FORM = 'UNFORMATTED' ) 360 IF( ios > 0 ) CALL ctl_stop( ' Pbm to OPEN the restart.obc file ' ) 350 CALL ctlopn( inum, 'restart.obc.output', 'UNKNOWN', 'UNFORMATTED', 'DIRECT', & 351 & nreclo, numout, .TRUE., 1 ) 361 352 362 353 ! 1. Read -
trunk/NEMO/OPA_SRC/SBC/flxfwb.F90
r622 r623 80 80 81 81 !! * Local declarations 82 CHARACTER (len=32) :: & 83 clname = 'EMPav.dat' 82 84 INTEGER :: ji, jj, jk ! dummy loop indices 83 INTEGER :: inum = 11! temporary logical unit85 INTEGER :: inum ! temporary logical unit 84 86 INTEGER :: ikty ! 85 87 REAL(wp) :: & … … 194 196 IF( kt == nitend ) THEN 195 197 196 OPEN( inum, FILE='EMPave.dat' ) 198 CALL ctlopn( inum, clname, 'UNKNOWN', 'FORMATTED', 'SEQUENTIAL', & 199 & 1, numout, .FALSE., 0 ) 197 200 WRITE(inum, "(24X,I8,2ES24.16)" ) nyear, a_fwb_b, a_fwb 198 201 WRITE(inum,*) … … 249 252 !!---------------------------------------------------------------------- 250 253 !! * Local declarations 251 LOGICAL :: llbon252 254 CHARACTER (len=32) :: & 253 255 clname = 'EMPave_old.dat' 254 INTEGER :: inum = 11 ! temporary logical unit 255 INTEGER :: iyear 256 INTEGER :: inum, iyear 256 257 257 258 NAMELIST/namfwb/ ln_fwb … … 290 291 ! ! ============================== 291 292 ! Read the corrective factor on precipitations (empold) 292 INQUIRE( FILE=clname, EXIST=llbon ) 293 IF( llbon ) THEN 294 OPEN ( inum, FILE=clname) 295 READ ( inum, "(24X,I8,2ES24.16)" ) iyear, a_fwb_b, a_fwb 296 CLOSE( inum ) 297 empold = a_fwb ! current year freshwater budget correction 298 ! ! estimate from the previous year budget 299 IF(lwp)WRITE(numout,*) 300 IF(lwp)WRITE(numout,*)'flx_fwb_init : year = ',iyear , ' freshwater budget correction = ', empold 301 IF(lwp)WRITE(numout,*)' year = ',iyear-1, ' freshwater budget read = ', a_fwb 302 IF(lwp)WRITE(numout,*)' year = ',iyear-2, ' freshwater budget read = ', a_fwb_b 303 ELSE 304 WRITE(ctmp1,*)'flx_fwb_init : unable to read the file', clname 305 CALL ctl_stop( ctmp1 ) 306 ENDIF 293 CALL ctlopn( inum, clname, 'OLD', 'FORMATTED', 'SEQUENTIAL', & 294 & 1, numout, .FALSE., 1 ) 295 READ ( inum, "(24X,I8,2ES24.16)" ) iyear, a_fwb_b, a_fwb 296 CLOSE( inum ) 297 empold = a_fwb ! current year freshwater budget correction 298 ! ! estimate from the previous year budget 299 IF(lwp)WRITE(numout,*) 300 IF(lwp)WRITE(numout,*)'flx_fwb_init : year = ',iyear , ' freshwater budget correction = ', empold 301 IF(lwp)WRITE(numout,*)' year = ',iyear-1, ' freshwater budget read = ', a_fwb 302 IF(lwp)WRITE(numout,*)' year = ',iyear-2, ' freshwater budget read = ', a_fwb_b 307 303 ! ! ============================== 308 304 ELSE ! NO budget correction
Note: See TracChangeset
for help on using the changeset viewer.