Dear Marek,

Let's first look at the two distribute_local_to_global calls:

constraint_matrix_phase_constant.distribute_local_to_global(local_matrix,
            dof_indices, system_matrix_phase_constant);

constraint_matrix_phase.distribute_local_to_global(local_matrix,
local_vector, dof_indices, jacobian_phase, residuum_phase);

I think that the problem is in the way you put together the entries for the constant part. When you assemble a single matrix, you most likely take the approach you use for 'jacobian_phase' with constraint_matrix_phase. Thus, in order to arrive at the same final system matrix, you need to use the same constraint matrix in both cases. The math behind this: In case of homogeneous constraints, the distribute_local_to_global method is a linear operation, so if the final local matrix is a sum of the two local matrices, you can equally well sum the two matrices.

So my assumption would be that the constraint_matrix_phase_constant object has different constraints than the other. This cannot work.

I assume you have different entries because you have some inhomogeneities on the latter which cannot be handled in the first call. I recommend to re-formulate the equations such that you only have homogeneous constraints, which then allows you to use the same constraint matrix on both parts of the matrix. This typically results in some additional right hand side terms including the left hand side terms.

Best,
Martin

--
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.

Reply via email to