Hi Timo,

Thank you, that helped.

On 09.05.2012 19:10, Timo Heister wrote:
Hi Alexander,

try to use
"hanging_node_constraints.condense (c_sparsity); " before copy_from() instead.

On Wed, May 9, 2012 at 11:29 AM, Alexander Grayver
<[email protected]>  wrote:
Hello,

I'm trying to further work with CompressedSimpleSparsityPattern and I don't
understand how to avoid this error:

An error occurred in line<847>  of file
</usr/local/deal.II-dev/source/lac/constraint_matrix.cc>  in function
    void dealii::ConstraintMatrix::condense(dealii::SparsityPattern&) const
The violated condition was:
    sparsity.is_compressed() == false
The name and call sequence of the exception was:
    ExcMatrixIsClosed()

Because I need to take into account hanging nodes and want to use
CompressedSimpleSparsityPattern at the same time:

    CompressedSparsityPattern c_sparsity(dof_handler.n_dofs());
    DoFTools::make_sparsity_pattern (dof_handler, c_sparsity);
    sparsity_pattern.copy_from(c_sparsity);

    hanging_node_constraints.condense (sparsity_pattern);
    sparsity_pattern.compress();

What would be the way to do that?

Thanks.
--
Regards,
Alexander

_______________________________________________
dealii mailing list http://poisson.dealii.org/mailman/listinfo/dealii

Reply via email to