Replacement of MixedFunctionSpace

#1

I wonder if MixedFunctionSpace based on submeshes can still be supported in some way. I tried import from UFL and define Function on that but it fails.

#2

MixedFunctionSpace is for now deprecated, in favor of FunctionSpace built from a MixedElement.
As an example :

V = FiniteElement("CG", mesh.ufl_cell(), 2)
Q = FiniteElement("CG", mesh.ufl_cell(), 1)
VQ = FunctionSpace(mesh, MixedElement(V, Q))
1 Like
#3

@cdaversin Thanks for the attention. The real problem is how to define functionspace on submeshes. MixedFunctionSpace allowed one to do that before.

#4

Indeed, using MixedElement implies the function spaces to be defined on the same (sub)mesh.
We are working on a new version of MixedFunctionSpace allowing to define product of function spaces from various submeshes, which can eventually have different topological dimensions.
This feature will be available soon, in a next release.
In the meanwhile you can give a try to the development version using the Docker image : https://hub.docker.com/r/ceciledc/fenics_mixed_dimensional

1 Like
#5

@cdaversin Cool. Could you let me know how to keep updated on new releases?

#6

New releases are advertised on the FEniCS website https://fenicsproject.org/download/

#7

Does MixedElement work with, say, three spaces V,Q and X? I mean this

VQX = FunctionSpace(mesh, MixedElement(V,Q,X))

#8

I gave the docker version a try. It seems that there are still bugs like _repr or _cpp_object is missing for some classes. What is the estimated release cycle?

#9

Yes. They need to be defined on the same mesh. Put them in a list: MixedElement([V, Q, X])

1 Like