| 1 |
subroutine do_plumes(uplume,vplume,thplume, |
| 2 |
. idim,jdim,Nr,Nsx,Nsy,bi,bj,nxperdyn,nyperdyn, |
| 3 |
. duplume,dvplume,dthplume) |
| 4 |
c----------------------------------------------------------------------- |
| 5 |
c Dummy routine to calculate plumes increments - here set them to whatever |
| 6 |
c |
| 7 |
c----------------------------------------------------------------------- |
| 8 |
implicit none |
| 9 |
#include "CPP_OPTIONS.h" |
| 10 |
|
| 11 |
integer idim,jdim,Nr,Nsx,Nsy,bi,bj,nxperdyn,nyperdyn |
| 12 |
_RL uplume(idim,jdim,Nr,Nsx,Nsy) |
| 13 |
_RL vplume(idim,jdim,Nr,Nsx,Nsy) |
| 14 |
_RL thplume(idim,jdim,Nr,Nsx,Nsy) |
| 15 |
_RL splume(idim,jdim,Nr,Nsx,Nsy) |
| 16 |
_RL duplume(idim,jdim,Nr,Nsx,Nsy) |
| 17 |
_RL dvplume(idim,jdim,Nr,Nsx,Nsy) |
| 18 |
_RL dthplume(idim,jdim,Nr,Nsx,Nsy) |
| 19 |
_RL dsplume(idim,jdim,Nr,Nsx,Nsy) |
| 20 |
c |
| 21 |
_RL upergrid(nxperdyn,nyperdyn,nr) |
| 22 |
_RL vpergrid(nxperdyn,nyperdyn,nr) |
| 23 |
_RL tpergrid(nxperdyn,nyperdyn,nr) |
| 24 |
_RL spergrid(nxperdyn,nyperdyn,nr) |
| 25 |
_RL dupergrid(nxperdyn,nyperdyn,nr) |
| 26 |
_RL dvpergrid(nxperdyn,nyperdyn,nr) |
| 27 |
_RL dtpergrid(nxperdyn,nyperdyn,nr) |
| 28 |
_RL dspergrid(nxperdyn,nyperdyn,nr) |
| 29 |
integer i,j,L,ig,jg,iindex,jindex,nxgrids,nygrids |
| 30 |
|
| 31 |
nxgrids = idim/nxperdyn |
| 32 |
nygrids = jdim/nyperdyn |
| 33 |
|
| 34 |
c Large do-loop, do a plume model at each grid point |
| 35 |
do jg = 1,nygrids |
| 36 |
do ig = 1,nxgrids |
| 37 |
|
| 38 |
c Extract per grid point info from large arrays |
| 39 |
do L = 1,Nr |
| 40 |
do j = 1,nyperdyn |
| 41 |
do i = 1,nxperdyn |
| 42 |
iindex = (i-1)*nxgrids + i |
| 43 |
jindex = (j-1)*nygrids + j |
| 44 |
upergrid(i,j,L) = uplume(iindex,jindex,L,bi,bj) |
| 45 |
vpergrid(i,j,L) = vplume(iindex,jindex,L,bi,bj) |
| 46 |
tpergrid(i,j,L) = thplume(iindex,jindex,L,bi,bj) |
| 47 |
spergrid(i,j,L) = splume(iindex,jindex,L,bi,bj) |
| 48 |
enddo |
| 49 |
enddo |
| 50 |
enddo |
| 51 |
|
| 52 |
c Now call plume model to get tendencies |
| 53 |
call plume( ) |
| 54 |
|
| 55 |
c Put tendencies into large arrays |
| 56 |
do L = 1,Nr |
| 57 |
do j = 1,nyperdyn |
| 58 |
do i = 1,nxperdyn |
| 59 |
iindex = (i-1)*nxgrids + i |
| 60 |
jindex = (j-1)*nygrids + j |
| 61 |
duplume(iindex,jindex,L,bi,bj) = dupergrid(i,j,L) |
| 62 |
dvplume(iindex,jindex,L,bi,bj) = dvpergrid(i,j,L) |
| 63 |
dthplume(iindex,jindex,L,bi,bj) = dtpergrid(i,j,L) |
| 64 |
dsplume(iindex,jindex,L,bi,bj) = dspergrid(i,j,L) |
| 65 |
enddo |
| 66 |
enddo |
| 67 |
enddo |
| 68 |
|
| 69 |
return |
| 70 |
end |