<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=us-ascii">
<meta name="Generator" content="Microsoft Word 14 (filtered medium)">
<style><!--
/* Font Definitions */
@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;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-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;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
span.EmailStyle18
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@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="color:#1F497D">Just to follow up on my own question, I think I found the solution.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">When I increased MAX_DOMAINS from 21 to 41 in config.wrf, I then got errors from real.exe stating the following:<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"> get_config_rec_as_buffer: buffer size too small for config_rec<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">A bit more poking around showed this was controlled by CONFIG_BUF_LEN in config.wrf. The original value was 32768. Since I essentially doubled MAX_DOMAINS, I figured that a doubling of CONFIG_BUF_LEN was in
order, to 65536.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">After rebuilding, things seem to be working as I’d like. I can now run WRF with 12 domains, and hopefully more when needed. I’ll revisit if I come across any other issues.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Later,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Mike<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> Zulauf, Michael
<br>
<b>Sent:</b> Tuesday, May 03, 2016 2:54 PM<br>
<b>To:</b> 'wrf-users@ucar.edu'<br>
<b>Cc:</b> 'wrfhelp@ucar.edu'<br>
<b>Subject:</b> WRF V3.3.1 and MAX_DOMAINS<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Hi all...<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">I’m running WRF V3.3.1 for forecasting at work. Our configuration covers the CONUS area at a moderate resolution, with quite a few nested grids over different areas for enhanced resolution. Our currently working setup uses up to 10 total
domains – d01 to d10. This has been running without problem.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Due to new forecasting needs, I’ve been attempting to add two more domains to bring us up to 12 (ie, up to d12). I’ve used exactly the same methodology to add these two new domains as I have in the past, but I’m hitting a snag.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Long story short, I found that having more than 11 values (domains) defined in any of the namelist.input variables that are dimensioned by max_dom causes real.exe to fail. It fails with a very unhelpful error message I might add. It doesn’t
even matter if max_dom is actually 11 or less, if you have more than 11 columns, it will fail.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">After a little digging around, it appears to me that this is dictated by the parameter max_domains, which is defined from the preprocessing variable MAX_DOMAINS_F, which is set by utilizing the variable MAX_DOMAINS in configure.wrf.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">My configure.wrf has:<o:p></o:p></p>
<p class="MsoNormal"> MAX_DOMAINS = 21<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">This is utilized as a preprocessor directive during compilation:<o:p></o:p></p>
<p class="MsoNormal"> -DMAX_DOMAINS_F=$(MAX_DOMAINS)<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Finally, in frame/module_driver_constants.F, we calculate max_domains:<o:p></o:p></p>
<p class="MsoNormal"> max_domains = ( MAX_DOMAINS_F - 1 ) / 2 + 1<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">So, plugging in the MAX_DOMAINS value of 21, I see that I get a max_domains parameter value of 11. So that makes sense (sort of).<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">So now I wonder, can I simply rebuild WRF after increasing my value of MAX_DOMAINS in configure.wrf? Say to 41? That would yield a value of max_domains of 21, which should hold me for a while.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Is that ok, or will it break something else? Will I need to tweak any other settings?<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Thanks,<o:p></o:p></p>
<p class="MsoNormal">Mike<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">-- <o:p></o:p></p>
<p class="MsoNormal">Mike Zulauf<o:p></o:p></p>
<p class="MsoNormal">Meteorologist, Lead Senior<o:p></o:p></p>
<p class="MsoNormal">Operational Meteorology <o:p></o:p></p>
<p class="MsoNormal">Iberdrola Renewables<o:p></o:p></p>
<p class="MsoNormal">1125 NW Couch, Suite 700<o:p></o:p></p>
<p class="MsoNormal">Portland, OR 97209<o:p></o:p></p>
<p class="MsoNormal">Office: 503-478-6304 Cell: 503-913-0403<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
</body>
</html>
<table><tr><td bgcolor=#ffffff><font color=#000000><pre>==============================================================
Please consider the environment before printing this email.
If you have received this message in error, please notify the sender and immediately delete this message and any attachment hereto and/or copy hereof, as such message contains confidential information intended solely for the individual or entity to whom it is addressed. The use or disclosure of such information to third parties is prohibited by law and may give rise to civil or criminal liability.
The views presented in this message are solely those of the author(s) and do not necessarily represent the opinion of Iberdrola Renewables, LLC. or any company of its group. Neither Iberdrola Renewables, LLC. nor any company of its group guarantees the integrity, security or proper receipt of this message. Likewise, neither Iberdrola Renewables, LLC. nor any company of its group accepts any liability whatsoever for any possible damages arising from, or in connection with, data interception, software viruses or manipulation by third parties.
==============================================================</pre></font></td></tr></table>