With the minimum functionality going for vector-valued elements, I wanted
to start moving on adding support to FEMContext and FEMSystem. The main
issue is the path I want to follow will break backward compatibility, so I
wanted to discuss here first.
As was briefly mentioned in an earlier devel-thread (here:
http://sourceforge.net/mailarchive/message.php?msg_id=29247370), there are
two ways I can see moving forward on this:
1. Add data structures to stash the different finite element types
2. Move to storing FEAbstract* and down cast to the right type when needed
I'm really not a fan of the former (even though it would preserve backward
compatibility, I think) because, among other reasons, it will not scale
well as new types get added (e.g. tensor elements).
Moving to FEAbstract* will automatically break backward compatibility since
a down cast will be needed. Talking to Roy briefly, he opined that accessor
methods were long overdue for this and this would be a good time to add
For interior_value, etc., the plan is to add (replace? If we're breaking
compatibility anyway, why have duplicate code sitting around?) templated
void FEMContext::interior_value( unsigned int var, unsigned int qp,
FieldType& value )
If we're going to be going down the road of breaking backward compatibility
and adding accessor methods, what about protecting elem_solution,
I'd like to start on this right away, so my plan is to add the necessary
protected element_fe data structures and populate it with FEAbstract* and
still populate the public data structures (for the time being) to shake
things out while we hash out plans here.
On Sat, Jun 23, 2012 at 1:38 AM, Paul T. Bauman <ptbauman@...> wrote:
> Attached is a patch that has started along this road. There are now FE
> accessor methods, protected FEAbstract* data structures for FE types, a
> couple of template methods, and a working vector_fe_ex2 using FEMSystem on
> the uncoupled Laplace example from vector_fe_ex1. Roy mentioned briefly
> today that he would be in favor of me going accessor happy. What's the plan
> for backward compatiblity then? Or rather how long do we want to hold on to
I've added an updated patch here:
It adds initial support to ConstrainDirichlet for vector-valued elements.
C1 support is not complete yet (nor do I have any elements with which to
test it). I've updated the new vector_fe_ex2 to exercise this capability
and, in particular, made it 3-D to try and hit the side and edge
constraints. Seems to be working.