FEInterfaceValues and hp::FECollection

92 views
Skip to first unread message

Marco Feder

unread,
Aug 8, 2022, 6:58:17 PM8/8/22
to deal.II User Group
Dear all,

I'm using an hp::FECollection object to describe different FE spaces in my grid. In particular, I'm in the following scenario:

x- - - - - -x
|             |
|     0      | 
|             |
x - - F - -x 
|             |
|     1      | 
|             |
x- - - - - -x

On cell number 0 I have a FESystem with FE_Q(1) and FE_Q(1), which corresponds to fe_collection[0].
On cell number 1, I have again a FESystem with FE_Q(1) and FE_Nothing, corresponding to fe_collection[1].

I need to compute the jump [d_n u_h]_F, being F the face shared by the two cells. Unfortunately, I can't find a proper way to initialize FEInterfaceValues so that it understands that I need the jump of the first components only. Indeed, if I use fe_collection[0] (or fe_collection[1]) as first argument in the constructor, I have a runtime error in reinit(cell) saying (as expected):

    The FiniteElement you provided to FEValues and the FiniteElement that
    belongs to the DoFHandler that provided the cell iterator do not
    match.


since we have different spaces on cell0 and cell1. Is there a possible workaround to this?

Best,
Marco

Simon Sticko

unread,
Aug 9, 2022, 11:59:11 AM8/9/22
to dea...@googlegroups.com
Hi,

Unfortunately no-one has implemented FEInterfaceValues for hp yet (I think it would be great if someone did). The only workaround I know is to NOT use FEInterfaceValues and instead:

1. Use 2 hp::FEFaceValues objects, one initialized with cell 0 and one initialized with cell 1.

2. Split the jump term in 4 terms: [u][v] = u_0*v_0 - u0*v_1 - u_1*v_0 + u_1*v_1

3. Assemble each term in a separate local matrix (A_00, A_01, A_10, A_11), where

A_01 - Rows correspond to local dofs on cell 0, columns to local dofs on cell 1.

4. Use global_dof_indices of cell 0 and cell 1 to map each local matrix to the global matrix.

Best,
Simon



On 09/08/2022 00:58, Marco Feder wrote:
> Dear all,
>
> I'm using an hp::FECollection object to describe different FE spaces in my grid. In particular, I'm in the following scenario:
>
> x- - - - - -x
> |             |
> |     0      |
> |             |
> x - - F - -x
> |             |
> |     1      |
> |             |
> x- - - - - -x
>
> On cell number 0 I have a FESystem with FE_Q(1) and FE_Q(1), which corresponds to fe_collection[0].
> On cell number 1, I have again a FESystem with FE_Q(1) and FE_Nothing, corresponding to fe_collection[1].
>
> I need to compute the jump [d_n u_h]_F, being F the face shared by the two cells. Unfortunately, I can't find a proper way to initialize FEInterfaceValues so that it understands that I need the jump of the first components only. Indeed, if I use fe_collection[0] (or fe_collection[1]) as first argument in the constructor, I have a runtime error in reinit(cell) saying (as expected):
>
> /    The FiniteElement you provided to FEValues and the FiniteElement that
>     belongs to the DoFHandler that provided the cell iterator do not
>     match./
> /
> /
> since we have different spaces on cell0 and cell1. Is there a possible workaround to this?
>
> Best,
> Marco
>
> --
> The deal.II project is located at http://www.dealii.org/ <http://www.dealii.org/>
> For mailing list/forum options, see https://groups.google.com/d/forum/dealii?hl=en <https://groups.google.com/d/forum/dealii?hl=en>
> ---
> You received this message because you are subscribed to the Google Groups "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to dealii+un...@googlegroups.com <mailto:dealii+un...@googlegroups.com>.
> To view this discussion on the web visit https://groups.google.com/d/msgid/dealii/2d71b802-132c-4f8a-a20d-03542939036an%40googlegroups.com <https://groups.google.com/d/msgid/dealii/2d71b802-132c-4f8a-a20d-03542939036an%40googlegroups.com?utm_medium=email&utm_source=footer>.

Marco Feder

unread,
Aug 18, 2022, 5:01:53 AM8/18/22
to dea...@googlegroups.com
Thanks Simon,

As you might suspect, I was using your step-85 to solve an interface problem also in the “outside” region with cutFEM, and  “hardcoding" the jump terms like in DG as you suggested finally solved the issue. Sorry for the late reply. 

Best, 
Marco

--- You received this message because you are subscribed to a topic in the Google Groups "deal.II User Group" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/dealii/4nmXUhsSNfc/unsubscribe.
To unsubscribe from this group and all its topics, send an email to dealii+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/dealii/23e81ebd-cf4e-60ad-ea66-ad825581b533%40gmail.com.
Reply all
Reply to author
Forward
0 new messages