Hello,
I am testing NCL functions (wrf_cape_2d, wrf_cape_3d; wrf_user_getvar) for the CAPE calculation. What I did is to take a WRF output file provided by NCL website and use these functions to calculate the most unstable CAPE (wrf_cape_2d or wrf_user_getvar) and surface based CAPE (wrf_cape_3d or wrf_user_getvar). It came to my attention that the value of most unstable CAPE is smaller than surface-based CAPE (see my attached figures). Also surprising is that the value of most unstable CAPE using wrf_cape_2d function is a little larger than the most unstable cape using wrf_user_getvar(a,"cape_2d"). [By contrast, the CAPE calculated by wrf_cape_3d is identical to the CAPE calculated by wrf_user_getva(a,"cape_3d")]. I wonder if any one can help share some insight why this happens. In particular, shouldn't we expect the most unstable CAPE to be equal or larger than surface-based CAPE?
Note that I also tested this using WRF_Python package and found that wrf.cape_2d (identical to NCL wrf_cape_2d) is also smaller than wrf.cape_3d surface-layer value ( identical to NCL wrf_cape_3d). Thus, I suspect that this might be a common issue for both NCL and Python.
Any comments and/or suggestions will be appreciated!
--
Lantao sun
Research Scientist
Department of Atmospheric Science
Colorado State University
Fort Collins, Colorado, USA
Lantao.Sun@colostate.edu
P.S.: Some details below regarding how I did the test:
1. Most unstable CAPE based on wrf_cape_2d: I simply follow the code for example 1 at NCL website:
begin
a = addfile("wrfout_d01_2005-08-28_00:00:00","r")
T = a->T
P = a->P
PB = a->PB
QV = a->QVAPOR
PH = a->PH
PHB = a->PHB
HGT = a->HGT
PSFC = a->PSFC
T = T + 300.
P = P + PB
tk = wrf_tk( P , T )
PH = PH + PHB
z = wrf_user_unstagger(PH,PH@stagger)
z = z/9.81
cinfo = wrf_cape_2d( P, tk, QV, z, HGT, PSFC, True )
mcape = cinfo(0,:,
; ....................plot scripts follow ....................
end
2. Most unstable CAPE based on wrf_user_getvar: I follow the code for example 2 at NCL website:
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"
load "$NCARG_ROOT/lib/ncarg/nclscripts/wrf/WRFUserARW.ncl"
a = addfile("wrfout_d01_2005-08-28_00:00:00","r")
cape2d = wrf_user_getvar(a,"cape_2d",-1)
mcape = cape2d(0,:,
3. Surface-based CAPE based on wrf_cape_3d: similar to 1, but change wrf_cape_2d to wrf_cape_3d, and only keep the bottom layer for surface-based CAPE.
4. Surface-based CAPE based on wrf_user_getvar: similar to 2, but use "wrf_user_getvar("cape3d",-1)" and only keep the bottom layer for surface-based CAPE.
I am testing NCL functions (wrf_cape_2d, wrf_cape_3d; wrf_user_getvar) for the CAPE calculation. What I did is to take a WRF output file provided by NCL website and use these functions to calculate the most unstable CAPE (wrf_cape_2d or wrf_user_getvar) and surface based CAPE (wrf_cape_3d or wrf_user_getvar). It came to my attention that the value of most unstable CAPE is smaller than surface-based CAPE (see my attached figures). Also surprising is that the value of most unstable CAPE using wrf_cape_2d function is a little larger than the most unstable cape using wrf_user_getvar(a,"cape_2d"). [By contrast, the CAPE calculated by wrf_cape_3d is identical to the CAPE calculated by wrf_user_getva(a,"cape_3d")]. I wonder if any one can help share some insight why this happens. In particular, shouldn't we expect the most unstable CAPE to be equal or larger than surface-based CAPE?
Note that I also tested this using WRF_Python package and found that wrf.cape_2d (identical to NCL wrf_cape_2d) is also smaller than wrf.cape_3d surface-layer value ( identical to NCL wrf_cape_3d). Thus, I suspect that this might be a common issue for both NCL and Python.
Any comments and/or suggestions will be appreciated!
--
Lantao sun
Research Scientist
Department of Atmospheric Science
Colorado State University
Fort Collins, Colorado, USA
Lantao.Sun@colostate.edu
P.S.: Some details below regarding how I did the test:
1. Most unstable CAPE based on wrf_cape_2d: I simply follow the code for example 1 at NCL website:
begin
a = addfile("wrfout_d01_2005-08-28_00:00:00","r")
T = a->T
P = a->P
PB = a->PB
QV = a->QVAPOR
PH = a->PH
PHB = a->PHB
HGT = a->HGT
PSFC = a->PSFC
T = T + 300.
P = P + PB
tk = wrf_tk( P , T )
PH = PH + PHB
z = wrf_user_unstagger(PH,PH@stagger)
z = z/9.81
cinfo = wrf_cape_2d( P, tk, QV, z, HGT, PSFC, True )
mcape = cinfo(0,:,
; ....................plot scripts follow ....................
end
2. Most unstable CAPE based on wrf_user_getvar: I follow the code for example 2 at NCL website:
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"
load "$NCARG_ROOT/lib/ncarg/nclscripts/wrf/WRFUserARW.ncl"
a = addfile("wrfout_d01_2005-08-28_00:00:00","r")
cape2d = wrf_user_getvar(a,"cape_2d",-1)
mcape = cape2d(0,:,
3. Surface-based CAPE based on wrf_cape_3d: similar to 1, but change wrf_cape_2d to wrf_cape_3d, and only keep the bottom layer for surface-based CAPE.
4. Surface-based CAPE based on wrf_user_getvar: similar to 2, but use "wrf_user_getvar("cape3d",-1)" and only keep the bottom layer for surface-based CAPE.