Changeset 11632
 Timestamp:
 20191001T20:57:51+02:00 (5 years ago)
 File:

 1 edited
Legend:
 Unmodified
 Added
 Removed

NEMO/trunk/src/ICE/icedyn_adv_pra.F90
r11627 r11632 229 229 ! 230 230 !  Ensure nonnegative fields  ! 231 ! Remove negative values (conservation is ensured)232 ! (because advected fields are not perfectly bounded and tiny negative values can occur, e.g. 1.e20)231 ! Remove negative values (conservation is ensured) 232 ! (because advected fields are not perfectly bounded and tiny negative values can occur, e.g. 1.e20) 233 233 CALL ice_var_zapneg( zdt, pato_i, pv_i, pv_s, psv_i, poa_i, pa_i, pa_ip, pv_ip, pe_s, pe_i ) 234 ! 235 !  Ensure snow load is not too big  ! 236 CALL Hsnow( zdt, pv_i, pv_s, pa_i, pa_ip, pe_s ) 234 237 ! 235 238 IF( lrst_ice ) CALL adv_pra_rst( 'WRITE', kt ) !* write Prather fields in the restart file … … 576 579 ! 577 580 END SUBROUTINE adv_y 581 582 583 SUBROUTINE Hsnow( pdt, pv_i, pv_s, pa_i, pa_ip, pe_s ) 584 !! 585 !! *** ROUTINE Hsnow *** 586 !! 587 !! ** Purpose : 1 Check snow load after advection 588 !! 2 Correct pond concentration to avoid a_ip > a_i 589 !! 590 !! ** Method : If snow load makes snowice interface to deplet below the ocean surface 591 !! then put the snow excess in the ocean 592 !! 593 !! ** Notes : This correction is crucial because of the call to routine icecor afterwards 594 !! which imposes a mini of ice thick. (rn_himin). This imposed mini can artificially 595 !! make the snow very thick (if concentration decreases drastically) 596 !! This behavior has been seen in UltimateMacho and supposedly it can also be true for Prather 597 !! 598 REAL(wp) , INTENT(in ) :: pdt ! tracer timestep 599 REAL(wp), DIMENSION(:,:,:) , INTENT(inout) :: pv_i, pv_s, pa_i, pa_ip 600 REAL(wp), DIMENSION(:,:,:,:), INTENT(inout) :: pe_s 601 ! 602 INTEGER :: ji, jj, jl ! dummy loop indices 603 REAL(wp) :: z1_dt, zvs_excess, zfra 604 !! 605 ! 606 z1_dt = 1._wp / pdt 607 ! 608 !  check snow load  ! 609 DO jl = 1, jpl 610 DO jj = 1, jpj 611 DO ji = 1, jpi 612 IF ( pv_i(ji,jj,jl) > 0._wp ) THEN 613 ! 614 zvs_excess = MAX( 0._wp, pv_s(ji,jj,jl)  pv_i(ji,jj,jl) * (rau0rhoi) * r1_rhos ) 615 ! 616 IF( zvs_excess > 0._wp ) THEN ! snowice interface deplets below the ocean surface 617 ! put snow excess in the ocean 618 zfra = ( pv_s(ji,jj,jl)  zvs_excess ) / MAX( pv_s(ji,jj,jl), epsi20 ) 619 wfx_res(ji,jj) = wfx_res(ji,jj) + zvs_excess * rhos * z1_dt 620 hfx_res(ji,jj) = hfx_res(ji,jj)  SUM( pe_s(ji,jj,1:nlay_s,jl) ) * ( 1._wp  zfra ) * z1_dt ! W.m2 <0 621 ! correct snow volume and heat content 622 pe_s(ji,jj,1:nlay_s,jl) = pe_s(ji,jj,1:nlay_s,jl) * zfra 623 pv_s(ji,jj,jl) = pv_s(ji,jj,jl)  zvs_excess 624 ENDIF 625 ! 626 ENDIF 627 END DO 628 END DO 629 END DO 630 ! 631 ! correct pond concentration to avoid a_ip > a_i  ! 632 WHERE( pa_ip(:,:,:) > pa_i(:,:,:) ) pa_ip(:,:,:) = pa_i(:,:,:) 633 ! 634 END SUBROUTINE Hsnow 578 635 579 636
Note: See TracChangeset
for help on using the changeset viewer.