Hi all,
I modelling multiphase flow and I want to simulate the propagating
interface separating two fluids. During the reinitialization step I want
to impose the condition that for the nodes within a tolerance from the
interface the solution does not change i.e. I know its value. I tried
doing it by using the ConstraintMatrix class but for the moment it does
not work so I was thinking of ruling out possibilities. Here is my
implemenation and, as always, my questions

 for(unsigned int i = 0; i<reinit_dof_handler.n_dofs(); ++i)
        {

       ///if the solution within tolerance add line, add entry set the
value you want
         if(fabs(
old_reinitialization_solution(i)<=3.0*GridTools::maximal_cell_diameter(t
riangulation)/2.0)
         {

            reinitialization_constraints.add_line(i);

          ///a matrix with one column
            reinitialization_constraints.add_entry(i,0, 0.0 );
        
reinitialization_constraints.set_inhomogeneity(i,old_reinitialization_so
lution(i));
         }      
        }

  reinitialization_constraints.close(); 

And  then in the assemble function after looping all cells

 
reinitialization_constraints.condense(reinitialization_system_matrix,rei
nitialization_system_rhs);

For the moment this approach does not seem to be doing what I meant to
do, although I need to look into that more thoroughly. So my questions
are

The third argument in the add_entry()  function it is meant to be the
alpha in the equation x[i]= sum(alpha[i][j]x[i][j])+b[i] as this is
given in the doc of the relevant class?

My constraints are of the form x[i]=b[i] so I understand that I will
have a column matrix with as many lines as constraints?

Do I have to use the relevant VectorTools::interpolate_boundary_values
to enforce the inhomogeneity in the constraint?

Thank you for your patience :)
All the best
Alex
 
This message has been checked for viruses but the contents of an attachment
may still contain software viruses which could damage your computer system:
you are advised to perform your own checks. Email communications with the
University of Nottingham may be monitored as permitted by UK legislation.
_______________________________________________
dealii mailing list http://poisson.dealii.org/mailman/listinfo/dealii

Reply via email to