<div>Dear Rob, Mike and others;</div> <div> </div> <div>I have the same experience. In my laptop of 32 bit and using Suse 9.2, there is no problem at all to run regrid2.</div> <div> </div> <div>However, in my new laptop of 64 bit and using compat-g77 fortran compiler of Fedora Core 6, I have the same problem with Rob's problem.</div> <div> </div> <div>I guess: The compat-g77 fortran compiler can not compile the regrid2beta.f </div> <div>If yes, the regrid2beta.f should be modified to accommodate the other compiler(s).</div> <div> </div> <div>Has anyone experience by using compat-g77 fortran compiler and successfull to compile regrid2?</div> <div> </div> <div>Best regards, Syamsul</div> <div><BR><BR><B><I>Robert Burgman <rburgman@RSMAS.MIAMI.EDU></I></B> wrote:</div> <BLOCKQUOTE class=replbq style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #1010ff 2px solid"> <DIV style="MARGIN: 0px">I am also having a problem
with regrid2. I have compiled the function on our linux box and it is working fine, however when I compiled the code on my macbook pro I get an error</DIV> <DIV style="MIN-HEIGHT: 14px; MARGIN: 0px; FONT: 12px Helvetica"><BR></DIV> <DIV style="MARGIN: 0px">ga-> d regrid2(sst,5,5,ba)</DIV> <DIV style="MARGIN: 0px">number of arguments = 0</DIV> <DIV style="MIN-HEIGHT: 14px; MARGIN: 0px; FONT: 12px Helvetica"><BR></DIV> <DIV style="MARGIN: 0px">regrid requires 2 or more arguements: <<a write statement tells me the nargs=0 here>></DIV> <div style="MARGIN: 0px"> </div> <DIV style="MARGIN: 0px">Error from regrid2: Error reading from transfer file</DIV> <DIV style="MARGIN: 0px"> File name: udf.regrid.gfi</DIV> <DIV style="MARGIN: 0px">Operation Error: Error from regrid2 function</DIV> <DIV style="MARGIN: 0px"> Error ocurred at column 1</DIV> <DIV style="MARGIN: 0px">DISPLAY
error: Invalid expression</DIV> <DIV style="MARGIN: 0px"> Expression = regrid2(sst,5,5,ba)</DIV> <DIV style="MIN-HEIGHT: 14px; MARGIN: 0px; FONT: 12px Helvetica"><BR></DIV> <DIV style="MARGIN: 0px">I am unsure why there is a problem reading from the udf.regrid.gfi file, which is created when I execute the command and is populated with data. The udf.regrid.gfo and udf.regrid.out are , of course empty. </DIV> <DIV style="MARGIN: 0px">Has any one compiled regrid2beta.f on an intel Mac?</DIV> <DIV style="MIN-HEIGHT: 14px; MARGIN: 0px; FONT: 12px Helvetica"><BR></DIV> <DIV style="MIN-HEIGHT: 14px; MARGIN: 0px; FONT: 12px Helvetica"><BR></DIV> <DIV style="MARGIN: 0px">Thanks,</DIV> <DIV style="MARGIN: 0px">Rob</DIV><BR> <DIV> <DIV>On May 29, 2007, at 3:17 PM, Daniel Victoria wrote:</DIV><BR class=Apple-interchange-newline> <BLOCKQUOTE type="cite"> <DIV style="MARGIN: 0px">Mike, I'm resending an earlier email where I explain the dimensions
of</DIV> <DIV style="MARGIN: 0px">the files. Could it be that I'm trying to convert a gaussian grid to a</DIV> <DIV style="MARGIN: 0px">uniform grid?</DIV> <DIV style="MIN-HEIGHT: 14px; MARGIN: 0px"><BR></DIV> <DIV style="MARGIN: 0px">-------------------------------------------------------------------------------------------------------</DIV> <DIV style="MARGIN: 0px">I've daily NetCDF TMAX from ncep/ncar reanalysis at a gaussian grid</DIV> <DIV style="MARGIN: 0px">(downloaded from cdc) and want to resample it to a 0.25 x 0.25 grid.</DIV> <DIV style="MARGIN: 0px">So I issued the following command:</DIV> <DIV style="MIN-HEIGHT: 14px; MARGIN: 0px"><BR></DIV> <DIV style="MARGIN: 0px">lats4d -i input.nc -o output -de template_0.25.ctl -func regrid2(@,0.25,0.25,bs)</DIV> <DIV style="MIN-HEIGHT: 14px; MARGIN: 0px"><BR></DIV> <DIV style="MARGIN: 0px">And the output grid I got is all messed up! The dimensions and the</DIV> <DIV style="MARGIN: 0px">template file
are:</DIV> <DIV style="MIN-HEIGHT: 14px; MARGIN: 0px"><BR></DIV> <DIV style="MARGIN: 0px">Input dimensions:</DIV> <DIV style="MARGIN: 0px">ga-> q file</DIV> <DIV style="MARGIN: 0px">File 1 : daily NMC reanalysis (1948)</DIV> <DIV style="MARGIN: 0px">Descriptor: tmax.ncep.1948.2006.nc</DIV> <DIV style="MARGIN: 0px">Binary: tmax.ncep.1948.2006.nc</DIV> <DIV style="MARGIN: 0px">Type = Gridded</DIV> <DIV style="MARGIN: 0px">Xsize = 33<SPAN class=Apple-converted-space> </SPAN>Ysize = 21<SPAN class=Apple-converted-space> </SPAN>Zsize = 1<SPAN class=Apple-converted-space> </SPAN>Tsize = 21550</DIV> <DIV style="MARGIN: 0px">Number of Variables = 1</DIV> <DIV style="MARGIN: 0px"><SPAN class=Apple-converted-space> </SPAN>tmax 0 -999 Daily Maximum Temperature at 2 m</DIV> <DIV style="MARGIN: 0px">ga-> q dims</DIV> <DIV style="MARGIN: 0px">Default file number is: 1</DIV> <DIV style="MARGIN: 0px">X is varying <SPAN
class=Apple-converted-space> </SPAN>Lon = 270 to 330 <SPAN class=Apple-converted-space> </SPAN>X = 1.00001 to 33</DIV> <DIV style="MARGIN: 0px">Y is varying <SPAN class=Apple-converted-space> </SPAN>Lat = -29.5234 to 8.57257 <SPAN class=Apple-converted-space> </SPAN>Y = 1 to 21</DIV> <DIV style="MARGIN: 0px">Z is fixed <SPAN class=Apple-converted-space> </SPAN>Lev = 0<SPAN class=Apple-converted-space> </SPAN>Z = 1</DIV> <DIV style="MARGIN: 0px">T is fixed <SPAN class=Apple-converted-space> </SPAN>Time = 00Z01JAN1948<SPAN class=Apple-converted-space> </SPAN>T = 1</DIV> <DIV style="MIN-HEIGHT: 14px; MARGIN: 0px"><BR></DIV> <DIV style="MARGIN: 0px">Template file:</DIV> <DIV style="MARGIN: 0px">dset nofile</DIV> <DIV style="MARGIN: 0px">title "Template GrADS ctl at 0.25 horizontal grid"</DIV> <DIV style="MARGIN: 0px">options template</DIV> <DIV style="MARGIN: 0px">undef -999</DIV> <DIV style="MARGIN:
0px">xdef 129 linear 279 0.25</DIV> <DIV style="MARGIN: 0px">ydef 101 linear -20 0.25</DIV> <DIV style="MARGIN: 0px">zdef 1 levels 1</DIV> <DIV style="MARGIN: 0px">tdef 21550 linear 00z01jan1948 1dy</DIV> <DIV style="MARGIN: 0px">vars 1</DIV> <DIV style="MARGIN: 0px">var 0 0 generic</DIV> <DIV style="MARGIN: 0px">endvars</DIV> <DIV style="MIN-HEIGHT: 14px; MARGIN: 0px"><BR></DIV> <DIV style="MIN-HEIGHT: 14px; MARGIN: 0px"><BR></DIV> <DIV style="MARGIN: 0px">Anyone knows what am I doing wrong?</DIV> <DIV style="MARGIN: 0px">Cheers</DIV> <DIV style="MARGIN: 0px">Daniel</DIV> <DIV style="MIN-HEIGHT: 14px; MARGIN: 0px"><BR></DIV> <DIV style="MARGIN: 0px">On 5/29/07, Michael Fiorino <<A href="mailto:Michael.Fiorino@noaa.gov">Michael.Fiorino@noaa.gov</A>> wrote:</DIV> <BLOCKQUOTE type="cite"> <DIV style="MARGIN: 0px">daniel, this could be a bug, but it might also be the size of nimax,</DIV> <DIV style="MARGIN: 0px">njmax -- you may need to increase for
really big output files.<SPAN class=Apple-converted-space> </SPAN>i wrote</DIV> <DIV style="MARGIN: 0px">this over 10 y ago and the default nimax,njmax is now on the low side.</DIV> <DIV style="MARGIN: 0px">also, check the open for udf.regrid.gfi (input grid file) and</DIV> <DIV style="MARGIN: 0px">udf.regrid.gfo (output grid file).<SPAN class=Apple-converted-space> </SPAN>i'm confused why you're getting more</DIV> <DIV style="MARGIN: 0px">data out; you may need to do a 'set lat ...' 'set lon ...' to force</DIV> <DIV style="MARGIN: 0px">output exactly where you want...<SPAN class=Apple-converted-space> </SPAN>the version you're using is that</DIV> <DIV style="MARGIN: 0px">latest...<SPAN class=Apple-converted-space> </SPAN>best /r mike</DIV> <DIV style="MIN-HEIGHT: 14px; MARGIN: 0px"><BR></DIV> <DIV style="MIN-HEIGHT: 14px; MARGIN: 0px"><BR></DIV> <DIV style="MIN-HEIGHT: 14px; MARGIN: 0px"><BR></DIV> <DIV style="MIN-HEIGHT: 14px; MARGIN:
0px"><BR></DIV> <DIV style="MARGIN: 0px">Daniel Victoria wrote:</DIV> <DIV style="MARGIN: 0px">> Hi Michael,</DIV> <DIV style="MARGIN: 0px">></DIV> <DIV style="MARGIN: 0px">> Xavier Francis helped me out and I figured out what was going on.</DIV> <DIV style="MARGIN: 0px">> regrid2 was adding some more lines and columns to the output file. So,</DIV> <DIV style="MARGIN: 0px">> the way I solved the issue was to export the regrided file to a binary</DIV> <DIV style="MARGIN: 0px">> grid (set gxout fwrite). When I do this, GrADS reports the number of</DIV> <DIV style="MARGIN: 0px">> columns/rows and the initial lat/lon. So I can then write a correct</DIV> <DIV style="MARGIN: 0px">> .ctl file and export to NetCDF using lats4d. A lengthier process but</DIV> <DIV style="MARGIN: 0px">> it works.</DIV> <DIV style="MARGIN: 0px">></DIV> <DIV style="MARGIN: 0px">> As for the details, I did sent a more detailed email before but with</DIV>
<DIV style="MARGIN: 0px">> the input and output dimensions (template ctl and netcdf dims). I had</DIV> <DIV style="MARGIN: 0px">> no idea it could be a compilation problem with regrid2, specially</DIV> <DIV style="MARGIN: 0px">> because I know nothing about fortran.</DIV> <DIV style="MARGIN: 0px">> Just to answer your questions, the open line in regrid2beta.f is:</DIV> <DIV style="MARGIN: 0px">></DIV> <DIV style="MARGIN: 0px">> open (iunit_diag,file='udf.regrid.out',</DIV> <DIV style="MARGIN: 0px">> <SPAN class=Apple-converted-space> </SPAN>$ <SPAN class=Apple-converted-space> </SPAN>form='formatted',status='unknown')</DIV> <DIV style="MARGIN: 0px">></DIV> <DIV style="MARGIN: 0px">> Can't recall where I got the code from but it was about an year ago.</DIV> <DIV style="MARGIN: 0px">> Is there a more recent version?</DIV> <DIV style="MARGIN: 0px">></DIV> <DIV style="MARGIN: 0px">> Cheers</DIV>
<DIV style="MARGIN: 0px">> Daniel</DIV> <DIV style="MARGIN: 0px">></DIV> <DIV style="MARGIN: 0px">></DIV> <DIV style="MARGIN: 0px">> On 5/29/07, Michael Fiorino <<A href="mailto:Michael.Fiorino@noaa.gov">Michael.Fiorino@noaa.gov</A>> wrote:</DIV> <DIV style="MARGIN: 0px">>> daniel, this looks like a regrid2 build problem.<SPAN class=Apple-converted-space> </SPAN>the most annoying</DIV> <DIV style="MARGIN: 0px">>> thing about fortran is the lack of a binary<SPAN class=Apple-converted-space> </SPAN>i/o standard...<SPAN class=Apple-converted-space> </SPAN>look at</DIV> <DIV style="MARGIN: 0px">>> the 'open' line in the .f -- using direct access?<SPAN class=Apple-converted-space> </SPAN>sequential?<SPAN class=Apple-converted-space> </SPAN>and the</DIV> <DIV style="MARGIN: 0px">>> usual plea -- if you want help, you HAVE to send details -- operating</DIV> <DIV style="MARGIN: 0px">>> system,
where you got the regrid code, the .ctl file you're working...</DIV> <DIV style="MARGIN: 0px">>> /r mike</DIV> <DIV style="MARGIN: 0px">>></DIV> <DIV style="MARGIN: 0px">>> Daniel Victoria wrote:</DIV> <DIV style="MARGIN: 0px">>> > Hi all,</DIV> <DIV style="MARGIN: 0px">>> ></DIV> <DIV style="MARGIN: 0px">>> > I still haven't been able to regrid the gausian NCEP file to a uniform</DIV> <DIV style="MARGIN: 0px">>> > 0.25 x 0.25 lat lon grid. The result I get is all messed up (attached</DIV> <DIV style="MARGIN: 0px">>> > file). Does anyone knows what I'm doing wrong? Or is grads not able to</DIV> <DIV style="MARGIN: 0px">>> > regrid the gaussian NCEP to uniform grid?</DIV> <DIV style="MARGIN: 0px">>> ></DIV> <DIV style="MARGIN: 0px">>> > Thanks</DIV> <DIV style="MARGIN: 0px">>> > Daniel</DIV> <DIV style="MARGIN: 0px">>> ></DIV> <DIV style="MARGIN:
0px">>> ></DIV> <DIV style="MARGIN: 0px">>> ------------------------------------------------------------------------</DIV> <DIV style="MARGIN: 0px">>> ></DIV> <DIV style="MARGIN: 0px">>></DIV> <DIV style="MIN-HEIGHT: 14px; MARGIN: 0px"><BR></DIV></BLOCKQUOTE></BLOCKQUOTE></DIV><BR> <DIV><SPAN class=Apple-style-span style="WORD-SPACING: 0px; FONT: 12px Helvetica; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; WHITE-SPACE: normal; LETTER-SPACING: normal; BORDER-COLLAPSE: separate; border-spacing: 0px 0px; orphans: 2; widows: 2; khtml-text-decorations-in-effect: none; apple-text-size-adjust: auto"><SPAN class=Apple-style-span style="WORD-SPACING: 0px; FONT: 12px Helvetica; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; WHITE-SPACE: normal; LETTER-SPACING: normal; BORDER-COLLAPSE: separate; border-spacing: 0px 0px; orphans: 2; widows: 2; khtml-text-decorations-in-effect: none; apple-text-size-adjust: auto"><SPAN
class=Apple-style-span style="WORD-SPACING: 0px; FONT: 12px Helvetica; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; WHITE-SPACE: normal; LETTER-SPACING: normal; BORDER-COLLAPSE: separate; border-spacing: 0px 0px; orphans: 2; widows: 2; khtml-text-decorations-in-effect: none; apple-text-size-adjust: auto"><SPAN class=Apple-style-span style="WORD-SPACING: 0px; FONT: 12px Helvetica; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; WHITE-SPACE: normal; LETTER-SPACING: normal; BORDER-COLLAPSE: separate; border-spacing: 0px 0px; orphans: 2; widows: 2; khtml-text-decorations-in-effect: none; apple-text-size-adjust: auto"><SPAN class=Apple-style-span style="WORD-SPACING: 0px; FONT: 12px Helvetica; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; WHITE-SPACE: normal; LETTER-SPACING: normal; BORDER-COLLAPSE: separate; border-spacing: 0px 0px; orphans: 2; widows: 2; khtml-text-decorations-in-effect: none; apple-text-size-adjust: auto"><SPAN
class=Apple-style-span style="WORD-SPACING: 0px; FONT: 12px Helvetica; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; WHITE-SPACE: normal; LETTER-SPACING: normal; BORDER-COLLAPSE: separate; border-spacing: 0px 0px; orphans: 2; widows: 2; khtml-text-decorations-in-effect: none; apple-text-size-adjust: auto"><SPAN class=Apple-style-span style="WORD-SPACING: 0px; FONT: 12px Helvetica; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; WHITE-SPACE: normal; LETTER-SPACING: normal; BORDER-COLLAPSE: separate; border-spacing: 0px 0px; orphans: 2; widows: 2; khtml-text-decorations-in-effect: none; apple-text-size-adjust: auto"><SPAN class=Apple-style-span style="WORD-SPACING: 0px; FONT: 12px Helvetica; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; WHITE-SPACE: normal; LETTER-SPACING: normal; BORDER-COLLAPSE: separate; border-spacing: 0px 0px; orphans: 2; widows: 2; khtml-text-decorations-in-effect: none; apple-text-size-adjust: auto"> <DIV
style="MARGIN: 0px">----------------------------------------------------</DIV> <DIV style="MARGIN: 0px">Dr. Robert Burgman</DIV> <DIV style="MARGIN: 0px">Division of Meteorology and Physical Oceanography</DIV> <DIV style="MARGIN: 0px">Rosenstiel School of Marine and Atmospheric Science</DIV> <DIV style="MARGIN: 0px">University of Miami MPO, MSC 237</DIV> <DIV style="MARGIN: 0px">4600 Rickenbacker Causeway</DIV> <DIV style="MARGIN: 0px">Miami, FL 33149</DIV> <DIV style="MIN-HEIGHT: 14px; MARGIN: 0px"><BR></DIV> <DIV style="MARGIN: 0px">Tel: <SPAN class=Apple-converted-space> </SPAN>(305) 421-4272</DIV> <DIV style="MARGIN: 0px">Fax:<SPAN class=Apple-converted-space> </SPAN> <SPAN class=Apple-converted-space> </SPAN>(305) 421-4696</DIV> <DIV style="MARGIN: 0px">Email: <SPAN class=Apple-converted-space> </SPAN><A href="mailto:rburgman@rsmas.miami.edu">rburgman@rsmas.miami.edu</A></DIV> <DIV
style="MARGIN: 0px">---------------------------------------------------</DIV> <DIV style="MARGIN: 0px"><BR class=khtml-block-placeholder></DIV><BR class=Apple-interchange-newline></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></DIV><BR></BLOCKQUOTE><BR><p> 
<hr size=1>
Don't get soaked. Take a<a href="
http://tools.search.yahoo.com/shortcuts/?fr=oni_on_mail&#news"> quick peak at the forecast </a><br> with the<a href="
http://tools.search.yahoo.com/shortcuts/?fr=oni_on_mail&#news">Yahoo! Search weather shortcut.</a>