Dear Arlindo,<br> I herewith attach a GS file in which velocity potential and stream function is computed from u and v components. I attempted this long back and I am sorry to say that I could not remember the whole steps. Still I hope this may be useful. Also the following link may be useful.<br>
<a href="http://opengrads.org/doc/udxt/fish/fish.html#computing_velocity_potential_from_wind_components">http://opengrads.org/doc/udxt/fish/fish.html#computing_velocity_potential_from_wind_components</a><br><br>'reinit'<br>
'sdfopen /media/JKPRMUSIC/JKPR/DATA/ncep/d/uvw/<a href="http://uwnd.2000.nc">uwnd.2000.nc</a>'<br>'sdfopen /media/JKPRMUSIC/JKPR/DATA/ncep/d/uvw/<a href="http://vwnd.2000.nc">vwnd.2000.nc</a>'<br>'set lon 0 357.5'<br>
'set lat -90 90'<br>prompt 'key-in file name for psi:'<br>pull fname<br>'set fwrite 'fname<br>tt=1<br>while (tt<=10)<br>'set t 'tt<br>zz=1<br>while (zz<=2)<br>'set z 'zz<br>'define psi= fish_psi(uwnd,vwnd.2)'<br>
'define one=1+0*lat'<br>'define upsi=mvadv(one,psi)'<br>'define vpsi=-muadv(one,psi)'<br>*'set gxout shaded'<br>*'display psi/1e7'<br>*'set gxout stream'<br>*'display upsi;vpsi'<br>
'set gxout fwrite'<br>'d psi/1e7'<br>'d upsi'<br>'d vpsi'<br>zz=zz+1<br>endwhile<br>tt=tt+1<br>endwhile<br>'disable fwrite'<br><br>If any suggestions I will again look into my old archives. Best of Luck.<br clear="all">
<br>-- <br>Sincerely<br>***********************************************<br>Jayakrishnan.P.R<br>Teaching Associate (Atmospheric Science)<br>Academy of Climate Change Education and Research<br>Kerala Agricultural University<br>
Vellanikkara-680 656<br><br>and also<br><br>Research Fellow (Part Time)<br>Department of Atmospheric Sciences<br>CUSAT, Cochin-682 016<br>Kerala, India.<br>Mob: 09496026547<br><br>***********************************************