source: trunk/LMDZ.MARS/libf/phymars/mzescape_normaliz.F @ 469

Last change on this file since 469 was 414, checked in by aslmd, 14 years ago

LMDZ.MARS : NEW NLTE MODEL FROM GRANADA AMIGOS

23/11/11 == FGG + MALV

New parameterization of the NLTE 15 micron cooling. The old parameterization is kept as an option, including or not variable atomic oxygen concentration. A new flag is introduced in callphys.def, nltemodel, to select which parameterization wants to be used (new one, old one with variable [O], or old one with fixed [O], see below). Includes many new subroutines and commons in phymars. Some existing routines are also modified:

-physiq.F. Call to the new subroutine NLTE_leedat in first call. Call to nltecool modified to allow for variable atomic oxygen. Depending on the value of nltemodel, the new subroutine NLTEdlvr09_TCOOL is called instead of nltecool.

-inifis.F. Reading of nltemodel is added.

-callkeys.h Declaration of nltemodel is added.

The following lines should be added to callphys.def (ideally after setting callnlte):

# NLTE 15um scheme to use.
# 0-> Old scheme, static oxygen
# 1-> Old scheme, dynamic oxygen
# 2-> New scheme
nltemodel = 2

A new directory, NLTEDAT, has to be included in datagcm.

Improvements into NLTE NIR heating parameterization to take into account variability with O/CO2 ratio and SZA. A new subroutine, NIR_leedat.F, and a new common, NIRdata.h, are included. A new flag, nircorr, is added in callphys.def, to include or not these corrections. The following files are modified:

-nirco2abs.F: nq and pq are added in the arguments. The corrections factors are interpolated to the GCM grid and included in the clculation. A new subroutine, interpnir, is added at the end of the file.

-physiq.F: Call to NIR_leedat added at first call. Modified call to nirco2abs

-inifis: Reading new flag nircorr.

-callkeys.h: Declaration of nircorr.

The following lines have to be added to callphys.def (ideally after callnirco2):

# NIR NLTE correction for variable SZA and O/CO2?
# matters only if callnirco2=T
# 0-> no correction
# 1-> include correction
nircorr=1

A new data file, NIRcorrection_feb2011.dat, has to be included in datagcm.

Small changes to the molecular diffusion scheme to fix the number of species considered, to avoid problems when compiling with more than 15 tracers (for example, when CH4 is included). Modified subroutines: aeronomars/moldiff.F and aeronomars/moldiffcoeff.F

File size: 3.7 KB
Line 
1c***********************************************************************
2c       mzescape_normaliz.f                           
3c***********************************************************************
4c                                               
5c       program  for correcting some strange values and for normalizing       
6c       the atmospheric escape functions computed by mzescape_15um.f   
7c       possibilities according to istyle (see mzescape_15um.f).       
8c                                               
9                                                           
10        subroutine mzescape_normaliz ( taustar, istyle )           
11                                                           
12                                                           
13c       dic 99          malv    first version   
14c       jul 2011 malv+fgg       Adapted to LMD-MGCM
15c***********************************************************************
16                                                           
17        implicit none                                 
18        include 'nltedefs.h'         
19                                                           
20                                                           
21c arguments                                     
22        real*8          taustar(nl)     ! o                   
23        integer         istyle          ! i           
24                                                           
25c local variables and constants                 
26        integer         i, imaximum                           
27        real*8          maximum                       
28                                                           
29c***********************************************************************
30                                                           
31!                                               
32! correcting strange values at top, eliminating local maxima, etc...   
33!                                               
34        taustar(nl) = taustar(nl-1)                   
35                                                           
36        if ( istyle .eq. 1 ) then                     
37          imaximum = nl                               
38          maximum = taustar(nl)                       
39          do i=1,nl-1                                 
40            if (taustar(i).gt.maximum) taustar(i) = taustar(nl)   
41          enddo                                       
42        elseif ( istyle .eq. 2 ) then                 
43          imaximum = nl                               
44          maximum = taustar(nl)                       
45          do i=nl-1,1,-1                               
46            if (taustar(i).gt.maximum) then           
47               maximum = taustar(i)                   
48               imaximum = i                           
49            endif                                     
50          enddo                                       
51          do i=imaximum,nl                             
52            if (taustar(i).lt.maximum) taustar(i) = maximum       
53          enddo                                       
54        endif                                         
55                                                           
56!                                               
57! normalizing                                   
58!                                               
59        do i=1,nl                                     
60          taustar(i) = taustar(i) / maximum           
61        enddo                                         
62                                                           
63                                                           
64c end                                           
65        return                                         
66        end                                           
67                                                           
68                                                           
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
Note: See TracBrowser for help on using the repository browser.