source: trunk/libf/phytitan/cpdet.F @ 4

Last change on this file since 4 was 3, checked in by slebonnois, 15 years ago

Creation de repertoires:

  • chantiers : pour communiquer sur nos projets de modifs
  • documentation : pour stocker les docs

Ajout de:

  • libf/phytitan : physique de Titan
  • libf/chimtitan: chimie de Titan
  • libf/phyvenus : physique de Venus
File size: 2.1 KB
Line 
1! ADAPTATION GCM POUR CP(T)
2c======================================================================
3c S. Lebonnois, 10/2007:
4c
5c TERRE: Cp(T) = cpp 
6c cpp=RCPD=cp0 = 1000.
7c R/RCPD = RKAPPA
8c
9c La fonction d'Exner reste pk = RCPD*(play/pref)**RKAPPA
10c
11c T et teta (temperature potentielle) sont liees par:
12c
13c   integrale[teta a T](cp/T dT) = integrale[pref a p](R/p dp)
14c
15c Dans le cas de la Terre, ca donne:
16c
17c   teta = T * (pref/p)**RKAPPA
18c ou
19c   teta = T * RCPD/pk
20c
21c On passe de T a teta par t2tpot(t,teta,pk)
22c On passe de teta a T par tpot2t(teta,t,pk)
23c
24c
25c======================================================================
26
27      FUNCTION cpdet(t)
28      IMPLICIT none
29#include "cpdet.h"
30
31      real cpdet,t
32
33      cpdet = cp0
34
35      return
36      end
37     
38c======================================================================
39c======================================================================
40
41      SUBROUTINE t2tpot(npoints, yt, yteta, ypk)
42      IMPLICIT none
43c======================================================================
44c Arguments:
45c
46c yt   --------input-R- Temperature
47c yteta-------output-R- Temperature potentielle
48c ypk  --------input-R- Fonction d'Exner: RCPD*(pplay/pref)**RKAPPA
49c
50c======================================================================
51#include "dimensions.h"
52#include "cpdet.h"
53
54      integer npoints
55      REAL yt(npoints), yteta(npoints), ypk(npoints)
56
57      yteta = yt * cp0/ypk
58     
59      return
60      end
61
62c======================================================================
63c======================================================================
64
65      SUBROUTINE tpot2t(npoints, yteta, yt, ypk)
66      IMPLICIT none
67c======================================================================
68c Arguments:
69c
70c yteta--------input-R- Temperature potentielle
71c yt   -------output-R- Temperature
72c ypk  --------input-R- Fonction d'Exner: RCPD*(pplay/pref)**RKAPPA
73c
74c======================================================================
75#include "dimensions.h"
76#include "cpdet.h"
77
78      integer npoints
79      REAL yt(npoints), yteta(npoints), ypk(npoints)
80
81      yt = yteta * ypk/cp0
82     
83      return
84      end
85
Note: See TracBrowser for help on using the repository browser.