> Absolutely, the FENothing approach seems like a great fix. If you
> could send me any pointers, that would be great. I will start looking
> at the implementation of similar classes.

Essentially, what you would have to do is something along the following lines, 
in a first step:

  template <int dim>
  class FENothing : public FiniteElement<dim> {
    FENothing () 
                 :
                 call base class constructor with arguments that
                 indicate that this element has no dofs whatsoever {}

    virtual double shape_value (const unsigned int  i,
                                const Point<dim>   &p) const
    {
      Assert (false, ExcMessage ("This element has no shape functions"));
      return 0;
    }

    // do the same with pretty much all virtual functions that need to be
    // implemented; just go through the list of functions that the
    // FiniteElement class has.
  };

Then try out what happens if you create an hp::FECollection with the element 
you currently use and the FENothing, create an hp::DoFHandler, and do what 
you are currently doing to set up your linear system. You may want to read 
through step-27 to see how to do all these parts.

Once you've got this part done, we'll have to worry about the interplay with 
the FEValues class, but you may not even have to do that if you never call a 
hp::FEValues::reinit function on a cell with this FE.
    
Let me know if you hit a snag and I'll try to help out!

Best
 W.


-------------------------------------------------------------------------
Wolfgang Bangerth                email:            [email protected]
                                 www: http://www.math.tamu.edu/~bangerth/

_______________________________________________
dealii mailing list http://poisson.dealii.org/mailman/listinfo/dealii

Reply via email to