如何计算du / dx和dv / dy水分通量收敛吗?- 江南体育网页版- - - - -地球科学堆江南电子竞技平台栈交换 最近30从www.hoelymoley.com 2023 - 07 - 07 - t22:54:00z //www.hoelymoley.com/feeds/question/9634 https://creativecommons.org/licenses/by-sa/4.0/rdf //www.hoelymoley.com/q/9634 9 如何计算du / dx和dv / dy水分通量收敛吗? //www.hoelymoley.com/users/3194 2017 - 02 - 09 - t08:35:04z 2017 - 07 - 02 - t22:42:39z < p > u风美元,v风美元和特定的湿度。我想计算网格点水分通量收敛。所以我需要计算的价值美元q(\压裂{du} {dx} + \压裂{dv} {dy}) $ < / p > < p >我的问题是如何计算$ \压裂{du} {dx} $和$ \压裂{dv} {dy}从u风美元美元美元风准备点(x, y)美元吗?< / p > //www.hoelymoley.com/questions/9634/-/10667 # 10667 5 她回答的如何计算du / dx和dv / dy水分通量收敛吗? //www.hoelymoley.com/users/8396 2017 - 06 - 22 - t20:09:28z 2017 - 07 - 02 - t22:42:39z < p >我想象你有水平网格(x, y)和风力分量u (x, y)和v (x, y)。< / p >

Normally we do 1-degree of latitude constant (y-dimension) and equal to 110000 m. So your dy depends on how many degrees per grid point you have (yresolution). However, dx will vary according to the latitude.

dy=110000*yesolution;

Now, we may use centered finite differences to compute what you want. (Below is a Matlab code, but I believe generic enough to be reproducible in other languages).

for y=2:length(lat)-1 dx=abs(110000*cos(latx(y)*(2*pi/360))*xresolution); for x=2:length(lon)-1 div(x,y,1)= (u(x+1,y,1)-u(x-1,y,1))/(2*dx) + (v(x,y+1,1)-v(x,y-1,1)/(2*dy); end end

Note that you will have an empty frame around your divergence field when x=1, x=max(x), y=1 and y=max(y), once they do not have two neighboors to compute the differences. The same is observed when you do this with hdivg function in Grads, for example.

By the way, this is based on and yields the same result as Grads (I have checked!) using cdiff to reproduce hdivg.

Also note that the cosine function here works with radians, so if you compute cosines in degrees directly (i.e. cosd function in Matlab), you should omit the term scaling by (2*pi/360), which is just a conversion.

Hope it helps!

//www.hoelymoley.com/questions/9634/-/10713 # 10713 3 由BarocliniCplusplus回答如何计算du / dx和dv / dy水分通量收敛吗? BarocliniCplusplus //www.hoelymoley.com/users/704 2017 - 06 - 28 - t14:44:36z 2017 - 06 - 28 - t14:44:36z < p >最简单的答案是使用有限差分。哪一个是完全你的选择。例如,我将选择一个简单的中心差分格式。< / p >

You say you have a grid, and your point ($x$,$y$) is at the ith and jth gridpoint, where i indicates the left-right index on the grid and j indicates the north-south index on the grid. Therefore $u$ and $v$ can be expressed as $u(x_{i,j},y_{i,j})$ and $v(x_{i,j},y_{i,j})$.

$$\frac{du}{dx}\approx\frac{\Delta u}{\Delta x}=\frac{u(x+\Delta x,y)-u(x-\Delta x,y)}{\Delta x}=\frac{u(x_{i+1,j},y)-u(x_{i-1,j},y)}{x_{i+1,j}-x_{i-1,j}}=\frac{u_{i+1,j}-u_{i-1,j}}{x_{i+1,j}-x_{i-1,j}}$$

A similar process can be applied to the v component, just change the index, and the variables

Baidu
map