Changeset 4840
- Timestamp:
- Mar 2, 2024, 7:21:43 PM (10 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ6/trunk/libf/phylmd/lmdz_wake.F90
r4839 r4840 319 319 REAL, DIMENSION (klon) :: h_zzz 320 320 321 print*,'WAKE LJYFz'321 ! print*,'WAKE LJYFzzzzz' 322 322 323 323 ! ------------------------------------------------------------------------- … … 2422 2422 USE lmdz_wake_ini , ONLY : RG 2423 2423 USE lmdz_wake_ini , ONLY : hwmin 2424 2424 2425 IMPLICIT NONE 2425 2426 2426 INTEGER, INTENT(IN) :: klon,klev 2427 REAL, INTENT(IN), DIMENSION (klon,klev+1) :: ph, p 2428 REAL, INTENT(IN), DIMENSION (klon,klev+1) :: rho 2429 LOGICAL, INTENT(IN), DIMENSION (klon) :: wk_adv 2430 REAL, INTENT(IN), DIMENSION (klon,klev+1) :: dth 2431 2432 REAL, INTENT(OUT), DIMENSION (klon) :: hw_ 2433 REAL, INTENT(OUT), DIMENSION (klon) :: ptop 2434 INTEGER, INTENT(OUT), DIMENSION (klon) :: Ktop 2435 REAL, INTENT(OUT), DIMENSION (klon) :: pupper 2436 INTEGER, INTENT(OUT), DIMENSION (klon) :: kupper 2437 INTEGER :: i,k 2438 2427 INTEGER, INTENT(IN) :: klon,klev 2428 REAL, DIMENSION (klon,klev+1) , INTENT(IN) :: ph, p 2429 REAL, DIMENSION (klon,klev+1) , INTENT(IN) :: rho 2430 LOGICAL, DIMENSION (klon) , INTENT(IN) :: wk_adv 2431 REAL, DIMENSION (klon,klev+1) , INTENT(IN) :: dth 2439 2432 REAL, INTENT(IN) :: delta_t_min 2440 2433 2434 REAL, DIMENSION (klon) , INTENT(OUT) :: hw_ 2435 REAL, DIMENSION (klon) , INTENT(OUT) :: ptop 2436 INTEGER, DIMENSION (klon) , INTENT(OUT) :: Ktop 2437 REAL, DIMENSION (klon) , INTENT(OUT) :: pupper 2438 INTEGER, DIMENSION (klon) , INTENT(OUT) :: kupper 2441 2439 REAL, DIMENSION (klon) , INTENT(OUT) :: h_zzz !! 2442 2440 REAL, DIMENSION (klon) , INTENT(OUT) :: Ptop1 !! 2443 2441 INTEGER, DIMENSION (klon) , INTENT(OUT) :: ktop1 !! 2444 2442 2443 INTEGER :: i,k 2445 2444 2446 2445 REAL, DIMENSION (klon) :: dthmin … … 2487 2486 DO k = 2, klev 2488 2487 DO i = 1, klon 2489 ! if (compte==92) then2490 ! print*,'debug xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx'2491 ! print*,'debug i =',i2492 ! print*,'debug k =',k2493 ! print*,'debug wk_adv(i) =',wk_adv(i)2494 ! print*,'debug ptop_provis(i) =',ptop_provis(i)2495 ! print*,'debug ph(i,1) =',ph(i,1)2496 ! print*,'debug dth(i,k) =',dth(i,k)2497 ! print*,'debug delta_t_min =',delta_t_min2498 ! print*,'debug p(i,k-1) =',p(i,k-1)2499 ! print*,'debug dth(i,k-1) =',dth(i,k-1)2500 ! print*,'debug p(i,k) =',p(i,k)2501 ! endif2502 2488 IF (wk_adv(i) .AND. ptop_provis(i)==ph(i,1) .AND. & 2503 2489 ! LJYF changer : dth(i,k)>=-delta_t_min .AND. dth(i,k-1)<-delta_t_min) THEN … … 2597 2583 ! PRINT *, 'wake-3, ktop(igout), kupper(igout) ', ktop(igout), kupper(igout) 2598 2584 ! ENDIF 2599 2600 kupper = 02601 2602 IF (wk_pupper<1.) THEN2603 ! Choose an integration bound well above wake top2604 ! -----------------------------------------------------------------2605 2606 ! Pupper = 50000. ! melting level2607 ! Pupper = 60000.2608 ! Pupper = 80000. ! essais pour case_e2609 DO i = 1, klon2610 ! pupper(i) = 0.6*ph(i, 1)2611 pupper(i) = wk_pupper*ph(i, 1)2612 pupper(i) = max(pupper(i), 45000.)2613 ! cc Pupper(i) = 60000.2614 END DO2615 2616 ELSE2617 2618 DO i=1, klon2619 ! pupper(i) = wk_pupper*ptop(i)+(1.-wk_pupper)*ph(i, 1)2620 pupper(i) = min( wk_pupper*ptop(i)+(1.-wk_pupper)*ph(i, 1) , ptop(i)-5000.)2621 END DO2622 END IF2623 2624 ! -5/ Determination de kupper2625 2626 DO k = klev, 1, -12627 DO i = 1, klon2628 IF (ph(i,k+1)<pupper(i)) kupper(i) = k2629 END DO2630 END DO2631 2632 ! On evite kupper = 1 et kupper = klev2633 DO i = 1, klon2634 kupper(i) = max(kupper(i), 2)2635 kupper(i) = min(kupper(i), klev-1)2636 END DO2637 2585 2638 2586 ! ----------------------------------------------------------------------- … … 2729 2677 2730 2678 endif 2679 2680 kupper = 0 2681 2682 IF (wk_pupper<1.) THEN 2683 ! Choose an integration bound well above wake top 2684 ! ----------------------------------------------------------------- 2685 2686 ! Pupper = 50000. ! melting level 2687 ! Pupper = 60000. 2688 ! Pupper = 80000. ! essais pour case_e 2689 DO i = 1, klon 2690 ! pupper(i) = 0.6*ph(i, 1) 2691 pupper(i) = wk_pupper*ph(i, 1) 2692 pupper(i) = max(pupper(i), 45000.) 2693 ! cc Pupper(i) = 60000. 2694 END DO 2695 2696 ELSE 2697 2698 DO i=1, klon 2699 ! pupper(i) = wk_pupper*ptop(i)+(1.-wk_pupper)*ph(i, 1) 2700 pupper(i) = min( wk_pupper*ptop(i)+(1.-wk_pupper)*ph(i, 1) , ptop(i)-5000.) 2701 END DO 2702 END IF 2703 2704 ! -5/ Determination de kupper 2705 2706 DO k = klev, 1, -1 2707 DO i = 1, klon 2708 IF (ph(i,k+1)<pupper(i)) kupper(i) = k 2709 END DO 2710 END DO 2711 2712 ! On evite kupper = 1 et kupper = klev 2713 DO i = 1, klon 2714 kupper(i) = max(kupper(i), 2) 2715 kupper(i) = min(kupper(i), klev-1) 2716 END DO 2731 2717 !---------- FIN nouveau calcul hw et ptop ------------------------------------- 2732 2718
Note: See TracChangeset
for help on using the changeset viewer.