我感兴趣的是根据过去的探测结果计算海角。我做了一些测试计算,由于某些原因,我的CAPE值与当前测深提供的值不一致
例如,见latest sounding from Boa Vista, Brazil(随机挑选的b/c,温度足以在一月份形成明显的海角)。数据显示CAPE为189 J/kg,而metpy给出的数值要低得多。具体地说,如果我使用探测中所有压力水平的所有数据,我得到72 J/kg。相反,如果我只使用标准压力水平(1000、925等——如下代码所示),我得到1 J/kg
我复制了下面的代码。有人能帮我找出正确的方法吗
谢谢, 纪尧姆
# IMPORT:
import metpy.calc as mpcalc
from metpy.units import units
import numpy as np
# SOUNDING:
p=np.array([1003,925,850,700,500,400,300,200,100])
t=np.array([24.4,20.6,16.4,10.4,-5.3,-15.5,-28.7,-52.3,-79.7])
d=np.array([21.1,20.2,16.3,6.5,-7.0,-25.5,-51.7,-73.3,-87.7])
# UNITS:
p = units.Quantity(p, "hPa")
t = units.Quantity(t, "degC")
d = units.Quantity(d, "degC")
# CALCULATE CAPE:
cape1,cin1 = mpcalc.surface_based_cape_cin(p,t,d)
prof = mpcalc.parcel_profile(p, t[0], d[0])
cape2,cin2 = mpcalc.cape_cin(p,t,d,prof)
print(cape1)
print(cape2)
怀俄明州档案中的计算值使用lowest 500m的平均值来表示用于计算的地块。不幸的是,这并非微不足道,但可以通过MetPy实现:
混合到位后,我得到的LCL压力/温度值(943.84 hPa和20.52 degC)与怀俄明州一致。这使我的CAPE为208 J/kg,CIN为-16 J/kg,这与怀俄明州报告的结果更为一致。任何差异,特别是对于这种轻微不稳定的测深,都可能是由于计算细节的差异造成的,就像原始差异是使用浅层混合地块造成的一样
这应该可以通过
metpy.calc.mixed_layer_cape_cin
实现,但由于a bug的原因,目前不适用于非基于压力的深度相关问题 更多 >
编程相关推荐