ffc team mailing list archive
-
ffc team
-
Mailing list archive
-
Message #00367
Re: [DOLFIN-dev] Dimension d in elasticity module
-
To:
Discussion of FFC development <ffc-dev@xxxxxxxxxx>
-
From:
Anders Logg <logg@xxxxxxxxx>
-
Date:
Fri, 7 Oct 2005 10:14:41 -0500
-
In-reply-to:
<1128697090.43468d02d3b3a@mech001.citg.tudelft.nl>
-
Mail-followup-to:
Discussion of FFC development <ffc-dev@xxxxxxxxxx>
-
User-agent:
Mutt/1.5.11
On Fri, Oct 07, 2005 at 04:58:10PM +0200, Garth N. Wells wrote:
> Knowing the tensor rank and dimension of each field of a mixed formulation would
> be useful for extracting "subfunctions".
You can access the list of elements that compose a mixed element
through the member variable elements:
e0 = FiniteElement(...)
e1 = FiniteElement(...)
element = e0 + e1
rank_0 = element.elements[0].rank()
rank_1 = element.elements[1].rank()
But maybe you mean that you need this is information to be included in
the generated code so it can be accessed in DOLFIN? We could do that,
and it would make it possible to implement some more advanced
functionality for the Function class in DOLFIN, like slicing out
subfunctions:
Function w(...);
Function u(w, 0, 2); // Components 0-1
Function p(w, 2); // Component 2
/Anders
Follow ups