<div dir="ltr">Hi Saji,<div><br></div><div>Hopefully I would have at least figured out the sign error eventually!</div><div><br></div><div>It seems like the grad_latlon_cfd function will work once I convert from curvilinear grid to rectilinear, which seems straightforward enough with NCL&#39;s ESMF regridding function.</div><div><br></div><div>Thanks!</div><div>Ryan</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Apr 21, 2016 at 7:47 PM, Saji Hameed <span dir="ltr">&lt;<a href="mailto:saji@u-aizu.ac.jp" target="_blank">saji@u-aizu.ac.jp</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div><div><div>Hi Ryan,<br><br></div>You can try downloading the libraries that compute horizontal gradients from <a href="http://www.cgd.ucar.edu/~shea/contributed.ncl_beta_640" target="_blank">http://www.cgd.ucar.edu/~shea/contributed.ncl_beta_640</a><br><br></div>I don&#39;t know what kind of grid your data is on - perhaps you may have to regrid it to a regular grid.<br><br></div>As for the plotting, maybe you should try RasterFill first.  It may help to smooth the data a bit before calculating the gradients (or remove any potential<br></div>discontinuities in the original field).<br><br></div><div>For the calculation of advection, you should multiply with -1.0 to get the right sign.<br></div><div><br></div>saji<br></div><div class="gmail_extra"><br clear="all"><div><div><div dir="ltr"><div><div dir="ltr"><br>Saji N Hameed,<br>Environmental Informatics, <br>University of Aizu, Tsuruga, Ikki-machi,<br>Aizuwakamatsu-shi, Fukushima 965-8580,<br>Japan<br>        <br>Tel: <a href="tel:%2B81242%2037-2736" value="+81242372736" target="_blank">+81242 37-2736</a><br>Fax:<a href="tel:%2B81242%2037-2760" value="+81242372760" target="_blank">+81242 37-2760</a><br> email: <a href="mailto:saji@u-aizu.ac.jp" target="_blank">saji@u-aizu.ac.jp</a><br> url: <a href="http://enformtk.u-aizu.ac.jp" target="_blank">http://enformtk.u-aizu.ac.jp</a><br> bib: <a href="http://www.researcherid.com/rid/B-9188-2009" target="_blank">http://www.researcherid.com/rid/B-9188-2009</a><div>code: <a href="https://github.com/sajinh" target="_blank">https://github.com/sajinh</a></div></div></div></div></div></div>
<br><div class="gmail_quote"><div><div class="h5">On Fri, Apr 22, 2016 at 6:09 AM, Ryan Connelly <span dir="ltr">&lt;<a href="mailto:rconne01@gmail.com" target="_blank">rconne01@gmail.com</a>&gt;</span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5"><div dir="ltr"><span style="font-size:12.8px">Hi fellow WRFers,</span><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">Does anyone have a sample script for calculating temperature advections in NCL?  (Note that I&#39;m stuck using V6.1.2, so the NCL function <font face="monospace, monospace">advect_variable</font> can&#39;t be used.  Regardless, it only runs on globally gridded data, which this is not.) </div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">I&#39;m trying to just hard code it like, <font face="monospace, monospace">temp_adv = u_plane*dTdx + v_plane*dTdy</font></div><div style="font-size:12.8px">where u_plane and v_plane are declared using the <font face="monospace, monospace">wrf_user_intrp3d function</font>.</div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">The problem I&#39;ve run into is the calculation of the gradient variables dTdx and dTdy.  Using NCL&#39;s <font face="monospace, monospace">center_difference_n</font> function produces numbers, though unrealistic, and the script ultimately crashes on <font face="monospace, monospace">wrf_contour </font><font face="arial, helvetica, sans-serif">by hanging up but not throwing any error.</font></div><div style="font-size:12.8px"><font face="arial, helvetica, sans-serif"><br></font></div><div style="font-size:12.8px"><font face="arial, helvetica, sans-serif">I&#39;ve already posted to the ncl-talk list serv, where it was suggested that I try this list instead.</font></div><div style="font-size:12.8px"><font face="arial, helvetica, sans-serif"><br></font></div><div style="font-size:12.8px"><font face="arial, helvetica, sans-serif">Thanks,</font></div><div style="font-size:12.8px"><font face="arial, helvetica, sans-serif">Ryan</font></div><span><font color="#888888"><div><br></div>-- <br><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><font size="1">Ryan Connelly</font></div><div dir="ltr"><div dir="ltr" style="font-size:12.8px"><font color="#000000"><font size="1">M.S. Student in Atmospheric Sciences, </font><span style="font-size:x-small">Stony Brook University</span><br></font></div><div dir="ltr" style="font-size:12.8px"><div><font color="#000000"><font size="1">B.S. in Meteorology with Minors in Mathematics and GIS, </font><span style="font-size:x-small">Valparaiso University</span></font></div></div><div><a href="mailto:rconne01@gmail.com" style="font-size:x-small" target="_blank">rconne01@gmail.com</a><br></div><div><font size="1"><a href="mailto:ryan.connelly@stonybrook.edu" target="_blank">ryan.connelly@stonybrook.edu</a></font></div></div></div></div></div></div></div></div></div></div>
</font></span></div>
<br></div></div>_______________________________________________<br>
Wrf-users mailing list<br>
<a href="mailto:Wrf-users@ucar.edu" target="_blank">Wrf-users@ucar.edu</a><br>
<a href="http://mailman.ucar.edu/mailman/listinfo/wrf-users" rel="noreferrer" target="_blank">http://mailman.ucar.edu/mailman/listinfo/wrf-users</a><br>
<br></blockquote></div><br></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><font size="1">Ryan Connelly</font></div><div dir="ltr"><div dir="ltr" style="font-size:12.8000001907349px"><font color="#000000"><font size="1">M.S. Student in Atmospheric Sciences, </font><span style="font-size:x-small">Stony Brook University</span><br></font></div><div dir="ltr" style="font-size:12.8000001907349px"><div><font color="#000000"><font size="1">B.S. in Meteorology with Minors in Mathematics and GIS, </font><span style="font-size:x-small">Valparaiso University</span></font></div></div><div><a href="mailto:rconne01@gmail.com" style="font-size:x-small" target="_blank">rconne01@gmail.com</a><br></div><div><font size="1"><a href="mailto:ryan.connelly@stonybrook.edu" target="_blank">ryan.connelly@stonybrook.edu</a></font></div></div></div></div></div></div></div></div></div></div>
</div>