Robust way of setting an affine constraint on a single point

24 views
Skip to first unread message

blais...@gmail.com

unread,
Jun 22, 2021, 5:12:09 PM6/22/21
to deal.II User Group
Dear all,
I hope you are well.

This is most likely a very simple question, but what would be a good way to robustly set an AffineConstraint not on a face, but on a single DOF, while making sure that it is not an hanging node. I'd like to do something equivalent to what is done by VectorTools::interpolate_boundary_values but for an a priori unknown DOF (it could be for example the first non-hanging node DOF or something similar).

This is to set the reference value for a Laplace problem with Neumann Bcs. I know there are alternative ways which are better (such as constraining the zero mean), but this is for a quick test.

Thank you very much :)!
Bruno


Wolfgang Bangerth

unread,
Jun 22, 2021, 6:04:42 PM6/22/21
to dea...@googlegroups.com
On 6/22/21 3:12 PM, blais...@gmail.com wrote:
>
> This is most likely a very simple question, but what would be a good way to
> robustly set an AffineConstraint not on a face, but on a single DOF, while
> making sure that it is not an hanging node. I'd like to do something
> equivalent to what is done by VectorTools::interpolate_boundary_values but for
> an a priori unknown DOF (it could be for example the first non-hanging node
> DOF or something similar).

As so often, there is precedent for this kind of thing in ASPECT :-)

https://github.com/geodynamics/aspect/blob/master/source/simulator/nullspace.cc#L112-L209


Best
W.

--
------------------------------------------------------------------------
Wolfgang Bangerth email: bang...@colostate.edu
www: http://www.math.colostate.edu/~bangerth/

blais...@gmail.com

unread,
Jun 23, 2021, 7:58:51 AM6/23/21
to deal.II User Group
Thank you Wolfgang, this is exactly what I needed :)
Best
Bruno

Reply all
Reply to author
Forward
0 new messages