← Back to team overview

dolfin team mailing list archive

Re: assembly on sub domains

 

On Thursday 08 May 2008, Anders Logg wrote:
> On Thu, May 08, 2008 at 11:33:49AM +0100, Nuno David Lopes wrote:
> > But then what is the difference between
> > a MeshFunction for interior and exterior face_domains?
> > Shouldn't they be the same only with different markers for the boundary
> > and for the interior?
> >
> > MeshFunction<unsigned int> facets_subdomains(mesh, mesh.topology().dim()
> > - 1); (it has the information for all the facets, doesn't it?)
>
> Yes it does.
>
> > Is the problem in the order of the markers:
> > 0...n-1 in the exterior
> > 0...n-1 in the interior
> >
> > If we dont need the interior could we use the same MeshFunction, knowing
> > that the interior is marked with 0?
>
> Are you talking about the facets in the interior? Those are not
> included when integrating *ds terms anyway.

Exactly. If I understood it well, only if you have *dS terms you need the 
information for the interior facets.
But that information is in the same MeshFunction as for exterior facets. 

>
> For the cells in the interior, you need to have a MeshFunction defined
> on the cells, so something like
>
>   MeshFunction<unsigned int> cell_domains(mesh, mesh.topology().dim());


Ok thats clear form me. 
For a 3D mesh:  
Cells information are in   Meshfunction cell_domains(mesh,'3') 
Facets information are in a MeshFunction facets_domains(mesh,'2')

And still if you want to use: "assemble" you need 3 MeshFunctions:

assemble(A,a,mesh, cell_domains,int_facet_domains,ext_facets_domains)
                               ^MeshF 1^      ^^MeshF 2^^          ^^MeshF3^^

I really don't understand the difference between MeshF 2 and MeshF 3?
And if they are different how to construct them. 
(That's why I've referred the order of the markers, since that seems important 
for  FFC)
 
  
-- 
Nuno David Lopes


Follow ups

References