How the stream function and gradient function work

From: Guangshan Chen <gchen9_at_nyahnyahspammersnyahnyah>
Date: Mon, 24 Aug 2009 17:25:50 -0500

Dear all,

I did a test to the stream function (uv2sfvpf) and the gradient
function (gradsf). But there seems something is wrong in my script.

I used the uv2sfvpf function to calculate stream function from u and v
wind. Then I used the gradsf to calculate
u and v wind from the stream function that I calculated in the first
step. Last, I compared the original wind field
and the wind field calculate from the steam function.

These two wind field should be the same, supposedly. But the figure
show that they are quite different.

I attached my script and the figure. Could anyone give me a hand?
The following is the core of the code.

; calculate stream function
   uvmsg = 1e+36
   sf = new ( (/nlat,mlon /), float, uvmsg ) ; stream function
   vp = new ( (/nlat,mlon /), float, uvmsg ) ; velocity potential

   uv2sfvpf (uwind,vwind, sf,vp) ; u,v ==> stream function + velocity
; calcualte the stream function's
; lat and longitudinal derivatives
   sf_x = sf
   sf_y = sf
   gradsf(sf, sf_x, sf_y)

   v_est = -sf_x
   u_est = sf_y


Thanks in advance.


ncl-talk mailing list
List instructions, subscriber options, unsubscribe:

Received on Mon Aug 24 2009 - 16:25:50 MDT

This archive was generated by hypermail 2.2.0 : Wed Sep 02 2009 - 12:24:39 MDT