Changeset 9242
- Timestamp:
- 2018-01-16T15:42:45+01:00 (7 years ago)
- Location:
- branches/UKMO/dev_r5518_new_runoff_coupling/NEMOGCM/NEMO/OPA_SRC
- Files:
-
- 1 added
- 1 deleted
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/UKMO/dev_r5518_new_runoff_coupling/NEMOGCM/NEMO/OPA_SRC/SBC/cpl_oasis3.F90
r9156 r9242 38 38 PUBLIC cpl_define 39 39 PUBLIC cpl_snd 40 PUBLIC runoff_rcv41 40 PUBLIC cpl_rcv 42 41 PUBLIC cpl_freq … … 69 68 INTEGER, PUBLIC, PARAMETER :: nmaxcat=5 ! Maximum number of coupling fields 70 69 INTEGER, PUBLIC, PARAMETER :: nmaxcpl=5 ! Maximum number of coupling fields 71 INTEGER, PUBLIC, PARAMETER :: n_rivers=2000 ! Total number of rivers whose runoff is passed from the atmosphere70 INTEGER, PUBLIC, PARAMETER :: n_rivers=2000 ! Total number of rivers in coupled runoff using 1D array 72 71 73 INTEGER :: runoff_id72 INTEGER, PUBLIC :: runoff_id 74 73 75 74 TYPE, PUBLIC :: FLD_CPL !: Type for coupling field information … … 141 140 ! 142 141 INTEGER :: id_part ! Partition for all 2D model fields to be coupled 143 INTEGER :: id_part_r ! Partition for river runoff142 INTEGER :: id_part_rnf_1d ! Partition for river runoff using 1D array 144 143 INTEGER :: paral(5) ! OASIS3 box partition 145 144 INTEGER :: ishape(2,2) ! shape of arrays passed to PSMILe … … 203 202 CALL oasis_def_partition ( id_part, paral, nerror ) 204 203 ! 205 ! Another partition is needed for river runoff 204 ! Another partition is needed for river runoff when using 1D array 206 205 207 206 paral(1) = 0 ! serial partitioning … … 211 210 paral(5) = 0 212 211 213 CALL oasis_def_partition ( id_part_r , paral, nerror, n_rivers )212 CALL oasis_def_partition ( id_part_rnf_1d, paral, nerror, n_rivers ) 214 213 215 214 ! ... Announce send variables. … … 304 303 END DO 305 304 306 ! Define river runoff307 CALL oasis_def_var (runoff_id, 'runoffo', id_part_r , (/ 1, 0 /), &305 ! Define coupled river runoff using 1D array 306 CALL oasis_def_var (runoff_id, 'runoffo', id_part_rnf_1d , (/ 1, 0 /), & 308 307 & OASIS_In , (/ 1, n_rivers /) , OASIS_REAL, nerror ) 309 308 IF ( nerror /= OASIS_Ok ) THEN … … 439 438 END SUBROUTINE cpl_rcv 440 439 441 SUBROUTINE runoff_rcv( kstep)442 443 INTEGER , INTENT(in ) :: kstep ! ocean time-step in seconds444 445 INTEGER :: kinfo ! OASIS3 info argument446 REAL(wp) :: runoff(n_rivers) ! River runoff. One value per river.447 448 ! Get the river runoff sent by the atmosphere449 CALL oasis_get ( runoff_id, kstep, runoff, kinfo )450 ! IF ( narea == 1 ) THEN451 WRITE(numout,*)' narea = ', narea452 WRITE(numout,*)' kstep = ', kstep453 WRITE(numout,*)' River runoff = ', runoff454 WRITE(numout,*)' kinfo = ', kinfo455 WRITE(numout,*)'-------'456 ! ENDIF457 458 459 END SUBROUTINE runoff_rcv460 461 462 440 INTEGER FUNCTION cpl_freq( cdfieldname ) 463 441 !!--------------------------------------------------------------------- -
branches/UKMO/dev_r5518_new_runoff_coupling/NEMOGCM/NEMO/OPA_SRC/SBC/sbccpl.F90
r8212 r9242 43 43 USE eosbn2 44 44 USE sbcrnf , ONLY : l_rnfcpl 45 USE cpl_rnf_1d, ONLY : cpl_rnf_1D_rcv ! Coupled runoff using 1D array 45 46 #if defined key_cpl_carbon_cycle 46 47 USE p4zflx, ONLY : oce_co2 … … 865 866 DO jn = 1, jprcv ! received fields sent by the atmosphere 866 867 IF( srcv(jn)%laction ) CALL cpl_rcv( jn, isec, frcv(jn)%z3, xcplmask(:,:,1:nn_cplmodel), nrcvinfo(jn) ) 867 END DO 868 869 CALL runoff_rcv( isec) 868 END DO 870 869 871 870 ! ! ========================= ! … … 1072 1071 ! 1073 1072 ! ! runoffs and calving (added in emp) 1074 IF( srcv(jpr_rnf)%laction ) rnf(:,:) = frcv(jpr_rnf)%z3(:,:,1) 1073 IF( srcv(jpr_rnf)%laction ) rnf(:,:) = frcv(jpr_rnf)%z3(:,:,1) 1074 CALL cpl_rnf_1d_rcv( isec) 1075 1075 IF( srcv(jpr_cal)%laction ) zemp(:,:) = zemp(:,:) - frcv(jpr_cal)%z3(:,:,1) 1076 1076 … … 1331 1331 1332 1332 1333 SUBROUTINE sbc_cpl_ice_flx( p_frld, palbi, psst, pist )1333 SUBROUTINE sbc_cpl_ice_flx( kt, p_frld, palbi, psst, pist ) 1334 1334 !!---------------------------------------------------------------------- 1335 1335 !! *** ROUTINE sbc_cpl_ice_flx *** … … 1371 1371 !! sprecip solid precipitation over the ocean 1372 1372 !!---------------------------------------------------------------------- 1373 INTEGER, INTENT(in) :: kt ! ocean model time step index 1373 1374 REAL(wp), INTENT(in ), DIMENSION(:,:) :: p_frld ! lead fraction [0 to 1] 1374 1375 ! optional arguments, used only in 'mixed oce-ice' case … … 1384 1385 !!---------------------------------------------------------------------- 1385 1386 ! 1387 INTEGER :: isec ! number of seconds since nit000 (assuming rdttra did not change since nit000) 1386 1388 IF( nn_timing == 1 ) CALL timing_start('sbc_cpl_ice_flx') 1387 1389 ! … … 1432 1434 CALL iom_put( 'calving_cea', frcv(jpr_cal)%z3(:,:,1) ) 1433 1435 ENDIF 1436 isec = ( kt - nit000 ) * NINT( rdttra(1) ) 1437 CALL cpl_rnf_1d_rcv( isec) 1434 1438 1435 1439 IF( ln_mixcpl ) THEN -
branches/UKMO/dev_r5518_new_runoff_coupling/NEMOGCM/NEMO/OPA_SRC/SBC/sbcice_cice.F90
r8163 r9242 139 139 CALL cice_sbc_force(kt) 140 140 ELSE IF ( ksbc == jp_purecpl ) THEN 141 CALL sbc_cpl_ice_flx( 1.0-fr_i )141 CALL sbc_cpl_ice_flx( kt, 1.0-fr_i ) 142 142 ENDIF 143 143 -
branches/UKMO/dev_r5518_new_runoff_coupling/NEMOGCM/NEMO/OPA_SRC/nemogcm.F90
r9156 r9242 53 53 USE bdydta ! open boundary cond. setting (bdy_dta_init routine) 54 54 USE bdytides ! open boundary cond. setting (bdytide_init routine) 55 USE cpl_rnf ! Runoff in coupled models (cpl_rnf_init routine)55 USE cpl_rnf_1d, ONLY : cpl_rnf_1d_init ! Coupled runoff 1D array 56 56 USE istate ! initial state setting (istate_init routine) 57 57 USE ldfdyn ! lateral viscosity setting (ldfdyn_init routine) … … 398 398 IF( lk_bdy .AND. lk_tide ) & 399 399 & CALL bdytide_init ! Open boundaries initialisation of tidal harmonic forcing 400 CALL cpl_rnf_ init ! Runoff in coupled model400 CALL cpl_rnf_1d_init ! Coupled runoff using 1D array 401 401 402 402 CALL dyn_nept_init ! simplified form of Neptune effect
Note: See TracChangeset
for help on using the changeset viewer.