Changeset 377


Ignore:
Timestamp:
03/20/23 18:42:16 (13 months ago)
Author:
dumas
Message:

use only in subroutine ablation_bord

File:
1 edited

Legend:

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

    r136 r377  
    2020 
    2121 
    22 use module3D_phy 
    23 implicit none 
    24 integer :: ip1,im1,jp1,jm1   ! pour chercher les voisins 
    25 integer :: somm 
     22  use module3D_phy, only:nx,ny,ice,ablbord,bmelt,bm,dt,ablbord_dtt 
     23  implicit none 
     24  integer :: ip1,im1,jp1,jm1   ! pour chercher les voisins 
     25  integer :: somm 
     26  integer :: i,j 
    2627 
    27 ! Dans les zones ou le calcul icethick a donne un H negatif : ablbord=H 
     28  ! Dans les zones ou le calcul icethick a donne un H negatif : ablbord=H 
    2829 
    29 ! pour être au bord, il suffit que la somme des ice voisins soit > 0 
    30 do j=1,ny 
    31    do i=1,nx 
    32       if (ice(i,j).eq.0) then   ! seulment pour les noeuds sans glace 
    33          im1=max(i-1,1) 
    34          jm1=max(j-1,1) 
    35          ip1=min(i+1,nx) 
    36          jp1=min(j+1,ny) 
     30  ! pour être au bord, il suffit que la somme des ice voisins soit > 0 
     31  do j=1,ny 
     32     do i=1,nx 
     33        if (ice(i,j).eq.0) then   ! seulment pour les noeuds sans glace 
     34           im1=max(i-1,1) 
     35           jm1=max(j-1,1) 
     36           ip1=min(i+1,nx) 
     37           jp1=min(j+1,ny) 
    3738 
    38          somm=ice(ip1,j)+ice(im1,j)+ice(i,jp1)+ice(i,jm1) 
    39          if (somm.gt.0.and.(ablbord(i,j).LT.0.)) then                               ! voisins englaces 
    40 !~ !         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 
    41 !~ !            ablbord(i,j)= ablbord(i,j) - (Acc(i,j) * dt)     !  Ablvrai=bmpdd-Acc-Hcalc/dt 
    42 !~           if (ablbord(i,j).LT.0..and.front(i,j).LE.4.and.front(i,j).GE.0) then 
    43             ablbord(i,j)= max(0.,ablbord(i,j) + ((Bmelt(i,j) - Bm(i,j)) * dt))  ! version Tof : ablbord = Hcons_mass - Bm - Bmelt 
     39           somm=ice(ip1,j)+ice(im1,j)+ice(i,jp1)+ice(i,jm1) 
     40           if (somm.gt.0.and.(ablbord(i,j).LT.0.)) then                               ! voisins englaces 
     41              !~ !         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 
     42              !~ !            ablbord(i,j)= ablbord(i,j) - (Acc(i,j) * dt)     !  Ablvrai=bmpdd-Acc-Hcalc/dt 
     43              !~             if (ablbord(i,j).LT.0..and.front(i,j).LE.4.and.front(i,j).GE.0) then 
     44              ablbord(i,j)= max(0.,ablbord(i,j) + ((Bmelt(i,j) - Bm(i,j)) * dt))  ! version Tof : ablbord = Hcons_mass - Bm - Bmelt 
    4445 
    45           else 
    46 !~ ! version cat            ablbord(i,j)=hdot(i,j)-acc(i,j)   ! on ne fond que ce qui est tombe + existant 
    47                                                 ablbord(i,j)=0. 
    48           endif 
     46           else 
     47              !~ ! version cat            ablbord(i,j)=hdot(i,j)-acc(i,j)   ! on ne fond que ce qui est tombe + existant 
     48              ablbord(i,j)=0. 
     49           endif 
    4950        else 
    50                       ablbord(i,j)=0. 
    51       end if 
    52    end do 
    53 end do 
     51           ablbord(i,j)=0. 
     52        end if 
     53     end do 
     54  end do 
    5455 
    55 ablbord_dtt(:,:) = ablbord_dtt(:,:) + ablbord(:,:) 
     56  ablbord_dtt(:,:) = ablbord_dtt(:,:) + ablbord(:,:) 
    5657 
    57 !cdc deplace dans bilan_flux_output_mod ablbord(:,:)=0. 
     58  !cdc deplace dans bilan_flux_output_mod ablbord(:,:)=0. 
    5859 
    5960end subroutine ablation_bord 
Note: See TracChangeset for help on using the changeset viewer.