Run solver independently in different subdomains

25 views
Skip to first unread message

Lucas Myers

unread,
Aug 24, 2022, 2:45:46 PM8/24/22
to deal.II User Group
Hi everyone,

I've got a diffusion-ish equation where I'd like to do the following:
  1. Partition my domain into n subdomains -- for concreteness, say the domain is a rectangle and my partitions are two (completely separated) circles along with the rest of the rectangle.
  2. Relax the system on each of the subdomains as if they were an isolated system (say, with pure Dirichlet or pure Neumann BCs).
  3. Eliminate the partitions and evolve the system altogether without any of the synthetically-imposed BCs.
As a first guess I suspect I can just mark each of the subdomains with a material_id or a user_index or something, and then only iterate over the cells from a particular subdomain during the assembly and solve normally. However, I am unsure how to mark the appropriate faces on the outside of the subdomains as boundary faces.

Has anyone dealt with this kind of problem before? Does it seem like this is the right direction to go? And how can I mark faces as belonging to a boundary, even if the cells are internal to the domain?

Any help is appreciated.

- Lucas

Wolfgang Bangerth

unread,
Aug 24, 2022, 3:58:42 PM8/24/22
to dea...@googlegroups.com
On 8/24/22 12:45, Lucas Myers wrote:
> As a first guess I suspect I can just mark each of the subdomains with a
> material_id or a user_index or something, and then only iterate over the
> cells from a particular subdomain during the assembly and solve
> normally. However, I am unsure how to mark the appropriate faces on the
> outside of the subdomains as boundary faces.
>
> Has anyone dealt with this kind of problem before? Does it seem like
> this is the right direction to go? And how can I mark faces as belonging
> to a boundary, even if the cells are internal to the domain?

The VectorTools::interpolate_boundary_values() function can't deal with
this, but it isn't very difficult to write your own replacement function
that simply loops over the faces of the cells that are part of a
subdomain, rather than the faces of the entire triangulation.

Best
W.


--
------------------------------------------------------------------------
Wolfgang Bangerth email: bang...@colostate.edu
www: http://www.math.colostate.edu/~bangerth/
Reply all
Reply to author
Forward
0 new messages