IBM XL Fortran for AIX, V12.1 (5724-U82) Version 12.01.0000.0001 --- ../core/elevadjust.F 03/09/11 11:03:50 >>>>> OPTIONS SECTION <<<<< *** Options In Effect *** == On / Off Options == CR DBG ESCAPE FULLPATH I4 INLGLUE NOLIBESSL NOLIBPOSIX OBJECT SOURCE STRICT SWAPOMP THREADED UNWIND ZEROSIZE == Options Of Integer Type == ALIAS_SIZE(65536) MAXMEM(-1) OPTIMIZE(2) SPILLSIZE(2000) STACKTEMP(0) == Options Of Character Type == 64(LARGETYPE) ALIAS(STD,NOINTPTR) ALIGN(BINDC(POWER),STRUCT(NATURAL)) ARCH(PWR6) ATTR(FULL) AUTODBL(NONE) DESCRIPTOR(V1) DIRECTIVE(IBM*,IBMT) ENUM() FLAG(I,I) FLOAT(RNDSNGL,MAF,FOLD,RNGCHK,SINGLE) FREE(F90) HALT(S) IEEE(NEAR) INTSIZE(4) LANGLVL(EXTENDED) REALSIZE(4) NOSAVE() TUNE(PWR6) UNROLL(AUTO) XREF(FULL) XLF2003(NOPOLYMORPHIC,NOBOZLITARGS,NOSTOPEXCEPT,NOVOLATILE,NOAUTOREALLOC,OLDNANINF) XLF77(LEADZERO,BLANKPAD) XLF90(NOSIGNEDZERO,NOAUTODEALLOC,OLDPAD) >>>>> SOURCE SECTION <<<<< 1 |#line 1 "../core/elevadjust.F" 1 |!------------------------------------------------------------------------- 2 |! NASA Goddard Space Flight Center Land Information System (LIS) V3.0 3 |! Released May 2004 4 |! 5 |! See SOFTWARE DISTRIBUTION POLICY for software distribution policies 6 |! 7 |! The LIS source code and documentation are in the public domain, 8 |! available without fee for educational, research, non-commercial and 9 |! commercial purposes. Users may distribute the binary or source 10 |! code to third parties provided this statement appears on all copies and 11 |! that no charge is made for such copies. 12 |! 13 |! NASA GSFC MAKES NO REPRESENTATIONS ABOUT THE SUITABILITY OF THE 14 |! SOFTWARE FOR ANY PURPOSE. IT IS PROVIDED AS IS WITHOUT EXPRESS OR 15 |! IMPLIED WARRANTY. NEITHER NASA GSFC NOR THE US GOVERNMENT SHALL BE 16 |! LIABLE FOR ANY DAMAGES SUFFERED BY THE USER OF THIS SOFTWARE. 17 |! 18 |! See COPYRIGHT.TXT for copyright details. 19 |! 20 |!------------------------------------------------------------------------- 21 |!BOP 22 |! !ROUTINE: elevadjust.F90 23 |! 24 |! !DESCRIPTION: 25 |! Corrects Temperature, Pressure, Humidity and Longwave Radiation 26 |! values for differences in elevation between EDAS and LDAS grids. 27 |! 28 |! !REVISION HISTORY: 29 |! 11 Apr 2000: Brian Cosgrove; Initial Code 30 |! 12 May 2000: Brian Cosgrove; Corrected for zero humidities 31 |! 09 Aug 2000: Brian Cosgrove; Corrected program so that 32 |! it only performs calculations if both 33 |! the elevation difference file and the forcing 34 |! data file (use temperature data as check for all 35 |! fields) contain defined values 36 |! 25 Jan 2001: Matt Rodell; Compute number of input and output 37 |! grid points, use to allocate local arrays 38 |! 27 Feb 2001: Brian Cosgrove; Added statement to check for use of 39 |! catchment data so that correct elevation correction 40 |! files is used 41 |! 15 Mar 2001: Jon Gottschalck; if-then to handle negative vapor 42 |! pressures in long wave correction 43 |! 15 Mar 2001: Matt Rodell; merge NLDAS and GLDAS versions 44 |! 14 Nov 2003: Sujay Kumar; Adopted in LIS 45 |! 46 |! !INTERFACE: 47 |subroutine elevadjust(t,f,fforce,force_tmp,force_hum,force_lwd, & 48 | force_prs) 49 | ! !USES: 50 | use lisdrv_module, only: tile 51 | implicit none 52 | !INPUT PARAMETERS: 53 | integer, intent(in) :: f, t 54 | !OUTPUT PARAMETERS: 55 | real, intent(inout) :: fforce,force_tmp,force_hum,& 56 | force_lwd,force_prs 57 | !EOP 58 | 59 | integer, parameter :: bb=2016 60 | integer err !iostat error code 61 | 62 | real :: mee,mfe,ee,fe 63 | real :: lapse, grav, rdry, ratio 64 | real :: esat,qsat,rh,fesat,fqsat,femiss,emiss 65 | real :: tcforce,pcforce,hcforce,lcforce,tbar 66 | !BOC 67 | grav = 9.81 68 | rdry = 287. 69 | lapse = -0.0065 70 | tcforce=force_tmp+(lapse*tile(t)%elev) 71 | tbar=(force_tmp+tcforce)/2. 72 | pcforce=force_prs/(exp((grav*tile(t)%elev)/(rdry*tbar))) 73 | if (force_hum .eq. 0) force_hum=1e-08 74 | ee=(force_hum*force_prs)/0.622 75 | esat=611.2*(exp((17.67*(force_tmp-273.15))/& 76 | ((force_tmp-273.15)+243.5))) 77 | qsat=(0.622*esat)/(force_prs-(0.378*esat)) 78 | rh=(force_hum/qsat)*100. 79 | fesat=611.2*(exp((17.67*(tcforce-273.15))/ & 80 | ((tcforce-273.15)+243.5))) 81 | fqsat=(0.622*fesat)/(pcforce-(0.378*fesat)) 82 | hcforce=(rh*fqsat)/100. 83 | fe=(hcforce*pcforce)/0.622 84 | mee=ee/100. 85 | mfe=fe/100. 86 | !---------------------------------------------------------------------- 87 | ! correct for negative vapor pressure at very low temperatures at 88 | ! high latitudes 89 | !---------------------------------------------------------------------- 90 | if (mee .le. 0) mee = 1e-08 91 | if (mfe .le. 0) mfe = 1e-08 92 | emiss =1.08*(1-exp(-mee**(force_tmp/bb))) 93 | femiss =1.08*(1-exp(-mfe**(tcforce/bb))) 94 | ratio=(femiss*(tcforce**4))/(emiss*(force_tmp**4)) 95 | lcforce=force_lwd*ratio 96 | 97 | select case (f) 98 | case(1) 99 | fforce=tcforce 100 | case(2) 101 | fforce=hcforce 102 | case(4) 103 | fforce=lcforce 104 | case(7) 105 | fforce=pcforce 106 | case default 107 | print*, "not a valid forcing type for elevation adjustment" 108 | call endrun 109 | end select 110 | return 111 | !EOC 112 |end subroutine elevadjust >>>>> ATTRIBUTE AND CROSS REFERENCE SECTION <<<<< IDENTIFIER NAME CROSS REFERENCE AND ATTRIBUTES bb Parameter, Integer(4) 0-59.25$ 0-92.40 0-93.38 col Use associated, Integer(4), Component of Derived type definition: tiledec, Offset: 0, Alignment: full word 0-50.7$ ee Automatic, Real(4), Offset: 0, Alignment: full word 0-62.19$ 0-74.3@ 0-84.7 elev Use associated, Real(4), Component of Derived type definition: tiledec, Offset: 20, Alignment: full word 0-50.7$ elevadjust Subroutine 0-47.12$ emiss Automatic, Real(4), Offset: 0, Alignment: full word 0-64.43$ 0-92.3@ 0-94.32 endrun External Subroutine 0-108.11 err Automatic, Integer(4), Offset: 0, Alignment: full word 0-60.11$ esat Automatic, Real(4), Offset: 0, Alignment: full word 0-64.11$ 0-75.3@ 0-77.15 0-77.39 exp Pure Intrinsic 0-72.22 0-75.15 0-79.16 0-92.19 0-93.19 f Reference argument, Intent (IN), Integer(4), Offset: 0, Alignment: full word 0-53.26$ 0-47.25 0-97.16 fe Automatic, Real(4), Offset: 0, Alignment: full word 0-62.22$ 0-83.3@ 0-85.7 femiss Automatic, Real(4), Offset: 0, Alignment: full word 0-64.36$ 0-93.3@ 0-94.10 fesat Automatic, Real(4), Offset: 0, Alignment: full word 0-64.24$ 0-79.3@ 0-81.16 0-81.39 fforce Reference argument, Intent (INOUT), Real(4), Offset: 0, Alignment: full word 0-55.26$ 0-47.27 0-99.6@ 0-101.6@ 0-103.6@ 0-105.6@ fgrd Use associated, Real(4), Component of Derived type definition: tiledec, Offset: 16, Alignment: full word 0-50.7$ force_hum Reference argument, Intent (INOUT), Real(4), Offset: 0, Alignment: full word 0-55.43$ 0-47.44 0-73.7 0-73.25@ 0-74.7 0-78.7 force_lwd Reference argument, Intent (INOUT), Real(4), Offset: 0, Alignment: full word 0-56.8$ 0-47.54 0-95.11 force_prs Reference argument, Intent (INOUT), Real(4), Offset: 0, Alignment: full word 0-56.18$ 0-48.6 0-72.11 0-74.17 0-77.22 force_tmp Reference argument, Intent (INOUT), Real(4), Offset: 0, Alignment: full word 0-55.33$ 0-47.34 0-70.11 0-71.9 0-75.27 0-76.10 0-92.30 0-94.39 fqsat Automatic, Real(4), Offset: 0, Alignment: full word 0-64.30$ 0-81.3@ 0-82.15 grav Automatic, Real(4), Offset: 0, Alignment: full word 0-63.18$ 0-67.3@ 0-72.27 hcforce Automatic, Real(4), Offset: 0, Alignment: full word 0-65.27$ 0-82.3@ 0-83.7 0-101.13 index Use associated, Integer(4), Component of Derived type definition: tiledec, Offset: 8, Alignment: full word 0-50.7$ lapse Automatic, Real(4), Offset: 0, Alignment: full word 0-63.11$ 0-69.3@ 0-70.22 lcforce Automatic, Real(4), Offset: 0, Alignment: full word 0-65.35$ 0-95.3@ 0-103.13 lisdrv_module Use associated, Nonintrinsic Module 0-50.7$ 0-50.7 mee Automatic, Real(4), Offset: 0, Alignment: full word 0-62.11$ 0-84.3@ 0-90.7 0-90.19@ 0-92.24 mfe Automatic, Real(4), Offset: 0, Alignment: full word 0-62.15$ 0-85.3@ 0-91.7 0-91.19@ 0-93.24 pcforce Automatic, Real(4), Offset: 0, Alignment: full word 0-65.19$ 0-72.3@ 0-81.24 0-83.15 0-105.13 qsat Automatic, Real(4), Offset: 0, Alignment: full word 0-64.16$ 0-77.3@ 0-78.17 ratio Automatic, Real(4), Offset: 0, Alignment: full word 0-63.30$ 0-94.3@ 0-95.21 rdry Automatic, Real(4), Offset: 0, Alignment: full word 0-63.24$ 0-68.3@ 0-72.47 rh Automatic, Real(4), Offset: 0, Alignment: full word 0-64.21$ 0-78.3@ 0-82.12 row Use associated, Integer(4), Component of Derived type definition: tiledec, Offset: 4, Alignment: full word 0-50.7$ t Reference argument, Intent (IN), Integer(4), Offset: 0, Alignment: full word 0-53.29$ 0-47.23 0-70.33 0-72.37 tbar Automatic, Real(4), Offset: 0, Alignment: full word 0-65.43$ 0-71.3@ 0-72.52 tcforce Automatic, Real(4), Offset: 0, Alignment: full word 0-65.11$ 0-70.3@ 0-71.19 0-79.28 0-80.10 0-93.30 0-94.18 0-99.13 tile Pointer, Use associated, Static, Derived type: tiledec (:), Offset: 216, Alignment: double word 0-50.28$ tile%elev Use associated, Real(4), Offset: 20, Alignment: full word 0-70.28 0-72.32 tile_module Use associated, Nonintrinsic Module 0-50.7$ tile_spmdmod Use associated, Nonintrinsic Module 0-50.7$ vegt Use associated, Integer(4), Component of Derived type definition: tiledec, Offset: 12, Alignment: full word 0-50.7$ ** elevadjust === End of Compilation 1 === >>>>> FILE TABLE SECTION <<<<< FILE CREATION FROM FILE NO FILENAME DATE TIME FILE LINE 0 ../core/elevadjust.F 03/09/11 11:03:50 >>>>> COMPILATION EPILOGUE SECTION <<<<< FORTRAN Summary of Diagnosed Conditions TOTAL UNRECOVERABLE SEVERE ERROR WARNING INFORMATIONAL (U) (S) (E) (W) (I) 0 0 0 0 0 0 Source records read....................................... 113 1501-510 Compilation successful for file elevadjust.F. 1501-543 Object file created.