<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:"MS Gothic";
        panose-1:2 11 6 9 7 2 5 8 2 4;}
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:"\@MS Gothic";
        panose-1:2 11 6 9 7 2 5 8 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri","sans-serif";}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-US" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">I have plotted WRF data in grib format with a Mercator projection and it appears to plot correctly.&nbsp; The grib2ctl.pl script that builds the ctl file constructs
 the YDEF line like<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">YDEF 120 LEVELS&nbsp; -3.325 -3.305 -3.287 ….. &lt;120 levels given&gt;<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">It calculates and puts in the actual latitudes of the grid points for the particular Mercator grid that is defined in the file.&nbsp; The levels in the YDEF (or
 XDEF) do not need to be at even intervals so this method appears to work for the Mercator-projection data.&nbsp; &nbsp;&nbsp;<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">For your application, you can pull out the latitudes of the grid points from one of the wrfout* files using something like “ncdump –v CLAT wrfout…” and build
 the YDEF line from these values.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">Steve Masters&nbsp;&nbsp;&nbsp;
<a href="mailto:masters.steve@ensco.com">masters.steve@ensco.com</a><o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">ENSCO, Inc.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">Melbourne, FL<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><b><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;">From:</span></b><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;"> gradsusr-bounces@gradsusr.org [mailto:gradsusr-bounces@gradsusr.org]
<b>On Behalf Of </b>Yaqiang Wang<br>
<b>Sent:</b> Friday, July 12, 2013 1:23 AM<br>
<b>To:</b> GrADS Users Forum<br>
<b>Subject:</b> Re: [gradsusr] Shift in the lattitude while plotting in grads mercator/latlon projction<o:p></o:p></span></p>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
<p class="MsoNormal">Mercator projection is longitude equal-interval but not latitude equal-interval. The ctl without PDEF (Mercator is not supported in PDEF at present) may approximatively plot the data at low latitude area, but it's imposible plot the data
 at exactly position.<br>
<br>
On Friday, July 12, 2013, itesh dash wrote:<o:p></o:p></p>
<blockquote style="border:none;border-left:solid #CCCCCC 1.0pt;padding:0in 0in 0in 6.0pt;margin-left:4.8pt;margin-right:0in">
<div>
<p class="MsoNormal">The information actually were extracted from in the namelist.wps file using WRF2GrAGS which generate the control(ctl) file. For the model I only provided the grid resolution(9km), no of grid points in both north south (640) and east west(460)
 &nbsp;and center latitude and longitude (18.0 and 91.0).&nbsp;<o:p></o:p></p>
<div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
</div>
<div>
<p class="MsoNormal">The XDEF,YDEF and other params were automatically calculated by WRF2Grads. But your guessing may be correct as i have&nbsp;changed&nbsp;the start lat from -3.1006 to -2.1006 and the shift is minimized. BUt is this correct way?<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
</div>
<div>
<p class="MsoNormal">I am currently using the mercator&nbsp;projection. I will change to lat-lon&nbsp;projection&nbsp;and see if that makes the difference.&nbsp;<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
</div>
<div>
<p class="MsoNormal">Thanks.<o:p></o:p></p>
<div>
<div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
</div>
</div>
</div>
</div>
<div>
<p class="MsoNormal" style="margin-bottom:12.0pt"><o:p>&nbsp;</o:p></p>
<div>
<p class="MsoNormal">On Fri, Jul 12, 2013 at 12:40 AM, James T. Potemra &lt;<a href="mailto:jimp@hawaii.edu">jimp@hawaii.edu</a>&gt; wrote:<o:p></o:p></p>
<blockquote style="border:none;border-left:solid #CCCCCC 1.0pt;padding:0in 0in 0in 6.0pt;margin-left:4.8pt;margin-right:0in">
<div>
<p class="MsoNormal">Itesh:<br>
<br>
Your model output is 640 x 460, but your descriptor file has<br>
xdef = 639 and ydef = 459.&nbsp; These should be 640 and 460,<br>
respectively.&nbsp; Also, I think what Mohsen meant was to make<br>
sure your starting lat/lon is the same in the descriptor file<br>
and model grid, i.e., you have 61.1815 as the starting lon<br>
and -3.1006 as the starting lat.&nbsp; Are these the same as the<br>
model grid?<br>
<br>
Jim<o:p></o:p></p>
<div>
<div>
<p class="MsoNormal" style="margin-bottom:12.0pt"><o:p>&nbsp;</o:p></p>
<div>
<p class="MsoNormal">On 7/11/13 7:31 AM, itesh dash wrote:<o:p></o:p></p>
</div>
<blockquote style="margin-top:5.0pt;margin-bottom:5.0pt">
<div>
<p class="MsoNormal">Dear Mohsen, <o:p></o:p></p>
<div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
</div>
<div>
<p class="MsoNormal">thanks for the response. But I am not even trying to use any script. Just by opening and plotting the ctl file.<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
</div>
<div>
<p class="MsoNormal">Here is my ctl file<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
</div>
<div>
<div>
<p class="MsoNormal">dset ^Jul1013_12.dat<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">undef 1.e35<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">xdef &nbsp;639 linear &nbsp; 61.1815 &nbsp; 0.0935<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">ydef &nbsp;459 linear &nbsp; -3.1006 &nbsp; 0.0873<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">zdef &nbsp; &nbsp;3 levels<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">&nbsp; 850.00000<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">&nbsp; 500.00000<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">&nbsp; 200.00000<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">tdef &nbsp; &nbsp; &nbsp; &nbsp; 8 linear 12z10jul2013 &nbsp;6hr<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">vars 1<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">HGT 0 0 Terrain Height<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">endvars<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
</div>
<div>
<p class="MsoNormal">The wrf model ran with mercator projection 640 x 460 grid points 9 km resolution.<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
</div>
<div>
<p class="MsoNormal">I could not figure out why the shift is there. Is there a way i can balance the shift.<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
</div>
<div>
<p class="MsoNormal">regards,<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">itesh<o:p></o:p></p>
</div>
</div>
</div>
<div>
<p class="MsoNormal" style="margin-bottom:12.0pt"><o:p>&nbsp;</o:p></p>
<div>
<p class="MsoNormal">On Thu, Jul 11, 2013 at 11:58 PM, Mohsen Soltani &lt;<a href="mailto:soltani.clima@gmail.com">soltani.clima@gmail.com</a>&gt; wrote:<o:p></o:p></p>
<blockquote style="border:none;border-left:solid #CCCCCC 1.0pt;padding:0in 0in 0in 6.0pt;margin-left:4.8pt;margin-right:0in">
<div>
<div>
<p class="MsoNormal"><span style="font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;;color:#0B5394">itesh,<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;;color:#0B5394"><o:p>&nbsp;</o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;;color:#0B5394">Make sure Lat/Lon in your .ctl file are the same as your script!<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;;color:#0B5394"><o:p>&nbsp;</o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;;color:#0B5394">Mohsen<o:p></o:p></span></p>
</div>
</div>
<div>
<p class="MsoNormal"><br clear="all">
<o:p></o:p></p>
<div>
<div>
<p class="MsoNormal">-- <o:p></o:p></p>
<div>
<p class="MsoNormal"><span style="font-size:9.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#274E13">April showers bring May flowers!</span><o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">--<span style="color:#B45F06">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;<br>
<b>Mohsen Soltani, M.Sc.</b><br>
Climatology Grad Student,<br>
Department of Climatology, Faculty of Geography,</span><o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><span style="color:#B45F06">University of Tehran,&nbsp;Tehran, Iran</span><o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><span style="color:#B45F06">voice: (&#43;98) 9119772934<br>
e-mail</span><span style="color:#BF9000">:</span> <a href="mailto:soltani.clima@gmail.com">
soltani.clima@gmail.com</a><o:p></o:p></p>
</div>
</div>
</div>
<p class="MsoNormal" style="margin-bottom:12.0pt"><o:p>&nbsp;</o:p></p>
<div>
<div>
<div>
<p class="MsoNormal">On Thu, Jul 11, 2013 at 9:05 AM, itesh dash &lt;<a href="mailto:itesh@rimes.int">itesh@rimes.int</a>&gt; wrote<o:p></o:p></p>
</div>
</div>
</div>
</div>
</blockquote>
</div>
</div>
</blockquote>
</div>
</div>
</div>
</blockquote>
</div>
</div>
</blockquote>
<p class="MsoNormal"><br>
<br>
-- <br>
*************************************************<br>
Dr. Yaqiang Wang<br>
Chinese Academy of Meteorological Sciences (CAMS)<br>
46, Zhong-Guan-Cun South Avenue<br>
Beijing, 100081<br>
China<br>
<span style="font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;">             </span><br>
<a href="mailto:yaqiang.wang@gmail.com" target="_blank">yaqiang.wang@gmail.com</a><br>
<br>
<a href="http://www.meteothinker.com" target="_blank">http://www.meteothinker.com</a><br>
**************************************************<o:p></o:p></p>
</div>
<br>
<hr>
<font face="Arial" color="Gray" size="1">The information contained in this email message is intended only for the use of the individual(s) to whom it is addressed and may contain information that is privileged and sensitive. If you are not the intended recipient,
 or otherwise have received this communication in error, please notify the sender immediately by email at the above referenced address and note that any further dissemination, distribution or copying of this communication is strictly prohibited.<br>
<br>
The U.S. Export Control Laws regulate the export and re-export of technology originating in the United States. This includes the electronic transmission of information and software to foreign countries and to certain foreign nationals. Recipient agrees to abide
 by these laws and their regulations -- including the U.S. Department of Commerce Export Administration Regulations and the U.S. Department of State International Traffic in Arms Regulations -- and not to transfer, by electronic transmission or otherwise, any
 content derived from this email to either a foreign national or a foreign destination in violation of such laws.<br>
</font>
</body>
</html>