Last change
on this file since 3493 was
1422,
checked in by milmd, 10 years ago
|
In GENERIC, MARS and COMMON models replace some include files by modules (usefull for decoupling physics with dynamics).
|
File size:
1.2 KB
|
Line | |
---|
1 | ! |
---|
2 | ! $Id: adaptdt.F 1403 2010-07-01 09:02:53Z fairhead $ |
---|
3 | ! |
---|
4 | subroutine adaptdt(nadv,dtbon,n,pbaru, |
---|
5 | c masse) |
---|
6 | |
---|
7 | USE control_mod |
---|
8 | USE comconst_mod, ONLY: dtvr |
---|
9 | IMPLICIT NONE |
---|
10 | |
---|
11 | #include "dimensions.h" |
---|
12 | c#include "paramr2.h" |
---|
13 | #include "paramet.h" |
---|
14 | #include "comdissip.h" |
---|
15 | #include "comgeom2.h" |
---|
16 | |
---|
17 | c---------------------------------------------------------- |
---|
18 | c Arguments |
---|
19 | c---------------------------------------------------------- |
---|
20 | INTEGER n,nadv |
---|
21 | REAL dtbon |
---|
22 | REAL pbaru(iip1,jjp1,llm) |
---|
23 | REAL masse(iip1,jjp1,llm) |
---|
24 | c---------------------------------------------------------- |
---|
25 | c Local |
---|
26 | c---------------------------------------------------------- |
---|
27 | INTEGER i,j,l |
---|
28 | REAL CFLmax,aaa,bbb |
---|
29 | |
---|
30 | CFLmax=0. |
---|
31 | do l=1,llm |
---|
32 | do j=2,jjm |
---|
33 | do i=1,iim |
---|
34 | aaa=pbaru(i,j,l)*dtvr/masse(i,j,l) |
---|
35 | CFLmax=max(CFLmax,aaa) |
---|
36 | bbb=-pbaru(i,j,l)*dtvr/masse(i+1,j,l) |
---|
37 | CFLmax=max(CFLmax,bbb) |
---|
38 | enddo |
---|
39 | enddo |
---|
40 | enddo |
---|
41 | n=int(CFLmax)+1 |
---|
42 | c pour reproduire cas VL du code qui appele x,y,z,y,x |
---|
43 | c if (nadv.eq.30) n=n/2 ! Pour Prather |
---|
44 | dtbon=dtvr/n |
---|
45 | |
---|
46 | return |
---|
47 | end |
---|
48 | |
---|
49 | |
---|
50 | |
---|
51 | |
---|
52 | |
---|
53 | |
---|
54 | |
---|
Note: See
TracBrowser
for help on using the repository browser.