Changeset 3577 for trunk/LMDZ.PLUTO/libf


Ignore:
Timestamp:
Jan 15, 2025, 11:04:37 AM (5 days ago)
Author:
tbertrand
Message:

LMDZ.PLUTO:
update of routine for testing mass conservation
TB

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/LMDZ.PLUTO/libf/phypluto/testconservmass.F90

    r3412 r3577  
    44      use comcstfi_mod, only: g
    55      use geometry_mod, only: cell_area
    6       USE comgeomfi_h, only: totarea
     6      USE comgeomfi_h, only: totarea,totarea_planet
    77      implicit none
    88
     
    4949      pstot=0.0
    5050
    51       do ig = 2, ngrid-1
     51      do ig = 1, ngrid
    5252
    5353         ! mass atm kg/m2
     
    6262
    6363      enddo
    64       atmmasstot= atmmasstot + ps(1)/g*cell_area(1)*iim
    65       atmmasstot= atmmasstot + ps(ngrid)/g*cell_area(ngrid)*iim
    66 
    67       surfmasstot= surfmasstot + surfmass(1)*cell_area(1)*iim
    68       surfmasstot= surfmasstot + surfmass(ngrid)*cell_area(ngrid)*iim
    69 
    70       pstot= pstot + ps(1)*cell_area(1)*iim
    71       pstot= pstot + ps(ngrid)*cell_area(ngrid)*iim
    7264               
    73       atmmasstot=  atmmasstot/(totarea+(iim-1)*(cell_area(1)+cell_area(ngrid)))
    74       pstot=  pstot/(totarea+(iim-1)*(cell_area(1)+cell_area(ngrid)))
    75       surfmasstot = surfmasstot/(totarea+(iim-1)*(cell_area(1)+cell_area(ngrid)))
     65      atmmasstot=  atmmasstot/totarea_planet
     66      pstot=  pstot/totarea_planet
     67      surfmasstot = surfmasstot/totarea_planet
    7668
    7769      totmass=surfmasstot+atmmasstot
Note: See TracChangeset for help on using the changeset viewer.