Changeset 3243 for trunk/LMDZ.PLUTO/libf
- Timestamp:
- Feb 28, 2024, 6:55:38 PM (10 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LMDZ.PLUTO/libf/phypluto/physiq_mod.F90
r3241 r3243 16 16 use write_field_phy, only: Writefield_phy 17 17 !! 18 use ieee_arithmetic 18 19 use ioipsl_getin_p_mod, only: getin_p 19 20 use radinc_h, only : L_NSPECTI,L_NSPECTV,naerkind, corrkdir, banddir … … 29 30 use comsaison_h, only: mu0, fract, dist_star, declin, right_ascen 30 31 use comsoil_h, only: nsoilmx, layer, mlayer, inertiedat 31 use geometry_mod, only: latitude, longitude, cell_area , real_area32 use geometry_mod, only: latitude, longitude, cell_area 32 33 USE comgeomfi_h, only: totarea, totarea_planet 33 34 USE tracer_h, only: noms, mmol, radius, rho_q, qext, & … … 55 56 n2cond,nearn2cond,noseason_day,conservn2, & 56 57 kbo,triton,paleo,paleoyears, & 57 fast,carbox, methane, UseVdifcPlutold, &58 carbox, methane, UseVdifcPlutold, & 58 59 aerohaze,haze_proffix,source_haze, & 59 60 season, sedimentation,generic_condensation, & … … 286 287 REAL flusurf(ngrid,nq) ! flux cond/sub kg.m-2.s-1 287 288 REAL flusurfold(ngrid,nq) ! old flux cond/sub kg.m-2.s-1 289 REAL zplev(ngrid,nlayer+1),zplay(ngrid,nlayer) 288 290 289 291 … … 842 844 ! II. Compute radiative tendencies 843 845 !--------------------------------- 846 ! Saving qsurf to compute paleo flux condensation/sublimation 847 DO iq=1, nq 848 DO ig=1,ngrid 849 IF (qsurf(ig,iq).lt.0.) then 850 qsurf(ig,iq)=0. 851 ENDIF 852 qsurf1(ig,iq)=qsurf(ig,iq) 853 ENDDO 854 ENDDO 855 844 856 845 857 ! Compute local stellar zenith angles … … 1653 1665 ps(1:ngrid) = pplev(1:ngrid,1) + pdpsrf(1:ngrid)*ptimestep 1654 1666 1667 ! pressure density !pluto specific 1668 IF (.not.fast) then ! 1669 do ig=1,ngrid 1670 do l=1,nlayer 1671 zplev(ig,l)=pplev(ig,l)/pplev(ig,1)*ps(ig) 1672 zplay(ig,l)=pplay(ig,l)/pplev(ig,1)*ps(ig) 1673 rho(ig,l) = zplay(ig,l)/(r*zt(ig,l)) 1674 enddo 1675 zplev(ig,nlayer+1)=pplev(ig,nlayer+1)/pplev(ig,1)*ps(ig) 1676 enddo 1677 ENDIF 1678 1655 1679 1656 1680 ! Surface and soil temperature information … … 1795 1819 ENDIF 1796 1820 endif 1797 1821 1798 1822 if (carbox) then 1799 1823 IF (fast) then … … 1814 1838 ENDIF 1815 1839 endif 1816 1840 1817 1841 zrho_haze(:,:)=0. 1818 1842 zdqrho_photprec(:,:)=0. … … 1825 1849 ENDDO 1826 1850 ENDIF 1827 1851 1828 1852 IF (fasthaze) then 1829 1853 DO ig=1,ngrid … … 1832 1856 ENDDO 1833 1857 ENDIF 1834 1858 1835 1859 ! Info about Ls, declin... 1836 1860 IF (fast) THEN … … 1843 1867 if (is_master) write(*,*),'Ls=',zls*180./pi,'decli=',declin*180./pi,'zday=',zday 1844 1868 ENDIF 1845 1869 1846 1870 lecttsoil=0 ! default value for lecttsoil 1847 1871 call getin_p("lecttsoil",lecttsoil) … … 1854 1878 CLOSE(13) 1855 1879 ENDIF 1856 1857 1880 1881 1858 1882 if (is_master) print*,'--> Ls =',zls*180./pi 1859 1883 … … 1893 1917 1894 1918 ! special case if we sublime the entire reservoir 1895 IF (-qsurfyear(ig,iq).gt.qsurf(ig,iq)) THEN 1896 masslost(iq)=masslost(iq)+real_area(ig)* & 1897 (-qsurfyear(ig,iq)-qsurf(ig,iq)) 1898 qsurfyear(ig,iq)=-qsurf(ig,iq) 1899 ENDIF 1900 1901 IF (qsurfyear(ig,iq).gt.0.) THEN 1902 massacc(iq)=massacc(iq)+real_area(ig)*qsurfyear(ig,iq) 1903 ENDIF 1919 !! AF: TODO : fix following lines (real_area), using line below: 1920 ! call planetwide_sumval((-qsurfyear(:,iq)-qsurf(:,iq))*cell_area(:),masslost) 1921 1922 ! IF (-qsurfyear(ig,iq).gt.qsurf(ig,iq)) THEN 1923 ! masslost(iq)=masslost(iq)+real_area(ig)* & 1924 ! (-qsurfyear(ig,iq)-qsurf(ig,iq)) 1925 ! qsurfyear(ig,iq)=-qsurf(ig,iq) 1926 ! ENDIF 1927 1928 ! IF (qsurfyear(ig,iq).gt.0.) THEN 1929 ! massacc(iq)=massacc(iq)+real_area(ig)*qsurfyear(ig,iq) 1930 ! ENDIF 1931 1904 1932 1905 1933 ENDDO … … 2068 2096 2069 2097 !! Pluto outputs 2070 call writediagfi(ngrid,"rice_ch4","ch4 ice mass mean radius","m",3,rice_ch4)2098 ! call writediagfi(ngrid,"rice_ch4","ch4 ice mass mean radius","m",3,rice_ch4) 2071 2099 call writediagfi(ngrid,"dist_star","dist_star","AU",0,dist_star) 2072 2100 … … 2075 2103 !AF: TODO which outputs? 2076 2104 else 2105 if (check_physics_outputs) then 2106 ! Check the validity of updated fields at the end of the physics step 2107 call check_physics_fields("HERE physiq:", zt, zu, zv, pplev, zq) 2108 endif 2109 2077 2110 call writediagfi(ngrid,"temp","temperature","K",3,zt) 2078 2111 call writediagfi(ngrid,"teta","potential temperature","K",3,zh) … … 2229 2262 call writediagfi(ngrid,"zrho_ch4","zrho_ch4","kg.m-3",3,zrho_ch4(:,:)) 2230 2263 endif 2231 2264 2232 2265 ! Tendancies 2233 2266 call writediagfi(ngrid,"zdqch4cloud","ch4 cloud","T s-1",& … … 2241 2274 call writediagfi(ngrid,"zdqadj_ch4","zdqadj ch4","",& 2242 2275 3,zdqadj(:,:,igcm_ch4_gas)) 2243 call writediagfi(ngrid,"zdqsed_ch4","zdqsed ch4","",& 2244 3,zdqsed(:,:,igcm_ch4_gas)) 2245 call writediagfi(ngrid,"zdqssed_ch4","zdqssed ch4","",& 2246 2,zdqssed(:,igcm_ch4_gas)) 2247 call writediagfi(ngrid,"zdtch4cloud","ch4 cloud","T s-1",& 2276 if (sedimentation) then 2277 call writediagfi(ngrid,"zdqsed_ch4","zdqsed ch4","",& 2278 3,zdqsed(:,:,igcm_ch4_gas)) 2279 call writediagfi(ngrid,"zdqssed_ch4","zdqssed ch4","",& 2280 2,zdqssed(:,igcm_ch4_gas)) 2281 endif 2282 if (metcloud) then 2283 call writediagfi(ngrid,"zdtch4cloud","ch4 cloud","T s-1",& 2248 2284 3,zdtch4cloud) 2249 2250 endif 2251 2285 endif 2286 2287 endif 2288 2252 2289 if (carbox) then 2253 2290 call writediagfi(ngrid,'co_iceflux','co_iceflux',& … … 2258 2295 endif 2259 2296 endif 2260 2297 2261 2298 if (haze) then 2262 2299 ! call writediagfi(ngrid,"zrho_haze","zrho_haze","kg.m-3",3,zrho_haze(:,:)) … … 2270 2307 3,zdqhaze(:,:,igcm_prec_haze)) 2271 2308 if (igcm_haze.ne.0) then 2272 call writediagfi(ngrid,"zdqhaze_haze","zdqhaze_haze","",& 2273 3,zdqhaze(:,:,igcm_haze)) 2274 call writediagfi(ngrid,"zdqssed_haze","zdqssed haze",& 2275 "kg/m2/s",2,zdqssed(:,igcm_haze)) 2309 call writediagfi(ngrid,"zdqhaze_haze","zdqhaze_haze","",& 2310 3,zdqhaze(:,:,igcm_haze)) 2311 if (sedimentation) then 2312 call writediagfi(ngrid,"zdqssed_haze","zdqssed haze",& 2313 "kg/m2/s",2,zdqssed(:,igcm_haze)) 2314 endif 2276 2315 endif 2277 2316 call writediagfi(ngrid,"zdqphot_ch4","zdqphot_ch4","",& … … 2282 2321 ! & 2,zdqhaze_col(:)) 2283 2322 endif 2284 2323 2285 2324 if (aerohaze) then 2286 2325 call writediagfi(ngrid,"tau_col",&
Note: See TracChangeset
for help on using the changeset viewer.