有人知道如何用NCL在WRF中计算垂直积分水分通量吗?这将是最好的,如果你能共享一个NCL脚本。这是我的代码,我用这个代码来计算一个月的平均水分通量。但我混淆了最后输出的单位。另一个问题是,我不确定是否需要将输出除以9.8?
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;dir1 = " /用户/ gerry /桌面/ WRF_EXTPCP / wrftest / FILES1 = systemfunc(“ls”+ dir1 + wrfout_d01_ *) a1 = addfile (FILES1 +“.nc”,”r ") ;------- 计算总层水汽通量 -------------------------- psfc = wrf_user_getvar (a1,“psfc”,1)* 0.01;表面压力,转到hPa (;WRF中PSFC的单位为Pa) pres = wrf_user_getvar(a1,“压力”,-1);气压hPa(时间,高度,纬度,时间)temp = wrf_user_getvar(a1,"tk",-1);K rh = wrf_user_getvar(a1,"rh",-1);% ua = wrf_user_getvar(a1,"ua",-1);M s-1 va = wrf_user_getvar(a1,"va",-1);M s-1;printVarSummary (psfc); (time,lat,lon) ; printVarSummary(pres) ; (time,level,lat,lon) ; printVarSummary(temp) ; (time,level,lat,lon) ; printVarSummary(rh) ; (time,level,lat,lon) ; printVarSummary(ua) ; (time,level,lat,lon) ; printVarSummary(va) ; (time,level,lat,lon) psfc1 = dim_avg_n_Wrap(psfc,0) pres1 = dim_avg_n_Wrap(pres,0) temp1 = dim_avg_n_Wrap(temp,0) rh1 = dim_avg_n_Wrap(rh,0) ua1 = dim_avg_n_Wrap(ua,0) va1 = dim_avg_n_Wrap(va,0) ;https://www.ncl.ucar.edu/Document/Functions/Built-in/mixhum_ptrh.shtml shum = mixhum_ptrh(pres1,temp1,rh1,2) ;units: (hPA,K,%,kg/kg);calculate the specific humidity(2),(1)means mixing ratio printVarSummary(shum) uq = ua1 * shum ;vapor flux vq = va1 * shum copy_VarCoords(psfc(0,:,:), psfc1) copy_VarCoords(ua(0,:,:,:), uq) copy_VarCoords(va(0,:,:,:), vq) copy_VarCoords(pres(0,:,:,:), pres1) ;;--vertical integrated moisture flux ptop = 100 ; top layer pressure pbot = 1100 uqflux = vibeta(pres1(lat|:,lon|:,lev|:),uq(lat|:,lon|:,lev|:),2,psfc1,pbot,ptop)/9.8 ;should divide 9.8?? vqflux = vibeta(pres1(lat|:,lon|:,lev|:),vq(lat|:,lon|:,lev|:),2,psfc1,pbot,ptop)/9.8 ; 1 means linear interpolation, 2 means log interpolation qflux = sqrt(uqflux^2+vqflux^2)