Changeset 270 for codes/icosagcm/branches/SATURN_DYNAMICO
- Timestamp:
- 09/05/14 14:42:27 (10 years ago)
- Location:
- codes/icosagcm/branches/SATURN_DYNAMICO
- Files:
-
- 1 added
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
codes/icosagcm/branches/SATURN_DYNAMICO/ICOSAGCM/arch/arch-X64_ADA.fcm
r264 r270 11 11 %DEBUG_FFLAGS -g -traceback -check bounds -fp-model strict 12 12 %MPI_FFLAGS 13 %OMP_FFLAGS -openmp 13 %OMP_FFLAGS -openmp -openmp-threadprivate compat 14 14 %BASE_LD -i4 -r8 -auto ${MKL_LIBS} -L/smplocal/pub/FFTW/3.3.3_dyn/lib -lfftw3 -lmkl_intel_lp64 -lmkl_sequential -lmkl_core -lpthread -Wl,-rpath=/smplocal/pub/NetCDF/4.1.3/mpi/lib:/smplocal/pub/HDF5/1.8.9/par/lib:/smplocal/pub/FFTW/3.3.3_dyn/lib -L../../LMDZ.COMMON/lib -llmdz 15 15 %MPI_LD -
codes/icosagcm/branches/SATURN_DYNAMICO/ICOSAGCM/compile_dynlmdz_ada
r264 r270 1 1 cd ../LMDZ.COMMON 2 rm -rf libo3 ./makelmdz_fcm -s 1 -d 128x96x64 -b 20x30 -io none -arch X64_ADA -parallel mpi -p std -j 8gcm2 #rm -rf libo 3 ./makelmdz_fcm -s 1 -d 32x24x64 -b 20x30 -io none -arch X64_ADA -parallel mpi -p std -j 8 -full gcm 4 4 cd ../ICOSAGCM 5 5 rm bin/icosa_gcm.exe -
codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/libf/phystd/iostart.F90
r245 r270 44 44 CONTAINS 45 45 46 SUBROUTINE open_startphy(filename )46 SUBROUTINE open_startphy(filename,found) 47 47 USE netcdf, only: NF90_OPEN, NF90_NOERR, NF90_NOWRITE, nf90_strerror 48 48 USE mod_phys_lmdz_para, only: is_master, bcast 49 49 IMPLICIT NONE 50 CHARACTER(LEN=*) :: filename 50 CHARACTER(LEN=*),INTENT(IN) :: filename 51 LOGICAL,INTENT(OUT),OPTIONAL :: found 51 52 INTEGER :: ierr 52 53 … … 56 57 write(*,*)'open_startphy: problem opening file '//trim(filename) 57 58 write(*,*)trim(nf90_strerror(ierr)) 58 CALL ABORT 59 !CALL ABORT 60 found=.false. 61 ELSE 62 found=.true. 59 63 ENDIF 60 64 ENDIF 61 65 62 66 CALL bcast(nid_start) ! tell all procs about nid_start 67 if(present(found)) CALL bcast(found) 63 68 64 69 END SUBROUTINE open_startphy -
codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/libf/phystd/phyetat0_academic.F90
r269 r270 83 83 84 84 INTEGER :: indextime=1 ! index of selected time, default value=1 85 logical :: found 85 logical :: found,found_file 86 86 87 87 ! … … 98 98 99 99 ! open physics initial state file: 100 call open_startphy(fichnom) 101 102 103 ! possibility to modify tab_cntrl in tabfi 104 write(*,*) 105 write(*,*) 'TABFI in phyeta0: Lmodif=',Lmodif," tab0=",tab0 106 call tabfi (ngrid,nid_start,Lmodif,tab0,day_ini,lmax,p_rad, & 100 call open_startphy(fichnom,found_file) 101 102 ! Ehouarn, if file not found, then call tabfi with nid_start==0 103 if (.not.found_file) then 104 write(*,*) 'phyetat0_academic: call tabfi with nid_start=0' 105 call tabfi (ngrid,0,Lmodif,tab0,day_ini,lmax,p_rad, & 107 106 p_omeg,p_g,p_cpp,p_mugaz,p_daysec,time) 108 107 else 108 ! possibility to modify tab_cntrl in tabfi 109 write(*,*) 110 write(*,*) 'TABFI in phyeta0: Lmodif=',Lmodif," tab0=",tab0 111 call tabfi (ngrid,nid_start,Lmodif,tab0,day_ini,lmax,p_rad, & 112 p_omeg,p_g,p_cpp,p_mugaz,p_daysec,time) 113 endif 109 114 !c 110 115 !c Lecture des latitudes (coordonnees): … … 165 170 166 171 ! Load surface geopotential: 167 call get_field("phisfi",phisfi,found) 172 if (found_file) then 173 call get_field("phisfi",phisfi,found) 174 else 175 found=.false. 176 endif 168 177 if (.not.found) then 169 178 write(*,*) "phyetat0: Failed loading <phisfi>" … … 175 184 176 185 ! Load bare ground albedo: 177 call get_field("albedodat",albedodat,found) 186 if (found_file) then 187 call get_field("albedodat",albedodat,found) 188 else 189 found=.false. 190 endif 178 191 if (.not.found) then 179 192 write(*,*) "phyetat0: Failed loading <albedodat>" … … 187 200 188 201 ! ZMEA 189 call get_field("ZMEA",zmea,found) 202 if (found_file) then 203 call get_field("ZMEA",zmea,found) 204 else 205 found=.false. 206 endif 190 207 if (.not.found) then 191 208 zmea(:)=0. … … 196 213 197 214 ! ZSTD 198 call get_field("ZSTD",zstd,found) 215 if (found_file) then 216 call get_field("ZSTD",zstd,found) 217 else 218 found=.false. 219 endif 199 220 if (.not.found) then 200 221 write(*,*) "phyetat0: Failed loading <ZSTD>" … … 206 227 207 228 ! ZSIG 208 call get_field("ZSIG",zsig,found) 229 if (found_file) then 230 call get_field("ZSIG",zsig,found) 231 else 232 found=.false. 233 endif 209 234 if (.not.found) then 210 235 write(*,*) "phyetat0: Failed loading <ZSIG>" … … 216 241 217 242 ! ZGAM 218 call get_field("ZGAM",zgam,found) 243 if (found_file) then 244 call get_field("ZGAM",zgam,found) 245 else 246 found=.false. 247 endif 219 248 if (.not.found) then 220 249 write(*,*) "phyetat0: Failed loading <ZGAM>" … … 226 255 227 256 ! ZTHE 228 call get_field("ZTHE",zthe,found) 257 if (found_file) then 258 call get_field("ZTHE",zthe,found) 259 else 260 found=.false. 261 endif 229 262 if (.not.found) then 230 263 write(*,*) "phyetat0: Failed loading <ZTHE>" … … 236 269 237 270 ! Surface temperature : 238 call get_field("tsurf",tsurf,found,indextime) 239 if (.not.found) then 240 write(*,*) "phyetat0: Failed loading <tsurf>" 241 !mi initialising tsurf with pt(:,1) 242 !tsurf(:)=175.0 271 if (found_file) then 272 call get_field("tsurf",tsurf,found,indextime) 273 else 274 found=.false. 275 endif 276 if (.not.found) then 277 !mi initialising tsurf with pt(:,1) 278 !tsurf(:)=175.0 243 279 else 244 280 write(*,*) "phyetat0: Surface temperature <tsurf> range:", & … … 247 283 248 284 ! Surface emissivity 249 call get_field("emis",emis,found,indextime) 285 if (found_file) then 286 call get_field("emis",emis,found,indextime) 287 else 288 found=.false. 289 endif 250 290 if (.not.found) then 251 291 write(*,*) "phyetat0: Failed loading <emis>" … … 257 297 258 298 ! Cloud fraction (added by BC 2010) 259 call get_field("cloudfrac",cloudfrac,found,indextime) 299 if (found_file) then 300 call get_field("cloudfrac",cloudfrac,found,indextime) 301 else 302 found=.false. 303 endif 260 304 if (.not.found) then 261 305 write(*,*) "phyetat0: Failed loading <cloudfrac>" … … 267 311 268 312 ! Total cloud fraction (added by BC 2010) 269 call get_field("totcloudfrac",totcloudfrac,found,indextime) 313 if (found_file) then 314 call get_field("totcloudfrac",totcloudfrac,found,indextime) 315 else 316 found=.false. 317 endif 270 318 if (.not.found) then 271 319 write(*,*) "phyetat0: Failed loading <totcloudfrac>" … … 277 325 278 326 ! Height of oceanic ice (added by BC 2010) 279 call get_field("hice",hice,found,indextime) 327 if (found_file) then 328 call get_field("hice",hice,found,indextime) 329 else 330 found=.false. 331 endif 280 332 if (.not.found) then 281 333 write(*,*) "phyetat0: Failed loading <hice>" … … 291 343 ! SLAB OCEAN (added by BC 2014) 292 344 ! nature of the surface 293 call get_field("rnat",rnat,found,indextime) 345 if (found_file) then 346 call get_field("rnat",rnat,found,indextime) 347 else 348 found=.false. 349 endif 294 350 if (.not.found) then 295 351 write(*,*) "phyetat0: Failed loading <rnat>" … … 310 366 endif 311 367 ! Pourcentage of sea ice cover 312 call get_field("pctsrf_sic",pctsrf_sic,found,indextime) 368 if (found_file) then 369 call get_field("pctsrf_sic",pctsrf_sic,found,indextime) 370 else 371 found=.false. 372 endif 313 373 if (.not.found) then 314 374 write(*,*) "phyetat0: Failed loading <pctsrf_sic>" … … 321 381 endif 322 382 ! Slab ocean temperature (2 layers) 323 call get_field("tslab",tslab,found,indextime) 383 if (found_file) then 384 call get_field("tslab",tslab,found,indextime) 385 else 386 found=.false. 387 endif 324 388 if (.not.found) then 325 389 write(*,*) "phyetat0: Failed loading <tslab>" … … 334 398 endif 335 399 ! Oceanic ice temperature 336 call get_field("tsea_ice",tsea_ice,found,indextime) 400 if (found_file) then 401 call get_field("tsea_ice",tsea_ice,found,indextime) 402 else 403 found=.false. 404 endif 337 405 if (.not.found) then 338 406 write(*,*) "phyetat0: Failed loading <tsea_ice>" … … 345 413 endif 346 414 ! Oceanic ice quantity (kg/m^2) 347 call get_field("sea_ice",sea_ice,found,indextime) 415 if (found_file) then 416 call get_field("sea_ice",sea_ice,found,indextime) 417 else 418 found=.false. 419 endif 348 420 if (.not.found) then 349 421 write(*,*) "phyetat0: Failed loading <sea_ice>" … … 360 432 361 433 ! pbl wind variance 362 call get_field("q2",q2,found,indextime) 434 if (found_file) then 435 call get_field("q2",q2,found,indextime) 436 else 437 found=.false. 438 endif 363 439 if (.not.found) then 364 440 write(*,*) "phyetat0: Failed loading <q2>" … … 380 456 ' h2o_ice instead of h2o_vap' 381 457 endif 382 call get_field(txt,qsurf(:,iq),found,indextime) 458 if (found_file) then 459 call get_field(txt,qsurf(:,iq),found,indextime) 460 else 461 found=.false. 462 endif 383 463 if (.not.found) then 384 464 write(*,*) "phyetat0: Failed loading <",trim(txt),">" -
codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/libf/phystd/physiq.F90
r269 r270 569 569 !ym rnat,pctsrf_sic,tslab, tsea_ice,sea_ice) 570 570 571 write(*,*) "physiq: firstcall, call phyetat0_academic" 571 572 call phyetat0_academic(ngrid,nlayer,"startfi.nc",0,0,nsoilmx,nq, & 572 573 day_ini,time_phys,tsurf,tsoil,emis,q2,qsurf, & … … 575 576 576 577 !mi initialising tsurf with pt 578 write(*,*) "Physiq: initializing tsurf(:) to pt(:,1) !!" 577 579 tsurf(:)=pt(:,1) 578 580 … … 744 746 745 747 if (ngrid.ne.1) then ! no need to create a restart file in 1d 746 call physdem0("restartfi.nc",long,lati,nsoilmx,ngrid,nlayer,nq, & 747 ptimestep,pday+nday,time_phys,area, & 748 albedodat,inertiedat,zmea,zstd,zsig,zgam,zthe) 748 ! EM: No restart file (for now). 749 ! call physdem0("restartfi.nc",long,lati,nsoilmx,ngrid,nlayer,nq, & 750 ! ptimestep,pday+nday,time_phys,area, & 751 ! albedodat,inertiedat,zmea,zstd,zsig,zgam,zthe) 749 752 endif 750 753 … … 1972 1975 ! cloudfrac,totcloudfrac,hice,noms) 1973 1976 !#endif 1974 call physdem1("restartfi.nc",nsoilmx,ngrid,nlayer,nq, & 1975 ptimestep,ztime_fin, & 1976 tsurf,tsoil,emis,q2,qsurf_hist, & 1977 cloudfrac,totcloudfrac,hice, & 1978 rnat,pctsrf_sic,tslab,tsea_ice,sea_ice) 1977 1978 ! EM: do not write a restart file (for now). 1979 ! call physdem1("restartfi.nc",nsoilmx,ngrid,nlayer,nq, & 1980 ! ptimestep,ztime_fin, & 1981 ! tsurf,tsoil,emis,q2,qsurf_hist, & 1982 ! cloudfrac,totcloudfrac,hice, & 1983 ! rnat,pctsrf_sic,tslab,tsea_ice,sea_ice) 1979 1984 endif 1980 1985 … … 2239 2244 CALL write_xios_field("ASR",fluxabs_sw) 2240 2245 CALL write_xios_field("OLR",fluxtop_lw) 2246 call write_xios_field("input_temp",pt) 2247 call write_xios_field("input_u",pu) 2248 call write_xios_field("input_v",pv) 2249 call write_xios_field("dtrad",dtrad) 2250 call write_xios_field("zdtlw",zdtlw) 2251 call write_xios_field("zdtsw",zdtsw) 2252 call write_xios_field("zdtdyn",zdtdyn/ptimestep) 2253 call write_xios_field("zdtdif",zdtdif) 2254 call write_xios_field("zdtadj",zdtadj) 2255 call write_xios_field("pdt",pdt) 2241 2256 IF (lastcall) CALL finalize_xios_output 2242 2257 … … 2344 2359 endif 2345 2360 2361 write(*,*) "physiq: done, zday=",zday 2346 2362 return 2347 2363 end subroutine physiq -
codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/libf/phystd/tabfi.F
r227 r270 44 44 c======================================================================= 45 45 ! to use 'getin' 46 use ioipsl_getincom , only: getin46 use ioipsl_getincom_p , only: getin_p 47 47 48 48 use surfdat_h, only: albedice, emisice, iceradius, dtemisice, … … 88 88 c Initialization of various physical constants to defaut values (nid = 0 case) 89 89 c----------------------------------------------------------------------- 90 ! Ehouarn: Default Saturn values: 91 tab_cntrl(:)=0 92 write(*,*) "Using default Saturn values..." 93 ! these should be read in a def file I guess... 94 lmax=0 ! not used anyways 95 !day_ini=0 96 time=0 97 ! radius of the planet 98 rad=60268000 99 call getin_p("radius",rad) 100 ! Planetary rotation rate 101 omeg=0.00016512100410182 102 call getin_p("omega",omeg) 103 ! Gravity 104 g=10.44 105 call getin_p("g",g) 106 !mugaz=2.34 !EM: does not give cpp=11500 107 mugaz=2.53 ! with this value of mugaz, cpp=11500 108 call getin_p("mugaz",mugaz) 109 ! kappa 110 rcp=0.2857143 111 call getin_p("kappa",rcp) 112 cpp=(8.314511/(mugaz/1000.0))/rcp 113 call getin_p("cpp",cpp) 114 ! write(*,*) "tabfi: cpp=",cpp 115 ! length (s) of a "standard" day 116 daysec=38052 117 call getin_p("day_length",daysec) 118 ! physics time step (s) ! not sure we need this here 119 dtphys=19026 120 ! length of year, in standard days 121 year_day=24430 122 ! Orbital parameters 123 periastr=9.02151966094971 124 apoastr=10.054479598999 125 peri_day=19280 126 obliquit=26.7299995422363 127 ! Other parameters some physical paréametrizations need 128 z0=1e-2 129 lmixmin=30 130 emin_turb=1.e-6 131 albedice(:)=0 132 emisice(:)=0 133 emissiv=0 134 iceradius(:)=1.e-6 135 dtemisice(:)=0 136 volcapa=1000000 137 c----------------------------------------------------------------------- 138 c Save some constants for later use (as routine arguments) 139 c----------------------------------------------------------------------- 140 p_omeg = omeg 141 p_g = g 142 p_cpp = cpp 143 p_mugaz = mugaz 144 p_daysec = daysec 145 p_rad=rad 146 90 147 ELSE 91 148 c----------------------------------------------------------------------- -
codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/libf/phystd/xios_output.F90
r263 r270 20 20 USE mod_phys_lmdz_para 21 21 USE mod_grid_phy_lmdz 22 USE planete_mod, ONLY: ap,bp,preff 22 23 23 24 IMPLICIT NONE … … 33 34 REAL :: bounds_lat_mpi(klon_mpi,nvertex) 34 35 INTEGER :: l 36 REAL :: presnivs(klev) 35 37 36 38 CALL gather_omp(rlond,lon_mpi) … … 45 47 CALL xios_set_current_context(ctx_hdl) 46 48 47 lev_value(:) = (/ (l,l=1,klev) /) 49 ! lev_value(:) = (/ (l,l=1,klev) /) 50 ! CALL xios_set_axis_attr("altitude",size=klev ,value=lev_value) 48 51 49 CALL xios_set_axis_attr("altitude",size=klev ,value=lev_value) 50 52 ! build presnivs "pseudo-pressure" at mid-layers 53 DO l=1,klev 54 presnivs(l)=0.5*(ap(l)+bp(l)*preff+ap(l+1)+bp(l+1)*preff) 55 ENDDO 56 CALL xios_set_axis_attr("presnivs",size=klev,value=presnivs,unit="Pa",positive="down") 51 57 52 58 CALL xios_set_domain_attr("horiz_domain",ni_glo=klon_glo, ibegin=klon_mpi_begin, ni=klon_mpi) -
codes/icosagcm/branches/SATURN_DYNAMICO/TEST/lmdz_physics.xml
r264 r270 13 13 <field id="OLR" long_name="outgoing longwave rad." unit="W m-2"/> 14 14 15 <field_group axis_ref=" altitude">15 <field_group axis_ref="presnivs"> 16 16 <field id="temp" long_name="temperature" unit="K"/> 17 17 <field id="u" long_name="Zonal wind" unit="m.s-1"/> 18 18 <field id="v" long_name="Meridional wind" unit="m.s-1"/> 19 19 <field id="p" long_name="Pressure" unit="Pa"/> 20 <field id="input_temp" long_name="Input temperature" unit="K"/> 21 <field id="input_u" long_name="Input zonal wind" unit="m/s"/> 22 <field id="input_v" long_name="Input meridional wind" unit="m/s"/> 23 <field id="dtrad" long_name="Total radiative tendency" unit="K/s"/> 24 <field id="zdtlw" long_name="LW radiative tendency" unit="K/s"/> 25 <field id="zdtsw" long_name="SW radiative tendency" unit="K/s"/> 26 <field id="zdtdyn" long_name="Dyn temperature tendency" unit="K/s"/> 27 <field id="zdtdif" long_name="Turbulent diffusion tendency" unit="K/s"/> 28 <field id="zdtadj" long_name="Convective adjustement tendency" unit="K/s"/> 29 <field id="pdt" long_name="Total temperature tendency" unit="K/s"/> 20 30 </field_group> 21 31 … … 23 33 24 34 25 <file_definition type="one_file" par_access="collective" output_freq="1 0ts" sync_freq="10ts" output_level="10" enabled=".TRUE.">35 <file_definition type="one_file" par_access="collective" output_freq="1ts" sync_freq="1ts" output_level="10" enabled=".TRUE."> 26 36 27 37 <file id="xios_diagfi" name="xios_diagfi" > … … 34 44 35 45 46 <!-- <axis_definition> 47 <axis id="altitude"/> 48 </axis_definition> --> 36 49 <axis_definition> 37 <axis id=" altitude"/>50 <axis id="presnivs"/> 38 51 </axis_definition> 39 52 -
codes/icosagcm/branches/SATURN_DYNAMICO/TEST/run_icosa.def
r256 r270 9 9 10 10 # Number of subdivision on a main triangle (nbp) : integer (default=40) 11 nbp= 4011 nbp=10 12 12 13 13 # nbp 20 40 80 160 … … 48 48 itau_adv=3 49 49 50 # number of timestep (default 100) 50 # number of timestep (default 100) (ignored if run_length is set) 51 51 itaumax = 100 52 52 … … 55 55 #run_length=0 56 56 #run_length=432000 57 # one saturn year 58 run_length=929610360 57 # one saturn year (24430 days) 58 #run_length=929610360 59 # 5 saturn day (5*38052=190260) 60 #run_length=190260 61 # 1 saturn day 62 run_length=38052 63 # 100 saturn days 64 #run_length=3805200 65 # 2000 saturn days 66 #run_length=76104000 59 67 60 68 #activate IO (default = true) … … 79 87 # etat0 : initial state : string (default=jablonowsky06) : 80 88 # jablonowsky06, academic, ncar 81 etat0=isothermal 82 etat0_isothermal_temp=175 89 #etat0=isothermal 90 #etat0_isothermal_temp=175 91 92 etat0=temperature_profile 93 # for 'etat0=temperature_profile" 94 # initial temperature profile provided in file 95 temperature_profile_file=temp_profile.txt 96 97 #etat0=start_file 98 # for 'etat0=start_file" 99 # start file name (default is start.nc) 100 # start_file_name=start 101 # restart file name (default is restart.nc) 102 #restart_file_name=restart 103 83 104 # ------------------------------ Dynamics -------------------------------- 84 105
Note: See TracChangeset
for help on using the changeset viewer.