Changeset 1960 for LMDZ5/trunk/libf/phy1d/1DUTILS.h
- Timestamp:
- Feb 7, 2014, 5:20:25 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ5/trunk/libf/phy1d/1DUTILS.h
r1953 r1960 4 4 c 5 5 c 6 SUBROUTINE conf_unicol ( tapedef )6 SUBROUTINE conf_unicol 7 7 c 8 8 #ifdef CPP_IOIPSL … … 15 15 c----------------------------------------------------------------------- 16 16 c Auteurs : A. Lahellec . 17 c18 c Arguments :19 c20 c tapedef :21 22 INTEGER tapedef23 17 c 24 18 c Declarations : … … 367 361 c Variables locales pour NetCDF: 368 362 c ------------------------------ 369 INTEGER nid, nvarid370 INTEGER idim_s371 INTEGER ierr, ierr_file372 363 INTEGER iq 373 364 INTEGER length … … 378 369 character*80 abort_message 379 370 LOGICAL found 380 c381 INTEGER nb382 371 383 372 modname = 'dyn1deta0 : ' … … 508 497 c ---------- 509 498 CHARACTER*(*) fichnom 510 REAL time511 499 cAl1 plev tronque pour .nc mais plev(klev+1):=0 512 500 real :: plev(klon,klev),play (klon,klev),phi(klon,klev) … … 520 508 c Variables locales pour NetCDF: 521 509 c ------------------------------ 522 INTEGER nid, nvarid 523 INTEGER idim_s 524 INTEGER ierr, ierr_file 510 INTEGER nid 511 INTEGER ierr 525 512 INTEGER iq,l 526 513 INTEGER length … … 535 522 DATA nb / 0 / 536 523 537 REAL zan0,zjulian,hours538 INTEGER yyears0,jjour0, mmois0539 character*30 unites540 541 cDbg542 524 CALL open_restartphy(fichnom) 543 525 print*,'redm1 ',fichnom,klon,klev,nqtot … … 550 532 ierr = NF_OPEN(fichnom, NF_WRITE, nid) 551 533 IF (ierr .NE. NF_NOERR) THEN 552 PRINT*,"Pb. d ouverture "//fichnom553 CALL abort 534 abort_message="Pb. d ouverture "//fichnom 535 CALL abort_gcm('Modele 1D',abort_message,1) 554 536 ENDIF 555 537 … … 661 643 ! traitement des point normaux 662 644 DO j=2,jm-1 663 645 ig=2+(j-2)*(im-1) 664 646 CALL SCOPY(im-1,pfi(ig,ifield),1,pdyn(1,j,ifield),1) 665 647 pdyn(im,j,ifield)=pdyn(1,j,ifield) 666 648 ENDDO 667 649 ENDDO … … 992 974 DO ifield=1,nfield 993 975 DO j=2,jm-1 994 976 ig=2+(j-2)*(im-1) 995 977 CALL SCOPY(im-1,pdyn(1,j,ifield),1,pfi(ig,ifield),1) 996 978 ENDDO … … 1151 1133 1152 1134 !====================================================================== 1153 SUBROUTINE read_tsurf1d(knon, knindex,sst_out)1135 SUBROUTINE read_tsurf1d(knon,sst_out) 1154 1136 1155 1137 ! This subroutine specifies the surface temperature to be used in 1D simulations … … 1158 1140 1159 1141 INTEGER, INTENT(IN) :: knon ! nomber of points on compressed grid 1160 INTEGER, DIMENSION(klon), INTENT(IN) :: knindex ! grid point number for compressed grid1161 1142 REAL, DIMENSION(klon), INTENT(OUT) :: sst_out ! tsurf used to force the single-column model 1162 1143 … … 1220 1201 1221 1202 SUBROUTINE advect_va(llm,omega,d_t_va,d_q_va,d_u_va,d_v_va, 1222 ! q,temp,u,v, 1223 ! play,plev) 1203 s q,temp,u,v,play) 1224 1204 !itlmd 1225 1205 !---------------------------------------------------------------------- … … 1237 1217 real q(llm,3),temp(llm) 1238 1218 real u(llm),v(llm) 1239 real play(llm) ,plev(llm+1)1219 real play(llm) 1240 1220 ! interne 1241 1221 integer l … … 1323 1303 real dph(llm),dqdp(llm),dtdp(llm) 1324 1304 ! interne 1325 integer l,k1326 real alpha,omdn,omup1305 integer k 1306 real omdn,omup 1327 1307 1328 1308 ! dudp=0. … … 1403 1383 character*80 fich_toga 1404 1384 1405 integer no,l,k,ip1406 real riy,rim,rid,rih,bid1385 integer k,ip 1386 real bid 1407 1387 1408 1388 integer iy,im,id,ih … … 1422 1402 1423 1403 do k = 1, nlev_toga 1424 read(21,230) plev_toga(k,ip), t_toga(k,ip), q_toga(k,ip) 1404 read(21,230) plev_toga(k,ip), t_toga(k,ip), q_toga(k,ip) 1425 1405 : ,u_toga(k,ip), v_toga(k,ip), w_toga(k,ip) 1426 1406 : ,ht_toga(k,ip), vt_toga(k,ip), hq_toga(k,ip), vq_toga(k,ip) … … 1443 1423 1444 1424 223 format(4i3,6f8.2) 1445 226 format(f7.1,1x,10f8.2)1446 227 format(f7.1,1x,1p,4e11.3)1447 1425 230 format(6f9.3,4e11.3) 1448 1426 … … 1462 1440 character*80 fich_sandu 1463 1441 1464 integer no,l,k,ip 1465 real riy,rim,rid,rih,bid 1466 1442 integer ip 1467 1443 integer iy,im,id,ih 1468 1444 1469 real plev_min 1470 1471 plev_min = 55000. ! pas de tendance de vap. d eau au-dessus de 55 hPa 1445 real plev_min 1446 1447 print*,'nlev_sandu',nlev_sandu 1448 plev_min = 55000. ! pas de tendance de vap. d eau au-dessus de 55 hPa 1472 1449 1473 1450 open(21,file=trim(fich_sandu),form='formatted') … … 1482 1459 1483 1460 223 format(4i3,f8.2) 1484 226 format(f7.1,1x,10f8.2)1485 227 format(f7.1,1x,1p,4e11.3)1486 230 format(6f9.3,4e11.3)1487 1461 1488 1462 return … … 1504 1478 character*80 fich_astex 1505 1479 1506 integer no,l,k,ip 1507 real riy,rim,rid,rih,bid 1508 1480 integer ip 1509 1481 integer iy,im,id,ih 1510 1482 1511 1483 real plev_min 1512 1484 1485 print*,'nlev_astex',nlev_astex 1513 1486 plev_min = 55000. ! pas de tendance de vap. d eau au-dessus de 55 hPa 1514 1487 … … 1528 1501 1529 1502 223 format(4i3,e13.2,f7.2,f7.3,f7.2,f7.3,f7.2) 1530 226 format(f7.1,1x,10f8.2)1531 227 format(f7.1,1x,1p,4e11.3)1532 230 format(6f9.3,4e11.3)1533 1503 1534 1504 return … … 1551 1521 character*80 :: fich_twpice 1552 1522 real*8 time(ntime) 1553 real*8 lat, lon, alt, phis 1523 real*8 lat, lon, alt, phis 1554 1524 real*8 lev(nlevel) 1555 1525 real*8 plev(nlevel,ntime) … … 1561 1531 real*8 T_adv_h(nlevel,ntime) 1562 1532 real*8 T_adv_v(nlevel,ntime), q_adv_h(nlevel,ntime) 1563 real*8 q_adv_v(nlevel,ntime) 1533 real*8 q_adv_v(nlevel,ntime) 1564 1534 real*8 s(nlevel,ntime), s_adv_h(nlevel,ntime) 1565 1535 real*8 s_adv_v(nlevel,ntime) … … 1976 1946 integer ierr 1977 1947 1978 integer i1979 1948 integer timevar,levvar 1980 1949 integer timelen,levlen … … 2050 2019 real omega_mod(llm),o3mmr_mod(llm) 2051 2020 2052 integer l,k,k1,k2 ,kp2053 real aa,frac,frac1,frac2,fact2021 integer l,k,k1,k2 2022 real frac,frac1,frac2,fact 2054 2023 2055 2024 do l = 1, llm … … 2168 2137 real o3mmr_mod(llm),ql_mod(llm),qt_mod(llm) 2169 2138 2170 integer l,k,k1,k2 ,kp2171 real aa,frac,frac1,frac2,fact2139 integer l,k,k1,k2 2140 real frac,frac1,frac2,fact 2172 2141 2173 2142 do l = 1, llm … … 2444 2413 real ts_prof 2445 2414 ! local: 2446 integer it_sandu1, it_sandu2 ,k2415 integer it_sandu1, it_sandu2 2447 2416 real timeit,time_sandu1,time_sandu2,frac 2448 2417 ! Check that initial day of the simulation consistent with SANDU period: … … 2511 2480 character*80 fich_armcu 2512 2481 2513 integer no,l,k,ip 2514 real riy,rim,rid,rih,bid 2482 integer ip 2515 2483 2516 2484 integer iy,im,id,ih,in 2485 2486 print*,'nlev_armcu',nlev_armcu 2517 2487 2518 2488 open(21,file=trim(fich_armcu),form='formatted') … … 2529 2499 2530 2500 223 format(5i3,5f8.3) 2531 226 format(f7.1,1x,10f8.2)2532 227 format(f7.1,1x,1p,4e11.3)2533 230 format(6f9.3,4e11.3)2534 2501 2535 2502 return … … 2571 2538 real hq_mod(llm),vq_mod(llm) 2572 2539 2573 integer l,k,k1,k2 ,kp2574 real aa,frac,frac1,frac2,fact2540 integer l,k,k1,k2 2541 real frac,frac1,frac2,fact 2575 2542 2576 2543 do l = 1, llm … … 2684 2651 real div_prof,ts_prof,ug_prof,vg_prof,ufa_prof,vfa_prof 2685 2652 ! local: 2686 integer it_astex1, it_astex2 ,k2653 integer it_astex1, it_astex2 2687 2654 real timeit,time_astex1,time_astex2,frac 2688 2655 … … 2985 2952 2986 2953 integer, parameter :: ilesfile=1 2987 integer :: ierr,irad,imax,jtot,k,itrac,nt1,nt2 2988 logical :: lmoist,lcoriol,ltimedep 2989 real :: xsize,ysize 2990 real :: ustin,wsvsurf,timerad 2991 character(80) :: chmess 2954 integer :: ierr,k,itrac,nt1,nt2 2992 2955 2993 2956 if(.not.(llesread)) return … … 3043 3006 implicit none 3044 3007 3045 integer nlev_max,kmax ,kmax23008 integer nlev_max,kmax 3046 3009 logical :: llesread = .true. 3047 3010 … … 3052 3015 3053 3016 integer, parameter :: ilesfile=1 3054 integer :: ierr,irad,imax,jtot,k 3055 logical :: lmoist,lcoriol,ltimedep 3056 real :: xsize,ysize 3057 real :: ustin,wsvsurf,timerad 3058 character(80) :: chmess 3017 integer :: k,ierr 3059 3018 3060 3019 if(.not.(llesread)) return … … 3079 3038 implicit none 3080 3039 3081 integer nlev_max,kmax ,kmax23040 integer nlev_max,kmax 3082 3041 logical :: llesread = .true. 3083 3042 … … 3088 3047 3089 3048 integer, parameter :: ilesfile=1 3090 integer :: ierr,irad,imax,jtot,k 3091 logical :: lmoist,lcoriol,ltimedep 3092 real :: xsize,ysize 3093 real :: ustin,wsvsurf,timerad 3094 character(80) :: chmess 3049 integer :: ierr,k 3095 3050 3096 3051 if(.not.(llesread)) return … … 3117 3072 implicit none 3118 3073 3119 integer nlev_max,kmax ,kmax23074 integer nlev_max,kmax 3120 3075 logical :: llesread = .true. 3121 3076 … … 3127 3082 integer, parameter :: ilesfile=1 3128 3083 integer, parameter :: ifile=2 3129 integer :: ierr,irad,imax,jtot,k 3130 logical :: lmoist,lcoriol,ltimedep 3131 real :: xsize,ysize 3132 real :: ustin,wsvsurf,timerad 3133 character(80) :: chmess 3084 integer :: ierr,jtot,k 3134 3085 3135 3086 if(.not.(llesread)) return … … 3182 3133 3183 3134 integer ntime,nlevel 3184 integer l,k3185 3135 character*80 :: fich_amma 3186 real*8 time(ntime) 3187 real*8 zz(nlevel) 3136 real*8 zz(nlevel) 3188 3137 3189 3138 real*8 temp(nlevel),pp(nlevel) … … 3192 3141 real*8 dw(nlevel,ntime) 3193 3142 real*8 dt(nlevel,ntime) 3194 real*8 dq(nlevel,ntime) 3143 real*8 dq(nlevel,ntime) 3195 3144 real*8 flat(ntime),sens(ntime) 3196 3145 … … 3522 3471 3523 3472 integer ntime,nlevel 3524 integer l,k3525 3473 character*80 :: fich_fire 3526 real*8 time(ntime) 3527 real*8 zz(nlevel) 3474 real*8 zz(nlevel) 3528 3475 3529 3476 real*8 thl(nlevel) … … 3532 3479 real*8 ug(nlevel,ntime),vg(nlevel,ntime),wls(nlevel,ntime) 3533 3480 real*8 dqtdx(nlevel,ntime),dqtdy(nlevel,ntime) 3534 real*8 dqtdt(nlevel,ntime),thl_rad(nlevel,ntime) 3481 real*8 dqtdt(nlevel,ntime),thl_rad(nlevel,ntime) 3535 3482 3536 3483 integer nid, ierr
Note: See TracChangeset
for help on using the changeset viewer.