On 04/15/2018 07:30 PM, Jaekwang Kim wrote:
and I think I should add this cell_matrix(i,j) and cell_rhs(i) to my system
matrix.
Yes.
but not overlapping the rows that describe weakform of original poisson
equation.. so I think i should not use them...
for (unsigned int i=0; i<dofs_per_cell; ++i)
{
for (unsigned int j=0; j<dofs_per_cell; ++j)
system_matrix.add (local_dof_indices[i],
local_dof_indices[j],
cell_matrix(i,j));
system_rhs(local_dof_indices[i]) += cell_rhs(i);
}
In this situation, how should I expand (to add rows) my system matrix and
connect to it boundary dof ?
No. These are just regular DoFs like all others that you have enumerated.
There is definitely no need to expand the size of the system.
I don't think that your boundary conditions are any different than the Neumann
conditions that we treat in one of the earlier tutorial programs (step-7?).
Your just happen to be Robin boundary conditions. Take a look at how this is
done there, and maybe also consider the video lectures on boundary conditions.
I'll point out that in your code snippet where you assemble the boundary
contributions, you need to make sure that the `fe_values` object you use there
is really an FE*Face*Values.
Best
W.
--
------------------------------------------------------------------------
Wolfgang Bangerth email: bange...@colostate.edu
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 dealii+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.