Changeset 476


Ignore:
Timestamp:
02/07/24 16:31:29 (5 months ago)
Author:
aquiquet
Message:

Cleaning branch: ablation_bord with explicit arguments

Location:
branches/GRISLIv3/SOURCES
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/GRISLIv3/SOURCES/ablation_bord.f90

    r446 r476  
    11!> \file ablation_bord.f90 
    2 !! Clacul de l'ablation sur le bord 
     2!! Evaluation of the ablation at the edge (bord) of the ice sheet  
    33!< 
    44       
    55 
    66!> SUBROUTINE: Ablation_bord 
    7 !! Calcule l'ablation pour les points du bord  
     7!! Evaluation of the ablation at the edge (bord) of the ice sheet 
    88!! \author ... 
    99!! \date .... 
    10 !! @note cas des bords de calotte : un point du bord peut perdre en plus la glace  
    11 !! amenée par l'écoulement. 
    12 !! @note Calcule l'ablation pour les points du bord avec H=0 mais apport par l'amont 
    13 !! diagnostic pour la fermeture du bilan d'eau 
    14 !! par convention ablation negative dans la zone d'ablation  
    15 !! @note Used modules: 
    16 !! @note  - use module3D_phy 
     10!! @note ice edge case: it can loose ice brought by ice transport 
     11!! @note Evaluate the ablation at the edge with H=0 but ice brought by mass transport 
     12!! diagnosed for water conservation 
     13!! ablation is defined as negative when ice is removed 
    1714!> 
    1815 
    19 subroutine ablation_bord 
     16subroutine ablation_bord(ice,bm,bmelt,ablbord,ablbord_dtt,dt) 
    2017 
     18  implicit none 
    2119 
    22   use module3D_phy, only: ice,ablbord,bmelt,bm,dt,ablbord_dtt 
    23   use geography, only: nx,ny 
    24   implicit none 
    25   integer :: ip1,im1,jp1,jm1   ! pour chercher les voisins 
     20  real                  , intent(in)    :: dt 
     21  integer,dimension(:,:), intent(in)    :: ice 
     22  real,   dimension(:,:), intent(in)    :: bm,bmelt 
     23  real,   dimension(:,:), intent(inout) :: ablbord,ablbord_dtt 
     24   
     25  integer :: nxloc,nyloc 
     26  integer :: ip1,im1,jp1,jm1   ! to look for neighbours 
    2627  integer :: somm 
    2728  integer :: i,j 
    2829 
    29   ! Dans les zones ou le calcul icethick a donne un H negatif : ablbord=H 
     30  nxloc=ubound(ice,1) 
     31  nyloc=ubound(ice,2) 
    3032 
    31   ! pour être au bord, il suffit que la somme des ice voisins soit > 0 
    32   do j=1,ny 
    33      do i=1,nx 
     33  ! When icethick has given negative values for H: ablbord=H 
     34 
     35  ! to be bord (edge), the sum of neighbouring ice points should be > 0 
     36  do j=1,nyloc 
     37     do i=1,nxloc 
    3438        if (ice(i,j).eq.0) then   ! seulment pour les noeuds sans glace 
    3539           im1=max(i-1,1) 
    3640           jm1=max(j-1,1) 
    37            ip1=min(i+1,nx) 
    38            jp1=min(j+1,ny) 
     41           ip1=min(i+1,nxloc) 
     42           jp1=min(j+1,nyloc) 
    3943 
    4044           somm=ice(ip1,j)+ice(im1,j)+ice(i,jp1)+ice(i,jm1) 
    41            if (somm.gt.0.and.(ablbord(i,j).LT.0.)) then                               ! voisins englaces 
    42               !~ !         if (somm.gt.0.and.((ablbord(i,j).LT.0.).OR.(flot(ip1,j).OR.flot(im1,j).OR.flot(i,jp1).OR.flot(i,jm1)))) then   ! voisins englaces 
    43               !~ !            ablbord(i,j)= ablbord(i,j) - (Acc(i,j) * dt)     !  Ablvrai=bmpdd-Acc-Hcalc/dt 
    44               !~             if (ablbord(i,j).LT.0..and.front(i,j).LE.4.and.front(i,j).GE.0) then 
     45           if (somm.gt.0.and.(ablbord(i,j).LT.0.)) then        ! glaciated neighbours 
     46 
    4547              ablbord(i,j)= max(0.,ablbord(i,j) + ((Bmelt(i,j) - Bm(i,j)) * dt))  ! version Tof : ablbord = Hcons_mass - Bm - Bmelt 
    4648 
    4749           else 
    48               !~ ! version cat            ablbord(i,j)=hdot(i,j)-acc(i,j)   ! on ne fond que ce qui est tombe + existant 
    4950              ablbord(i,j)=0. 
    5051           endif 
     
    5758  ablbord_dtt(:,:) = ablbord_dtt(:,:) + ablbord(:,:) 
    5859 
    59   !cdc deplace dans bilan_flux_output_mod ablbord(:,:)=0. 
    60  
    6160end subroutine ablation_bord 
  • branches/GRISLIv3/SOURCES/main3D-0.4-40km.f90

    r469 r476  
    132132 
    133133  USE module3D_phy, only: itemp,icouple,isynchro,icompteur,iglen, & 
     134                          ice,bm,bmelt,ablbord,ablbord_dtt,dt,    & 
    134135                          s,h,b,bsoc,flot,mk,mk0,uxbar,uybar,hwater,time,timemax,ndebug,ndebug_max 
    135136  use runparam, only: nt,tbegin,dtprofile,dtcpt,dirnameout,runname,itracebug 
     
    238239           call flottab() 
    239240           call calving 
    240            call ablation_bord 
     241           call ablation_bord(ice,bm,bmelt,ablbord,ablbord_dtt,dt) 
    241242           call flottab 
    242243           call Neffect() 
  • branches/GRISLIv3/SOURCES/steps_time_loop.f90

    r474 r476  
    1515 
    1616  use module3d_phy, only: ispinup,isynchro,timemax,time,flot,S,B,Bsoc,H,sealevel_2d,hmx,hmy,& 
     17       ice,bm,bmelt,ablbord,ablbord_dtt,dt, & 
    1718       uxbar,uybar,hdot,dtmax,dtmin,iout 
    1819  use runparam, only: itracebug,nt,num_tracebug 
     
    6061     call determin_tache 
    6162     call calving 
    62      call ablation_bord 
     63     call ablation_bord(ice,bm,bmelt,ablbord,ablbord_dtt,dt) 
    6364     call bilan_eau 
    6465     call bilan_flux_output      
Note: See TracChangeset for help on using the changeset viewer.