1 |
guez |
3 |
! |
2 |
|
|
! $Header: /home/cvsroot/LMDZ4/libf/dyn3d/massbar.F,v 1.1.1.1 2004/05/19 12:53:05 lmdzadmin Exp $ |
3 |
|
|
! |
4 |
|
|
SUBROUTINE massbar( masse, massebx, masseby ) |
5 |
|
|
c |
6 |
|
|
c ********************************************************************** |
7 |
|
|
c |
8 |
|
|
c Calcule les moyennes en x et y de la masse d'air dans chaque maille. |
9 |
|
|
c ********************************************************************** |
10 |
|
|
c Auteurs : P. Le Van , Fr. Hourdin . |
11 |
|
|
c .......... |
12 |
|
|
c |
13 |
|
|
c .. masse est un argum. d'entree pour le s-pg ... |
14 |
|
|
c .. massebx,masseby sont des argum. de sortie pour le s-pg ... |
15 |
|
|
c |
16 |
|
|
c |
17 |
|
|
c IMPLICIT NONE |
18 |
|
|
c |
19 |
|
|
use dimens_m |
20 |
|
|
use paramet_m |
21 |
|
|
use comconst |
22 |
|
|
use comgeom |
23 |
|
|
c |
24 |
|
|
REAL masse( ip1jmp1,llm ), massebx( ip1jmp1,llm ) , |
25 |
|
|
* masseby( ip1jm,llm ) |
26 |
|
|
c |
27 |
|
|
c |
28 |
|
|
c Methode pour calculer massebx et masseby . |
29 |
|
|
c ---------------------------------------- |
30 |
|
|
c |
31 |
|
|
c A chaque point scalaire P (i,j) est affecte 4 coefficients d'aires |
32 |
|
|
c alpha1(i,j) calcule au point ( i+1/4,j-1/4 ) |
33 |
|
|
c alpha2(i,j) calcule au point ( i+1/4,j+1/4 ) |
34 |
|
|
c alpha3(i,j) calcule au point ( i-1/4,j+1/4 ) |
35 |
|
|
c alpha4(i,j) calcule au point ( i-1/4,j-1/4 ) |
36 |
|
|
c |
37 |
|
|
c Avec alpha1(i,j) = aire(i+1/4,j-1/4)/ aire(i,j) |
38 |
|
|
c |
39 |
|
|
c N.B . Pour plus de details, voir s-pg ... iniconst ... |
40 |
|
|
c |
41 |
|
|
c |
42 |
|
|
c |
43 |
|
|
c alpha4 . . alpha1 . alpha4 |
44 |
|
|
c (i,j) (i,j) (i+1,j) |
45 |
|
|
c |
46 |
|
|
c P . U . . P |
47 |
|
|
c (i,j) (i,j) (i+1,j) |
48 |
|
|
c |
49 |
|
|
c alpha3 . . alpha2 .alpha3 |
50 |
|
|
c (i,j) (i,j) (i+1,j) |
51 |
|
|
c |
52 |
|
|
c V . Z . . V |
53 |
|
|
c (i,j) |
54 |
|
|
c |
55 |
|
|
c alpha4 . . alpha1 .alpha4 |
56 |
|
|
c (i,j+1) (i,j+1) (i+1,j+1) |
57 |
|
|
c |
58 |
|
|
c P . U . . P |
59 |
|
|
c (i,j+1) (i+1,j+1) |
60 |
|
|
c |
61 |
|
|
c |
62 |
|
|
c |
63 |
|
|
c On a : |
64 |
|
|
c |
65 |
|
|
c massebx(i,j) = masse(i ,j) * ( alpha1(i ,j) + alpha2(i,j)) + |
66 |
|
|
c masse(i+1,j) * ( alpha3(i+1,j) + alpha4(i+1,j) ) |
67 |
|
|
c localise au point ... U (i,j) ... |
68 |
|
|
c |
69 |
|
|
c masseby(i,j) = masse(i,j ) * ( alpha2(i,j ) + alpha3(i,j ) + |
70 |
|
|
c masse(i,j+1) * ( alpha1(i,j+1) + alpha4(i,j+1) |
71 |
|
|
c localise au point ... V (i,j) ... |
72 |
|
|
c |
73 |
|
|
c |
74 |
|
|
c======================================================================= |
75 |
|
|
|
76 |
|
|
DO 100 l = 1 , llm |
77 |
|
|
c |
78 |
|
|
DO ij = 1, ip1jmp1 - 1 |
79 |
|
|
massebx(ij,l) = masse( ij, l) * alpha1p2( ij ) + |
80 |
|
|
* masse(ij+1, l) * alpha3p4(ij+1 ) |
81 |
|
|
ENDDO |
82 |
|
|
|
83 |
|
|
c .... correction pour massebx( iip1,j) ..... |
84 |
|
|
c ... massebx(iip1,j)= massebx(1,j) ... |
85 |
|
|
c |
86 |
|
|
CDIR$ IVDEP |
87 |
|
|
DO ij = iip1, ip1jmp1, iip1 |
88 |
|
|
massebx( ij,l ) = massebx( ij - iim,l ) |
89 |
|
|
ENDDO |
90 |
|
|
|
91 |
|
|
|
92 |
|
|
DO ij = 1,ip1jm |
93 |
|
|
masseby( ij,l ) = masse( ij , l ) * alpha2p3( ij ) + |
94 |
|
|
* masse(ij+iip1, l ) * alpha1p4( ij+iip1 ) |
95 |
|
|
ENDDO |
96 |
|
|
|
97 |
|
|
100 CONTINUE |
98 |
|
|
c |
99 |
|
|
RETURN |
100 |
|
|
END |