Changeset 3379
- Timestamp:
- 2012-05-02T10:06:44+02:00 (13 years ago)
- Location:
- branches/2012/dev_r3337_NOCS10_ICB/NEMOGCM/NEMO/OPA_SRC/ICB
- Files:
-
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2012/dev_r3337_NOCS10_ICB/NEMOGCM/NEMO/OPA_SRC/ICB/icbclv.F90
r3374 r3379 42 42 !! *** ROUTINE icb_clv_flx *** 43 43 !! 44 !! ** Purpose : ?44 !! ** Purpose : accumulate ice available for calving into class arrays 45 45 !! 46 !! ** input : - ?47 46 !!---------------------------------------------------------------------- 48 47 INTEGER, INTENT(in) :: kt … … 57 56 ! Use interior mask: so no bergs in overlap areas and convert from km^3/year to kg/s 58 57 ! this assumes that input is given as equivalent water flux so that pure water density is appropriate 58 59 59 zfact = ( (1000._wp)**3 / ( NINT(rday) * nyear_len(1) ) ) * 1000._wp 60 60 berg_grid%calving(:,:) = src_calving(:,:) * tmask_i(:,:) * zfact -
branches/2012/dev_r3337_NOCS10_ICB/NEMOGCM/NEMO/OPA_SRC/ICB/icbdia.F90
r3373 r3379 14 14 !!---------------------------------------------------------------------- 15 15 !!---------------------------------------------------------------------- 16 !! icb_dia_end : end iceberg budgeting17 16 !! icb_dia_init : initialise iceberg budgeting 18 17 !!---------------------------------------------------------------------- … … 28 27 PRIVATE 29 28 30 PUBLIC icb_dia_end ! routine called in icbstp.F90 module31 29 PUBLIC icb_dia_init ! routine called in icbini.F90 module 32 30 PUBLIC icb_dia ! routine called in icbstp.F90 module … … 83 81 CONTAINS 84 82 85 SUBROUTINE icb_dia_end86 !!----------------------------------------------------------------------87 !88 IF( .NOT. ln_bergdia ) RETURN89 DEALLOCATE( berg_melt )90 DEALLOCATE( buoy_melt )91 DEALLOCATE( eros_melt )92 DEALLOCATE( conv_melt )93 DEALLOCATE( bits_src )94 DEALLOCATE( bits_melt )95 DEALLOCATE( bits_mass )96 DEALLOCATE( virtual_area )97 DEALLOCATE( berg_mass )98 DEALLOCATE( real_calving )99 DEALLOCATE( tmpc )100 IF( lk_mpp ) THEN101 DEALLOCATE( rsumbuf )102 DEALLOCATE( nsumbuf )103 ENDIF104 !105 END SUBROUTINE icb_dia_end106 107 108 83 SUBROUTINE icb_dia_init( ) 109 84 !!---------------------------------------------------------------------- … … 111 86 ! 112 87 IF( .NOT. ln_bergdia ) RETURN 88 113 89 ALLOCATE( berg_melt (jpi,jpj) ) ; berg_melt (:,:) = 0._wp 114 90 ALLOCATE( buoy_melt (jpi,jpj) ) ; buoy_melt (:,:) = 0._wp … … 179 155 SUBROUTINE icb_dia( ld_budge ) 180 156 !!---------------------------------------------------------------------- 157 !! sum all the things we've accumulated so far in the current processor 158 !! in MPP case then add these sums across all processors 159 !! for this we pack variables into buffer so we only need one mpp_sum 181 160 !!---------------------------------------------------------------------- 182 161 LOGICAL, INTENT(in) :: ld_budge … … 369 348 !!---------------------------------------------------------------------- 370 349 !! things to reset at the beginning of each timestep 371 !! this probably screws up fields going to diawri, so needs to be looked at - sga372 350 !!---------------------------------------------------------------------- 373 351 ! -
branches/2012/dev_r3337_NOCS10_ICB/NEMOGCM/NEMO/OPA_SRC/ICB/icbdyn.F90
r3374 r3379 39 39 !! ** Purpose : iceberg evolution. 40 40 !! 41 !! ** Method : - blah blah41 !! ** Method : - See Martin & Adcroft, Ocean Modelling 34, 2010 42 42 !!---------------------------------------------------------------------- 43 43 REAL(wp) :: zuvel1 , zvvel1 , zu1, zv1, zax1, zay1, zxi1 , zyj1 … … 174 174 !! ** Purpose : iceberg grounding. 175 175 !! 176 !! ** Method : - blah blah 176 !! ** Method : - adjust velocity and then put iceberg back to start position 177 !! NB two possibilities available one of which is hard-coded here 177 178 !!---------------------------------------------------------------------- 178 179 REAL(wp), INTENT(inout) :: pi , pj ! current iceberg position … … 240 241 !! ** Purpose : compute the iceberg acceleration. 241 242 !! 242 !! ** Method : - blah blah243 !! ** Method : - sum the terms in the momentum budget 243 244 !!---------------------------------------------------------------------- 244 245 TYPE(iceberg ), POINTER, INTENT(in ) :: berg ! berg -
branches/2012/dev_r3337_NOCS10_ICB/NEMOGCM/NEMO/OPA_SRC/ICB/icbini.F90
r3375 r3379 51 51 !! ** Purpose : iceberg initialization. 52 52 !! 53 !! ** Method : - blah blah 53 !! ** Method : - read the iceberg namelist 54 !! - find non-overlapping processor interior since we can only 55 !! have one instance of a particular iceberg 56 !! - calculate the destinations for north fold exchanges 57 !! - setup either test icebergs or calving file 54 58 !!---------------------------------------------------------------------- 55 59 REAL(wp), INTENT(in) :: pdt ! iceberg time-step (rdt*nn_fsbc) … … 356 360 READ ( numnam, namberg ) 357 361 358 !!gm bug here in mpp : the return instruction will be done only on the 1st processor (lwp=True)359 ! IF( .NOT. ln_icebergs .AND. lwp ) THEN360 ! WRITE(numout,*)361 ! WRITE(numout,*) 'icb_nam : iceberg initialization through namberg namelist read'362 ! WRITE(numout,*) '~~~~~~~~ '363 ! WRITE(numout,*) 'NO icebergs used'364 ! RETURN365 ! ENDIF366 !!gm solution:367 368 362 IF( .NOT. ln_icebergs ) THEN ! no icebergs 369 363 IF(lwp) THEN … … 374 368 RETURN 375 369 ENDIF 376 !!gm end377 370 378 371 IF( nn_test_icebergs > nclasses ) THEN -
branches/2012/dev_r3337_NOCS10_ICB/NEMOGCM/NEMO/OPA_SRC/ICB/icblbc.F90
r3375 r3379 14 14 !!---------------------------------------------------------------------- 15 15 !!---------------------------------------------------------------------- 16 !! icb_lbc : Pass icebergs across cyclic boundaries17 !! icb_lbc_mpp : In MPP pass icebergs from linked list between processors18 !! as they advect around19 !! Lagrangian processes cannot be handled by existing NEMO MPP20 !! routines because they do not lie on regular jpi,jpj grids21 !! Processor exchanges are handled as in lib_mpp whenever icebergs step22 !! across boundary of interior domain (nicbdi-nicbei, nicbdj-nicbej)23 !! so that iceberg does not exist in more than one processor24 !! North fold exchanges controlled by three arrays:25 !! nicbflddest - unique processor numbers that current one exchanges with26 !! nicbfldproc - processor number that current grid point exchanges with27 !! nicbfldpts - packed i,j point in exchanging processor16 !! icb_lbc : - Pass icebergs across cyclic boundaries 17 !! icb_lbc_mpp : - In MPP pass icebergs from linked list between processors 18 !! as they advect around 19 !! - Lagrangian processes cannot be handled by existing NEMO MPP 20 !! routines because they do not lie on regular jpi,jpj grids 21 !! - Processor exchanges are handled as in lib_mpp whenever icebergs step 22 !! across boundary of interior domain (nicbdi-nicbei, nicbdj-nicbej) 23 !! so that iceberg does not exist in more than one processor 24 !! - North fold exchanges controlled by three arrays: 25 !! nicbflddest - unique processor numbers that current one exchanges with 26 !! nicbfldproc - processor number that current grid point exchanges with 27 !! nicbfldpts - packed i,j point in exchanging processor 28 28 !!---------------------------------------------------------------------- 29 29 -
branches/2012/dev_r3337_NOCS10_ICB/NEMOGCM/NEMO/OPA_SRC/ICB/icbrst.F90
r3375 r3379 14 14 !!---------------------------------------------------------------------- 15 15 !!---------------------------------------------------------------------- 16 !! icb_rst_read : initialise !!gm suggested name : icebergs_rst_read or better icb_rst_read17 !! icb_rst_write : generate test icebergs !!gm icebergs_rst_write or better icb_rst_write16 !! icb_rst_read : read restart file 17 !! icb_rst_write : write restart file 18 18 !!---------------------------------------------------------------------- 19 19 USE par_oce ! NEMO parameters -
branches/2012/dev_r3337_NOCS10_ICB/NEMOGCM/NEMO/OPA_SRC/ICB/icbstp.F90
r3376 r3379 55 55 !! ** Purpose : iceberg time stepping. 56 56 !! 57 !! ** Method : - blah blah57 !! ** Method : - top level routine to do things in the correct order 58 58 !!---------------------------------------------------------------------- 59 59 INTEGER, INTENT(in) :: kt ! time step index … … 172 172 IF( nn_sample_rate .GT. 0 ) CALL icb_trj_end() 173 173 174 CALL icb_dia_end()175 176 174 IF(lwp) WRITE(numout,'(a,i6)') 'icebergs: icb_end complete', narea 177 175 CALL flush( numicb ) -
branches/2012/dev_r3337_NOCS10_ICB/NEMOGCM/NEMO/OPA_SRC/ICB/icbthm.F90
r3377 r3379 39 39 !! ** Purpose : compute the iceberg thermodynamics. 40 40 !! 41 !! ** Method : - blah blah41 !! ** Method : - See Martin & Adcroft, Ocean Modelling 34, 2010 42 42 !!---------------------------------------------------------------------- 43 43 INTEGER, INTENT(in) :: kt ! timestep number, just passed to icb_utl_print_berg -
branches/2012/dev_r3337_NOCS10_ICB/NEMOGCM/NEMO/OPA_SRC/ICB/icbtrj.F90
r3373 r3379 11 11 !!---------------------------------------------------------------------- 12 12 !!---------------------------------------------------------------------- 13 !! write_trajectory:13 !! icb_trj_init : 14 14 !!---------------------------------------------------------------------- 15 15 USE par_oce ! NEMO parameters … … 52 52 53 53 SUBROUTINE icb_trj_init( ktend ) 54 55 ! local variables 54 !!---------------------------------------------------------------------- 55 !! *** ROUTINE icb_trj_init *** 56 !! 57 !! ** Purpose : initialise iceberg trajectory output files 58 !!---------------------------------------------------------------------- 56 59 INTEGER, INTENT( in ) :: ktend 57 ! Local variables60 ! 58 61 INTEGER :: iret 59 62 CHARACTER(len=80) :: cl_filename 60 63 TYPE(iceberg), POINTER :: this 61 64 TYPE(point) , POINTER :: pt 65 !!---------------------------------------------------------------------- 62 66 63 67 IF( lk_mpp ) THEN ; WRITE(cl_filename,'("trajectory_icebergs_",I6.6,"_",I4.4,".nc")') ktend, narea-1 -
branches/2012/dev_r3337_NOCS10_ICB/NEMOGCM/NEMO/OPA_SRC/ICB/icbutl.F90
r3376 r3379 114 114 !! *** ROUTINE icb_utl_interp *** 115 115 !! 116 !! ** Purpose : i ceberg initialization.117 !! 118 !! ** Method : - blah blah116 !! ** Purpose : interpolation 117 !! 118 !! ** Method : - interpolate from various ocean arrays onto iceberg position 119 119 !! 120 120 !! !!gm CAUTION here I do not care of the slip/no-slip conditions … … 275 275 !! 276 276 !! ** Purpose : bilinear interpolation at berg location of horizontal scale factor 277 !! ** Method : interpolation done using the 4 nearest grid point among277 !! ** Method : interpolation done using the 4 nearest grid points among 278 278 !! t-, u-, v-, and f-points. 279 279 !!---------------------------------------------------------------------- … … 348 348 !! ** Purpose : add a new berg to the iceberg list 349 349 !! 350 !! ** method : - ?351 350 !!---------------------------------------------------------------------- 352 351 TYPE(iceberg), INTENT(in) :: bergvals … … 370 369 !! ** Purpose : add a new berg to the iceberg list 371 370 !! 372 !! ** method : - ?373 371 !!---------------------------------------------------------------------- 374 372 TYPE(iceberg), INTENT(in) :: bergvals … … 402 400 !! ** Purpose : add a new berg to the iceberg list 403 401 !! 404 !! ** method : - ?405 402 !!---------------------------------------------------------------------- 406 403 TYPE(iceberg), POINTER :: newberg … … 435 432 !!gm all these info are already known in daymod, no??? 436 433 !! 437 !! ** method : - ?438 434 !!---------------------------------------------------------------------- 439 435 INTEGER, INTENT(in) :: kmon, kday, khr, kmin, ksec … … 475 471 !! *** ROUTINE icb_utl_destroy *** 476 472 !! 477 !! ** Purpose : 473 !! ** Purpose : remove a single iceberg instance 478 474 !! 479 475 !!---------------------------------------------------------------------- … … 522 518 !! *** ROUTINE icb_utl_print_berg *** 523 519 !! 524 !! ** Purpose : 520 !! ** Purpose : print one 525 521 !! 526 522 !!---------------------------------------------------------------------- … … 544 540 !! *** ROUTINE icb_utl_print *** 545 541 !! 546 !! ** Purpose : 542 !! ** Purpose : print many 547 543 !! 548 544 !!---------------------------------------------------------------------- … … 631 627 !! *** FUNCTION icb_utl_mass *** 632 628 !! 633 !! ** Purpose : compute the mass all iceberg, all berg ies or all bergs.629 !! ** Purpose : compute the mass all iceberg, all berg bits or all bergs. 634 630 !!---------------------------------------------------------------------- 635 631 TYPE(iceberg) , POINTER :: first
Note: See TracChangeset
for help on using the changeset viewer.