source:
LMDZ.3.3/tags/version0/libf/dyn3d/moy2.F
@
285
Last change on this file since 285 was 2, checked in by , 25 years ago | |
---|---|
|
|
File size: 546 bytes |
Line | |
---|---|
1 | SUBROUTINE moy2(np,px,py,pwx,pwy,pz) |
2 | |
3 | c======================================================================= |
4 | c |
5 | c calcul de la moyenne ponderee de deux champs |
6 | c z (i) = [ wx*x(i) + wy*y(i) ] / [ wx + wy ] |
7 | c |
8 | c======================================================================= |
9 | |
10 | IMPLICIT NONE |
11 | INTEGER np |
12 | REAL px(np),py(np),pz(np) |
13 | REAL pwx,pwy |
14 | |
15 | REAL zwx,zwy |
16 | INTEGER i |
17 | |
18 | zwx=pwx/(pwx+pwy) |
19 | zwy=pwy/(pwx+pwy) |
20 | |
21 | DO i=1,np |
22 | pz(i)=px(i)*zwx+py(i)*zwy |
23 | ENDDO |
24 | |
25 | RETURN |
26 | END |
Note: See TracBrowser
for help on using the repository browser.