On Wed, Feb 23, 2011 at 14:05, Roman Vetter <[email protected]>wrote:
> Exactly. That's kind of the point. In order to be able to call > SNESConvergedReasons[reason], the reason enum/int must be stored > before _snes gets destroyed, which it isn't currently. Which brings be > back to my initial suggestion. > So there are a couple options for exposing reason to the user. 1. Send the raw backend-specific enum to the user. Downside: user needs to write different code for each back end. 2. Always convert to some new libmesh enum. Downside: conversion from backend value to generic value is not injective (several values might be mapped to "unknown", so you have lost information that the user might want. 3. Create a new libmesh enum, but store the backend value. This can always be converted to a generic value when convenient. My comment regarding KSPConvergedReasons is that many PETSc users are familiar with the specific failure modes so it would be entirely reasonable to print it instead of translated strings. It is certainly much better than printing "Unknown/unsupported con(di)vergence".
------------------------------------------------------------------------------ Free Software Download: Index, Search & Analyze Logs and other IT data in Real-Time with Splunk. Collect, index and harness all the fast moving IT data generated by your applications, servers and devices whether physical, virtual or in the cloud. Deliver compliance at lower cost and gain new business insights. http://p.sf.net/sfu/splunk-dev2dev
_______________________________________________ Libmesh-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/libmesh-devel
