comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: TRIGRID problem
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: TRIGRID problem [message #23081] Fri, 05 January 2001 12:30
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Cathy Smith (cas@cdc.noaa.gov) writes:

> I ran into a problem using TRIGRID to interpolate an array from 36x16 to 72x16
> on a sphere. I have the two lines
>
> triangulate,xlon1,xlat1,tr,FVALUE=slp1,sphere=s,/degrees
>
> z=trigrid(slp1,[0.,0.],[0.,15.,355.,90.],NX=72,NY=16,/degree s,sphere=s)
>
> This did not work and gave me the error
>
> % TRIGRID: Points are co-linear, no solution.
>
> However, using 354.99 instead of 355 gave me the correctly interpolated
> grid and no error.
>
> I think I followed the directions correctly (and in fact I tried setting
> GS to 5x5 and other similar
> permutations but got the same error).
>
> Does anyone know why?

I'm going to guess the infamous round-off error
related to the way computers store numbers. But
this is a useful trick to work around this frequent
problem. I've tried scaling the data before gridding,
etc. Lot's of things work. Sorta. :-)

Cheers,

David
--
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
[Message index]
 
Read Message
Previous Topic: grid3 and ill-conditioned matrix stuff
Next Topic: Re: Map projection and object graphics

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 14:26:21 PDT 2025

Total time taken to generate the page: 0.72661 seconds