Last change
on this file since 3436 was
3175,
checked in by emillour, 11 months ago
|
Pluto PCM:
Add the old Pluto LMDZ for reference (required prior step to making
an LMDZ.PLUTO using the same framework as the other physics packages).
TB+EM
|
File size:
1.2 KB
|
Line | |
---|
1 | subroutine globalaverage2d(ngrid,var,globaverage2d) |
---|
2 | |
---|
3 | use comgeomfi_h |
---|
4 | implicit none |
---|
5 | |
---|
6 | !================================================================== |
---|
7 | ! Purpose |
---|
8 | ! ------- |
---|
9 | ! |
---|
10 | ! Inputs |
---|
11 | ! ------ |
---|
12 | ! ngrid Number of vertical columns |
---|
13 | ! |
---|
14 | ! Authors |
---|
15 | ! ------- |
---|
16 | ! Tanguy Bertrand 2015 |
---|
17 | ! |
---|
18 | !================================================================== |
---|
19 | |
---|
20 | #include "dimensions.h" |
---|
21 | #include "dimphys.h" |
---|
22 | #include "comcstfi.h" |
---|
23 | #include "surfdat.h" |
---|
24 | !#include "comsaison.h" |
---|
25 | #include "comvert.h" |
---|
26 | #include "callkeys.h" |
---|
27 | #include "tracer.h" |
---|
28 | |
---|
29 | !----------------------------------------------------------------------- |
---|
30 | ! Arguments |
---|
31 | INTEGER ngrid |
---|
32 | REAL var(ngrid) |
---|
33 | |
---|
34 | ! LOCAL VARIABLES |
---|
35 | INTEGER ig |
---|
36 | |
---|
37 | ! OUTPUT |
---|
38 | REAL globaverage2d |
---|
39 | !----------------------------------------------------------------------- |
---|
40 | |
---|
41 | globaverage2d = 0.d0 |
---|
42 | DO ig=2,ngrid-1 |
---|
43 | globaverage2d = globaverage2d + var(ig)*area(ig) |
---|
44 | END DO |
---|
45 | globaverage2d = globaverage2d + var(1)*area(1)*iim |
---|
46 | globaverage2d = globaverage2d + var(ngrid)*area(ngrid)*iim |
---|
47 | globaverage2d = globaverage2d/(totarea+(area(1)+area(ngrid))*(iim-1)) |
---|
48 | |
---|
49 | end subroutine globalaverage2d |
---|
50 | |
---|
Note: See
TracBrowser
for help on using the repository browser.