← Back to team overview

dolfin team mailing list archive

Second thoughts on DofMap in Function

 

On Wed, Dec 06, 2006 at 11:39:44PM +0100, Garth N. Wells wrote:
> Anders Logg wrote:
> > Do you mean "DofMap associated with mesh and finite element"?
> >
> 
> Yep.
> 
> > I'm ok with that. We could have a DiscreteFunction with two members:
> > 
> >     Vector
> >     DofMap
> > 
> 
> That would work.

On second thought, I'm not sure this would work. The current class
FiniteElement has a few other functions than what is accomplished by
the DofMap. We have the value type for the function space (scalar,
vector, tensor) and we have evaluation at vertices with vertexeval()
which is used for output at vertices. So just the DofMap is not
enough.

I know the DofMap has a FiniteElement that can be accessed, but the
FiniteElement is more central. The DofMap is just a way to reorder the
dofs for efficiency.

How about letting

    Function = (vector, mesh, element, dofmap = 0)

so that the dofmap is optional (the pointer migth be 0). If it is
nonzero, the implementation must look at the dofmap when it does
interpolation.

?

/Anders


Follow ups

References