hp and FE_Enriched

35 views
Skip to first unread message

Edith Sotelo

unread,
Oct 20, 2017, 2:06:39 AM10/20/17
to deal.II User Group
Hello,

I am trying to use different enrichment functions in different parts of my domain. For that I am also using hp::FECollection. 

The issue is that my solution looks discontinuous at the interface  when the  enrichment function changes. I am also attaching the pictures of the solution and the disconitnuous solution I get

This is part of the constructor. The rest of the code is similar to tutorials using hp collection


 for (unsigned int n = 0; n < q; ++n)

        {

// note: the erichment functions are cos but with different frequencies


          Enrichment<dim> enrich0(ko,n,q);

          Enrichment<dim> enrich1(k1,n,q);


          functions0.push_back([=] (const typename Triangulation<dim>::cell_iterator &) -> const Function<dim> * {return & enrich0;});

          //nullfunction.push_back(nullptr);


          functions1.push_back([=] (const typename Triangulation<dim>::cell_iterator &) -> const Function<dim> * {return & enrich1;});


         }


    FE_Q<dim> feq (1);


    //FE_Nothing<dim> feq_nothing(1,true);



    fe_collection.push_back( FE_Enriched<dim> ( &feq, { &feq}, {functions0})  );

    fe_collection.push_back(FE_Enriched<dim> ( &feq, { &feq}, {functions1}) );


right_solution.png
DiscontinuousSol.png

Denis Davydov

unread,
Oct 20, 2017, 4:23:33 AM10/20/17
to deal.II User Group
Hi Edith


On Friday, October 20, 2017 at 8:06:39 AM UTC+2, Edith Sotelo wrote:
Hello,

I am trying to use different enrichment functions in different parts of my domain. For that I am also using hp::FECollection. 

The issue is that my solution looks discontinuous at the interface  when the  enrichment function changes. I am also attaching the pictures of the solution and the disconitnuous

that's perfectly expected and there is nothing anyone could do about this. 
If you bring together two arbitrary enrichment functions, there is no way to make them continuous across some boundary/faces. 
If you have such scenario, you need to group enrichments on different "layers", i.e. combine with FE_Nothing with dominating flag. 
Say for scalar valued FE space In 1D:

|---- base element --- | --- base element --- | --- base element --- |
|---- enrichment1 ----  | --- enrichment 1 --   | --- FENothing     --- |
|---- FENothing ------  | ---- FE_Nothing --    | --- enrichment 2 --- | 

                                                                   ^^^ here's your interface.
What will happen is that DoFs on the interface of both enrichments will be constrainted to zero and you end up having a continuous FE space.

p.s. The whole cell-to-function part in FE_Enriched is **only** meant for disjoint domains, like:

|---- base element --- | --- base element --- | --- base element --- |
|---- enrichment1 ----  | --- FE_Nothing  --   | --- enrichment 2  --- |


Regards,
Denis.
Reply all
Reply to author
Forward
0 new messages