In the step-3 example
(https://www.dealii.org/8.4.1/doxygen/deal.II/step_3.html), I noticed
that at first the variable phi is used as a test function. It is in the
same space with u, except for that the value is 0 on the boundaries. (in
this problem the boundary values for u is also 0, but it could be
non-zero for general cases)
However, later, the variable phi is also the shape function. I am lost
in this step in understanding why the test function could be the shape
function at the same time. For example, if the boundary conditions of u
is non-zero, we'd have to have a shape function to be non-zero at the
boundary (right?) but the test function space needs to be 0 on the boundary.
Your question shows a much deeper mathematical understanding of how
strong boundary conditions actually work than most of us actually have :-)
While you are correct that one can solve the problem as you suggest,
deal.II tries to separate the treatment of boundary conditions from the
treatment of assembly. We like to do things in such a way that we can do
the exact same thing on each cell during assembly, without having to
wonder whether some of the degrees of freedom are at the boundary. We
then only later modify the resulting linear system so that it reflects
the boundary conditions. You may want to watch lectures 21.6 and 21.65 here
http://www.math.colostate.edu/~bangerth/videos.html
where I discuss exactly these sorts of issues and how they are done
algorithmically.
Best
W.
--
------------------------------------------------------------------------
Wolfgang Bangerth email: [email protected]
www: http://www.math.colostate.edu/~bangerth/
--
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see
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 [email protected].
For more options, visit https://groups.google.com/d/optout.