Directory: | ./ |
---|---|
File: | dyn3d_common/psextbar.f |
Date: | 2022-01-11 19:19:34 |
Exec | Total | Coverage | |
---|---|---|---|
Lines: | 10 | 10 | 100.0% |
Branches: | 6 | 6 | 100.0% |
Line | Branch | Exec | Source |
---|---|---|---|
1 | ! | ||
2 | ! $Header$ | ||
3 | ! | ||
4 | 2881 | SUBROUTINE psextbar ( ps, psexbarxy ) | |
5 | IMPLICIT NONE | ||
6 | |||
7 | c======================================================================= | ||
8 | c | ||
9 | c Auteur: P. Le Van | ||
10 | c ------- | ||
11 | c | ||
12 | c Objet: | ||
13 | c ------ | ||
14 | c | ||
15 | c ********************************************************************** | ||
16 | c calcul des moyennes en x et en y de (pression au sol*aire variable) .. | ||
17 | c ********************************************************************** | ||
18 | c | ||
19 | c ps est un argum. d'entree pour le s-pg .. | ||
20 | c psexbarxy est un argum. de sortie pour le s-pg .. | ||
21 | c | ||
22 | c Methode: | ||
23 | c -------- | ||
24 | c | ||
25 | c A chaque point scalaire P (i,j) est affecte 4 coefficients d'aires | ||
26 | c alpha1(i,j) calcule au point ( i+1/4,j-1/4 ) | ||
27 | c alpha2(i,j) calcule au point ( i+1/4,j+1/4 ) | ||
28 | c alpha3(i,j) calcule au point ( i-1/4,j+1/4 ) | ||
29 | c alpha4(i,j) calcule au point ( i-1/4,j-1/4 ) | ||
30 | c | ||
31 | c Avec alpha1(i,j) = aire(i+1/4,j-1/4)/ aire(i,j) | ||
32 | c | ||
33 | c N.B . Pour plus de details, voir s-pg ... iniconst ... | ||
34 | c | ||
35 | c | ||
36 | c | ||
37 | c alpha4 . . alpha1 . alpha4 | ||
38 | c (i,j) (i,j) (i+1,j) | ||
39 | c | ||
40 | c P . U . . P | ||
41 | c (i,j) (i,j) (i+1,j) | ||
42 | c | ||
43 | c alpha3 . . alpha2 .alpha3 | ||
44 | c (i,j) (i,j) (i+1,j) | ||
45 | c | ||
46 | c V . Z . . V | ||
47 | c (i,j) | ||
48 | c | ||
49 | c alpha4 . . alpha1 .alpha4 | ||
50 | c (i,j+1) (i,j+1) (i+1,j+1) | ||
51 | c | ||
52 | c P . U . . P | ||
53 | c (i,j+1) (i+1,j+1) | ||
54 | c | ||
55 | c | ||
56 | c | ||
57 | c | ||
58 | c On a : | ||
59 | c | ||
60 | c pbarx(i,j) = Pext(i ,j) * ( alpha1(i ,j) + alpha2(i,j)) + | ||
61 | c Pext(i+1,j) * ( alpha3(i+1,j) + alpha4(i+1,j) ) | ||
62 | c localise au point ... U (i,j) ... | ||
63 | c | ||
64 | c pbary(i,j) = Pext(i,j ) * ( alpha2(i,j ) + alpha3(i,j ) + | ||
65 | c Pext(i,j+1) * ( alpha1(i,j+1) + alpha4(i,j+1) | ||
66 | c localise au point ... V (i,j) ... | ||
67 | c | ||
68 | c pbarxy(i,j)= Pext(i,j) *alpha2(i,j) + Pext(i+1,j) *alpha3(i+1,j) + | ||
69 | c Pext(i,j+1)*alpha1(i,j+1)+ Pext(i+1,j+1)*alpha4(i+1,j+1) | ||
70 | c localise au point ... Z (i,j) ... | ||
71 | c | ||
72 | c | ||
73 | c | ||
74 | c======================================================================= | ||
75 | |||
76 | |||
77 | !----------------------------------------------------------------------- | ||
78 | ! INCLUDE 'dimensions.h' | ||
79 | ! | ||
80 | ! dimensions.h contient les dimensions du modele | ||
81 | ! ndm est tel que iim=2**ndm | ||
82 | !----------------------------------------------------------------------- | ||
83 | |||
84 | INTEGER iim,jjm,llm,ndm | ||
85 | |||
86 | PARAMETER (iim= 32,jjm=32,llm=39,ndm=1) | ||
87 | |||
88 | !----------------------------------------------------------------------- | ||
89 | ! | ||
90 | ! $Header$ | ||
91 | ! | ||
92 | ! | ||
93 | ! ATTENTION!!!!: ce fichier include est compatible format fixe/format libre | ||
94 | ! veillez n'utiliser que des ! pour les commentaires | ||
95 | ! et bien positionner les & des lignes de continuation | ||
96 | ! (les placer en colonne 6 et en colonne 73) | ||
97 | ! | ||
98 | ! | ||
99 | !----------------------------------------------------------------------- | ||
100 | ! INCLUDE 'paramet.h' | ||
101 | |||
102 | INTEGER iip1,iip2,iip3,jjp1,llmp1,llmp2,llmm1 | ||
103 | INTEGER kftd,ip1jm,ip1jmp1,ip1jmi1,ijp1llm | ||
104 | INTEGER ijmllm,mvar | ||
105 | INTEGER jcfil,jcfllm | ||
106 | |||
107 | PARAMETER( iip1= iim+1,iip2=iim+2,iip3=iim+3 & | ||
108 | & ,jjp1=jjm+1-1/jjm) | ||
109 | PARAMETER( llmp1 = llm+1, llmp2 = llm+2, llmm1 = llm-1 ) | ||
110 | PARAMETER( kftd = iim/2 -ndm ) | ||
111 | PARAMETER( ip1jm = iip1*jjm, ip1jmp1= iip1*jjp1 ) | ||
112 | PARAMETER( ip1jmi1= ip1jm - iip1 ) | ||
113 | PARAMETER( ijp1llm= ip1jmp1 * llm, ijmllm= ip1jm * llm ) | ||
114 | PARAMETER( mvar= ip1jmp1*( 2*llm+1) + ijmllm ) | ||
115 | PARAMETER( jcfil=jjm/2+5, jcfllm=jcfil*llm ) | ||
116 | |||
117 | !----------------------------------------------------------------------- | ||
118 | ! | ||
119 | ! $Header$ | ||
120 | ! | ||
121 | !CDK comgeom | ||
122 | COMMON/comgeom/ & | ||
123 | & cu(ip1jmp1),cv(ip1jm),unscu2(ip1jmp1),unscv2(ip1jm), & | ||
124 | & aire(ip1jmp1),airesurg(ip1jmp1),aireu(ip1jmp1), & | ||
125 | & airev(ip1jm),unsaire(ip1jmp1),apoln,apols, & | ||
126 | & unsairez(ip1jm),airuscv2(ip1jm),airvscu2(ip1jm), & | ||
127 | & aireij1(ip1jmp1),aireij2(ip1jmp1),aireij3(ip1jmp1), & | ||
128 | & aireij4(ip1jmp1),alpha1(ip1jmp1),alpha2(ip1jmp1), & | ||
129 | & alpha3(ip1jmp1),alpha4(ip1jmp1),alpha1p2(ip1jmp1), & | ||
130 | & alpha1p4(ip1jmp1),alpha2p3(ip1jmp1),alpha3p4(ip1jmp1), & | ||
131 | & fext(ip1jm),constang(ip1jmp1),rlatu(jjp1),rlatv(jjm), & | ||
132 | & rlonu(iip1),rlonv(iip1),cuvsurcv(ip1jm),cvsurcuv(ip1jm), & | ||
133 | & cvusurcu(ip1jmp1),cusurcvu(ip1jmp1),cuvscvgam1(ip1jm), & | ||
134 | & cuvscvgam2(ip1jm),cvuscugam1(ip1jmp1), & | ||
135 | & cvuscugam2(ip1jmp1),cvscuvgam(ip1jm),cuscvugam(ip1jmp1), & | ||
136 | & unsapolnga1,unsapolnga2,unsapolsga1,unsapolsga2, & | ||
137 | & unsair_gam1(ip1jmp1),unsair_gam2(ip1jmp1),unsairz_gam(ip1jm), & | ||
138 | & aivscu2gam(ip1jm),aiuscv2gam(ip1jm),xprimu(iip1),xprimv(iip1) | ||
139 | |||
140 | ! | ||
141 | REAL & | ||
142 | & cu,cv,unscu2,unscv2,aire,airesurg,aireu,airev,unsaire,apoln ,& | ||
143 | & apols,unsairez,airuscv2,airvscu2,aireij1,aireij2,aireij3,aireij4,& | ||
144 | & alpha1,alpha2,alpha3,alpha4,alpha1p2,alpha1p4,alpha2p3,alpha3p4 ,& | ||
145 | & fext,constang,rlatu,rlatv,rlonu,rlonv,cuvscvgam1,cuvscvgam2 ,& | ||
146 | & cvuscugam1,cvuscugam2,cvscuvgam,cuscvugam,unsapolnga1,unsapolnga2& | ||
147 | & ,unsapolsga1,unsapolsga2,unsair_gam1,unsair_gam2,unsairz_gam ,& | ||
148 | & aivscu2gam ,aiuscv2gam,cuvsurcv,cvsurcuv,cvusurcu,cusurcvu,xprimu& | ||
149 | & , xprimv | ||
150 | ! | ||
151 | |||
152 | REAL ps( ip1jmp1 ), psexbarxy ( ip1jm ), pext( ip1jmp1 ) | ||
153 | |||
154 | INTEGER l, ij | ||
155 | c | ||
156 | |||
157 |
2/2✓ Branch 0 taken 2881 times.
✓ Branch 1 taken 3137409 times.
|
3140290 | DO ij = 1, ip1jmp1 |
158 | 3140290 | pext(ij) = ps(ij) * aire(ij) | |
159 | ENDDO | ||
160 | |||
161 | |||
162 |
2/2✓ Branch 0 taken 3039455 times.
✓ Branch 1 taken 2881 times.
|
3042336 | DO 5 ij = 1, ip1jm - 1 |
163 | psexbarxy( ij ) = pext(ij)*alpha2(ij) + pext(ij+1)*alpha3(ij+1) + | ||
164 | 3039455 | * pext(ij+iip1)*alpha1(ij+iip1) + pext(ij+iip2)*alpha4(ij+iip2) | |
165 | 2881 | 5 CONTINUE | |
166 | |||
167 | |||
168 | c .... correction pour psexbarxy( iip1,j ) ........ | ||
169 | |||
170 | CDIR$ IVDEP | ||
171 | |||
172 | 92192 | DO 7 ij = iip1, ip1jm, iip1 | |
173 |
2/2✓ Branch 0 taken 89311 times.
✓ Branch 1 taken 2881 times.
|
92192 | psexbarxy( ij ) = psexbarxy( ij - iim ) |
174 | 2881 | 7 CONTINUE | |
175 | |||
176 | |||
177 | 2881 | RETURN | |
178 | END | ||
179 |