From: Wolfgang Bangerth Date: Thu, 4 Sep 2003 20:38:16 +0000 (+0000) Subject: Fix a bug where the FullMatrix::copy_from function could not be compiled. X-Git-Tag: v8.0.0~16251 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0a047c1b39b35f383ac7f51e2f7979872860dd7c;p=dealii.git Fix a bug where the FullMatrix::copy_from function could not be compiled. git-svn-id: https://svn.dealii.org/trunk@7959 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/doc/news/c-4-0.html b/deal.II/doc/news/c-4-0.html index 62a41d7d7e..9bd55268ae 100644 --- a/deal.II/doc/news/c-4-0.html +++ b/deal.II/doc/news/c-4-0.html @@ -135,13 +135,19 @@ contributor's names are abbreviated by WB (Wolfgang Bangerth), GK

lac

    +
  1. Fixed: FullMatrix::copy_from didn't compile when copying + from a sparse matrix. This is now fixed. +
    + (Ralf B. Schulz 2002/09/04) +

  2. New: The classes FullMatrix and - PreconditionBlockJacobi have a const_iterator. -
    - (GK 2003/07/18) -

    + PreconditionBlockJacobi have a const_iterator. +
    + (GK 2003/07/18) +

diff --git a/tests/bits/Makefile b/tests/bits/Makefile index 14562c8989..7be17ed8c3 100644 --- a/tests/bits/Makefile +++ b/tests/bits/Makefile @@ -29,6 +29,7 @@ anna_4.exe : anna_4.g.$(OBJEXT) $(libraries) anna_5.exe : anna_5.g.$(OBJEXT) $(libraries) anna_6.exe : anna_6.g.$(OBJEXT) $(libraries) geometry_info_1.exe : geometry_info_1.g.$(OBJEXT) $(libraries) +full_matrix_1.exe : full_matrix_1.g.$(OBJEXT) $(libraries) data_out_01.exe : data_out_01.g.$(OBJEXT) $(libraries) data_out_02.exe : data_out_02.g.$(OBJEXT) $(libraries) data_out_faces_01.exe : data_out_faces_01.g.$(OBJEXT) $(libraries) @@ -105,6 +106,7 @@ cylinder.exe : cylinder.g.$(OBJEXT) $(libraries) tests = anna_1 anna_2 anna_3 anna_4 anna_5 anna_6 \ geometry_info_1 point_inside_1 point_inside_2 \ + full_matrix_1 \ data_out_01 data_out_02 data_out_faces_01 data_out_faces_02 \ data_out_rotation_01 data_out_rotation_02 data_out_stack_01 \ dof_tools_00a \ diff --git a/tests/bits/full_matrix_1.cc b/tests/bits/full_matrix_1.cc new file mode 100644 index 0000000000..1c96fd25eb --- /dev/null +++ b/tests/bits/full_matrix_1.cc @@ -0,0 +1,54 @@ +//---------------------------- full_matrix_1.cc --------------------------- +// $Id$ +// Version: $Name$ +// +// Copyright (C) 2002, 2003 by the deal.II authors and Anna Schneebeli +// +// This file is subject to QPL and may not be distributed +// without copyright and license information. Please refer +// to the file deal.II/doc/license.html for the text and +// further information on this license. +// +//---------------------------- full_matrix_1.cc --------------------------- + + +// FullMatrix::copy_from could not be compiled if we copied from a +// sparse matrix. make sure this now works + +#include +#include +#include +#include + + +int main () +{ + std::ofstream logfile("full_matrix_1.output"); + deallog.attach(logfile); + deallog.depth_console(0); + + const unsigned int N = 4; + FullMatrix f(N,N); + + SparsityPattern s (N,N,N); + for (unsigned int i=0; i sm(s); + for (unsigned int i=0; i