On Wed, Oct 20, 2010 at 4:19 PM, Derek Gaston <[email protected]> wrote:
>
> To "fix" this I propose using relative_fuzzy_equals() like so:
>
> if (!(elem->point(n) - elem->point(0)).relative_fuzzy_equals((cached_nodes[n] 
> - cached_nodes[0])))
>
> But of course this could have the bad side effect of false positives... ie 
> two elements that are _extremely_ similar but not exactly and still pass this 
> check.
>
> So what do you guys think?  Is this a valid thing to do... or is it just too 
> unsafe?  Is there a better option?

Good catch.

I'll let Roy answer since he wrote that code, but I think what you
propose doing sounds fine.  You can specify a tolerance to
relative_fuzzy_equals as well if you want to make it pretty precise.

-- 
John

------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store 
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
Libmesh-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/libmesh-devel

Reply via email to