Changeset 776 for trunk/LMDZ.COMMON/libf/dyn3d/leapfrog.F
- Timestamp:
- Sep 7, 2012, 2:49:58 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LMDZ.COMMON/libf/dyn3d/leapfrog.F
r500 r776 124 124 125 125 REAL SSUM 126 REAL time_0 , finvmaold(ip1jmp1,llm) 126 REAL time_0 127 ! REAL finvmaold(ip1jmp1,llm) 127 128 128 129 cym LOGICAL lafin … … 243 244 dq(:,:,:)=0. 244 245 CALL pression ( ip1jmp1, ap, bp, ps, p ) 245 if ( disvert_type==1) then246 if (pressure_exner) then 246 247 CALL exner_hyb( ip1jmp1, ps, p,alpha,beta, pks, pk, pkf ) 247 else ! we assume that we are in the disvert_type==2 case248 else 248 249 CALL exner_milieu( ip1jmp1, ps, p, beta, pks, pk, pkf ) 249 250 endif … … 271 272 c ---------------------------------- 272 273 273 1 CONTINUE 274 1 CONTINUE ! Matsuno Forward step begins here 274 275 275 276 jD_cur = jD_ref + day_ini - day_ref + & 276 & i nt (itau * dtvr / daysec)277 & itau/day_step 277 278 jH_cur = jH_ref + start_time + & 278 & (itau * dtvr / daysec - int(itau * dtvr / daysec))279 & mod(itau,day_step)/float(day_step) 279 280 jD_cur = jD_cur + int(jH_cur) 280 281 jH_cur = jH_cur - int(jH_cur) … … 307 308 308 309 c ... P.Le Van .26/04/94 .... 309 310 CALL SCOPY ( ijp1llm, masse, 1, finvmaold, 1 )311 CALL filtreg ( finvmaold ,jjp1, llm, -2,2, .TRUE., 1 )312 313 2 CONTINUE 310 ! Ehouarn: finvmaold is actually not used 311 ! CALL SCOPY ( ijp1llm, masse, 1, finvmaold, 1 ) 312 ! CALL filtreg ( finvmaold ,jjp1, llm, -2,2, .TRUE., 1 ) 313 314 2 CONTINUE ! Matsuno backward or leapfrog step begins here 314 315 315 316 c----------------------------------------------------------------------- … … 357 358 call tpot2t(ijp1llm,teta,temp,pk) 358 359 tsurpk = cpp*temp/pk 360 ! compute geopotential phi() 359 361 CALL geopot ( ip1jmp1, tsurpk , pk , pks, phis , phi ) 360 362 … … 372 374 373 375 ! IF( forward. OR . leapf ) THEN 376 ! Ehouarn: NB: at this point p with ps are not synchronized 377 ! (whereas mass and ps are...) 374 378 IF((.not.forward).OR. leapf ) THEN 375 379 ! Ehouarn: gather mass fluxes during backward Matsuno or LF step … … 398 402 399 403 CALL integrd ( 2,vcovm1,ucovm1,tetam1,psm1,massem1 , 400 $ dv,du,dteta,dq,dp,vcov,ucov,teta,q,ps,masse,phis ,401 $ finvmaold )404 $ dv,du,dteta,dq,dp,vcov,ucov,teta,q,ps,masse,phis ) 405 ! $ finvmaold ) 402 406 403 407 IF ((planet_type.eq."titan").and.(tidal)) then … … 431 435 432 436 CALL pression ( ip1jmp1, ap, bp, ps, p ) 433 if ( disvert_type==1) then437 if (pressure_exner) then 434 438 CALL exner_hyb( ip1jmp1, ps, p,alpha,beta,pks, pk, pkf ) 435 else ! we assume that we are in the disvert_type==2 case439 else 436 440 CALL exner_milieu( ip1jmp1, ps, p, beta, pks, pk, pkf ) 437 441 endif 438 442 439 443 jD_cur = jD_ref + day_ini - day_ref + & 440 & i nt (itau * dtvr / daysec)444 & itau/day_step 441 445 jH_cur = jH_ref + start_time + & 442 & (itau * dtvr / daysec - int(itau * dtvr / daysec))446 & mod(itau,day_step)/float(day_step) 443 447 jD_cur = jD_cur + int(jH_cur) 444 448 jH_cur = jH_cur - int(jH_cur) … … 545 549 546 550 CALL pression ( ip1jmp1, ap, bp, ps, p ) 547 if ( disvert_type==1) then551 if (pressure_exner) then 548 552 CALL exner_hyb( ip1jmp1, ps, p,alpha,beta, pks, pk, pkf ) 549 else ! we assume that we are in the disvert_type==2 case553 else 550 554 CALL exner_milieu( ip1jmp1, ps, p, beta, pks, pk, pkf ) 551 555 endif … … 613 617 ENDDO 614 618 615 DO ij = 1,iim 616 tppn(ij) = aire( ij ) * ps ( ij ) 617 tpps(ij) = aire(ij+ip1jm) * ps (ij+ip1jm) 618 ENDDO 619 tpn = SSUM(iim,tppn,1)/apoln 620 tps = SSUM(iim,tpps,1)/apols 621 622 DO ij = 1, iip1 623 ps( ij ) = tpn 624 ps(ij+ip1jm) = tps 625 ENDDO 626 619 if (1 == 0) then 620 !!! Ehouarn: lines here 1) kill 1+1=2 in the dynamics 621 !!! 2) should probably not be here anyway 622 !!! but are kept for those who would want to revert to previous behaviour 623 DO ij = 1,iim 624 tppn(ij) = aire( ij ) * ps ( ij ) 625 tpps(ij) = aire(ij+ip1jm) * ps (ij+ip1jm) 626 ENDDO 627 tpn = SSUM(iim,tppn,1)/apoln 628 tps = SSUM(iim,tpps,1)/apols 629 630 DO ij = 1, iip1 631 ps( ij ) = tpn 632 ps(ij+ip1jm) = tps 633 ENDDO 634 endif ! of if (1 == 0) 627 635 628 636 END IF ! of IF(apdiss) … … 749 757 750 758 CLOSE(99) 759 !!! Ehouarn: Why not stop here and now? 751 760 ENDIF ! of IF (itau.EQ.itaufin) 752 761
Note: See TracChangeset
for help on using the changeset viewer.