Changeset 5478
- Timestamp:
- Jan 16, 2025, 10:10:56 AM (4 hours ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ6/trunk/libf/phylmd/cv3_routines.f90
r5469 r5478 4938 4938 USE lmdz_cv_ini, ONLY : nl 4939 4939 USE cvflag_mod_h 4940 USE ioipsl_getin_p_mod, ONLY : getin_p 4940 4941 IMPLICIT NONE 4941 4942 4942 4943 4943 4944 !inputs: 4945 !------ 4944 4946 INTEGER, INTENT (IN) :: ncum, nd, na, nloc, len 4945 4947 INTEGER, DIMENSION (len), INTENT (IN) :: icb, inb … … 4949 4951 REAL, DIMENSION (len, nd+1), INTENT (IN) :: Vprecip 4950 4952 !ouputs: 4953 !------ 4951 4954 REAL, DIMENSION (len, na, na), INTENT (OUT) :: phi, phi2, epmlmMm 4952 4955 REAL, DIMENSION (len, na), INTENT (OUT) :: da, d1a, dam, eplaMm 4953 4956 ! 4957 !local variables: 4958 !--------------- 4954 4959 ! variables pour tracer dans precip de l'AA et des mel 4955 !local variables:4956 4960 INTEGER i, j, k 4957 4961 REAL epm(nloc, na, na) 4962 ! 4963 LOGICAL,SAVE :: first=.TRUE. 4964 LOGICAL,SAVE :: keep_bug_indices_cv3_tracer 4965 !$OMP_THREADPRIVATE (first, keep_bug_indices_cv3_tracer) 4958 4966 4959 4967 ! variables d'Emanuel : du second indice au troisieme … … 4962 4970 ! variables personnelles : du troisieme au second indice 4963 4971 ! ---> tab(i,j,k) -> de k a j 4964 ! phi, phi2 4965 4972 ! phi, phi2, epm, epmlmMm 4973 4974 IF (first) THEN 4975 keep_bug_indices_cv3_tracer = .FALSE. 4976 CALL getin_p('keep_bug_indices_cv3_tracer', keep_bug_indices_cv3_tracer) 4977 first = .FALSE. 4978 ENDIF ! (first) 4966 4979 ! initialisations 4967 4980 … … 5022 5035 d1a(i, j) = d1a(i, j) + ment(i, k, j)*ep(i, k)*(1.-sigij(i,k,j)) 5023 5036 IF (k<=j) THEN 5024 !!jyg dam(i, j) = dam(i, j) + ment(i, k, j)*epm(i, k, j)*(1.-ep(i,k))*(1.-sigij(i,k,j))5025 dam(i, j) = dam(i, j) + ment(i, k, j)*epm(i, j, k)*(1.-ep(i,k))*(1.-sigij(i,k,j))5026 5037 phi2(i, j, k) = phi(i, j, k)*epm(i, j, k) 5027 5038 END IF … … 5029 5040 END DO 5030 5041 END DO 5042 5043 IF (keep_bug_indices_cv3_tracer) THEN 5044 DO j = 1, nl 5045 DO k = 1, nl 5046 DO i = 1, ncum 5047 IF (k<=j) THEN 5048 dam(i, j) = dam(i, j) + ment(i, k, j)*epm(i, k, j)*(1.-ep(i,k))*(1.-sigij(i,k,j)) 5049 END IF ! (k<=j) 5050 END DO 5051 END DO 5052 END DO 5053 ELSE ! (keep_bug_indices_cv3_tracer) 5054 DO j = 1, nl 5055 DO k = 1, nl 5056 DO i = 1, ncum 5057 IF (k<=j) THEN 5058 dam(i, j) = dam(i, j) + ment(i, k, j)*epm(i, j, k)*(1.-ep(i,k))*(1.-sigij(i,k,j)) 5059 END IF ! (k<=j) 5060 END DO 5061 END DO 5062 END DO 5063 ENDIF ! (keep_bug_indices_cv3_tracer) 5031 5064 5032 5065 RETURN
Note: See TracChangeset
for help on using the changeset viewer.