On Wed, 15 Sep 2010, Tim Kroeger wrote:

> Just to keep this clear: NumericVector::solve_only_on() will only accept a 
> list of dofs, nothing else, because in particular a NumericVector does not 
> know anything about subdomain ids.

Absolutely.

> On the other hand, System::solve_only_on() will only accept (a
> reference to) an object of the (new) SystemSubset class.  A derived
> class SystemSubsetBySubdomain will exist, and users can write their
> own derived classes if they need.

That sounds great.

> No, we don't have such a function.  That is, at least in the way I thought of 
> this, solve_only_on() will make *all* successive calls to *any* of the 
> solve() methods restrict on the given subdomain.  Hence, there must be a 
> possibility to reset this functionality.  That's why I used a pointer.  We 
> can, if you like, also use a reference and instead use a different method 
> solve_everywhere(void) to reset this, but I find this less intuitive.

Ah, I see.  I don't find it intuitive to change the internal state
with a method named solve_only_on(); that sounded like it would have
no side effects.  Could we instead do:

restrict_solves_to();
solve();

It's one extra line of code for users, but this way it's clear that
the restriction call is making some state change and future solves
must be affected.
---
Roy

------------------------------------------------------------------------------
Start uncovering the many advantages of virtual appliances
and start using them to simplify application deployment and
accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev
_______________________________________________
Libmesh-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/libmesh-users

Reply via email to