]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Include <iostream> where necessary.
authorWolfgang Bangerth <bangerth@math.tamu.edu>
Sun, 27 Jan 2002 08:44:04 +0000 (08:44 +0000)
committerWolfgang Bangerth <bangerth@math.tamu.edu>
Sun, 27 Jan 2002 08:44:04 +0000 (08:44 +0000)
git-svn-id: https://svn.dealii.org/trunk@5422 0785d39b-7218-0410-832d-ea1e28bc413d

27 files changed:
deal.II/examples/step-10/step-10.cc
deal.II/examples/step-11/step-11.cc
deal.II/examples/step-12/step-12.cc
deal.II/examples/step-3/step-3.cc
deal.II/examples/step-4/step-4.cc
deal.II/examples/step-5/step-5.cc
deal.II/examples/step-6/step-6.cc
deal.II/examples/step-7/step-7.cc
deal.II/examples/step-8/step-8.cc
deal.II/examples/step-9/step-9.cc
tests/base/logtest.cc
tests/base/reference.cc
tests/base/tensor.cc
tests/base/timer.cc
tests/deal.II/grid_transform.cc
tests/deal.II/subdomain_ids.cc
tests/lac/block_matrices.cc
tests/lac/block_vector.cc
tests/lac/block_vector_iterator.cc
tests/lac/full_matrix.cc
tests/lac/matrix_out.cc
tests/lac/mg.cc
tests/lac/mgbase.cc
tests/lac/solver.cc
tests/lac/sparse_ilu.cc
tests/lac/sparsity_pattern.cc
tests/lac/vector-vector.cc

index 1d3f033c9ba892f6aac29091781fe8711d5310bd..2c0cdfed75e46aaa5d3a30599e724941d12eac7a 100644 (file)
@@ -35,6 +35,7 @@
 #include <fe/mapping_q.h>
 
                                 // And this again is C++:
+#include <iostream>
 #include <fstream>
 #include <cmath>
 
index c9eb4f20f5d48aaa9b3b49bc4e62623288366c2b..537467b6c2185251e665c1ecf2b1eedac6f0b906 100644 (file)
@@ -52,6 +52,7 @@
                                 // following file for its
                                 // declaration:
 #include <algorithm>
+#include <iostream>
 #include <iomanip>
 #include <cmath>
 
index 13c9de0e72e41865a67a0da293d29f67fbd14f75..b757801ff4252fa1064863c7d9a5f6737ef24dc1 100644 (file)
@@ -67,6 +67,7 @@
 #include <base/timer.h>
 
                                 // And this again is C++:
+#include <iostream>
 #include <fstream>
 
 
index 893fe897d86d3e55c5f4cb85d981635992305bba..9417d670cebfa721de82aadbee92c47d6702fbad 100644 (file)
 #include <lac/precondition.h>
 
                                 // Finally, this is for output to a
-                                // file.
+                                // file and to the console:
 #include <numerics/data_out.h>
 #include <fstream>
+#include <iostream>
 
 
                                 // Instead of the procedural
index bb4f71ac934d13b4ac9ad4803dc8202d0622a20c..9293fc08987f78338580f49272f6ddb45cc7b923 100644 (file)
@@ -38,6 +38,7 @@
 
 #include <numerics/data_out.h>
 #include <fstream>
+#include <iostream>
 
                                 // This is new, however: in the
                                 // previous example we got some
index 91ef76fd63092efc48a020ee29f2924a53b72818..ebbf6f3f1e103e6442e37879c4c9eb79242d3519 100644 (file)
@@ -50,8 +50,8 @@
 #include <fstream>
                                 // ... and this is too: We will
                                 // convert integers to strings using
-                                // the the C++ stringstream class
-                                // ``ostringstream''. One slight
+                                // the C++ stringstream class
+                                // ``ostringstream''. One annoying
                                 // complication arises here in that
                                 // the classes ``std::istringstream''
                                 // and ``std::ostringstream'' (with
@@ -62,7 +62,7 @@
                                 // around the time the C++ standard
                                 // was made in 1999. For example, the
                                 // gcc compiler up to and including
-                                // version 2.95.x did not have them,
+                                // version 2.95.2 did not have them,
                                 // but instead provided classes
                                 // ``istrstream'' and ``ostrstream''
                                 // with a similar, but nevertheless
@@ -793,11 +793,11 @@ void LaplaceProblem<dim>::output_results (const unsigned int cycle) const
                                   // run time using an input file.
 
                                   // Finally, we need the filename to
-                                  // which the results is to be
+                                  // which the results are to be
                                   // written. We would like to have
                                   // it of the form
                                   // ``solution-N.eps'', where N is
-                                  // the number of refinement
+                                  // the number of the refinement
                                   // cycle. Thus, we have to convert
                                   // an integer to a part of a
                                   // string; this can be done using
@@ -806,12 +806,13 @@ void LaplaceProblem<dim>::output_results (const unsigned int cycle) const
                                   // write everything into a special
                                   // stream (just like writing into a
                                   // file or to the screen) and
-                                  // retrieve that as a string. This
-                                  // applies the usual conversions
-                                  // from integer to strings, and one
-                                  // could as well give stream
-                                  // modifiers such as ``setf'',
-                                  // ``setprecision'', and so on.
+                                  // retrieve what you wrote as a
+                                  // string. This applies the usual
+                                  // conversions from integer to
+                                  // strings, and one could as well
+                                  // give stream modifiers such as
+                                  // ``setw'', ``setprecision'', and
+                                  // so on.
                                   //
                                   // In C++, you can do this by using
                                   // the so-called stringstream
@@ -836,11 +837,11 @@ void LaplaceProblem<dim>::output_results (const unsigned int cycle) const
                                   // the two classes which we might
                                   // now be using, depending on which
                                   // one is available, is close
-                                  // enough that we need not take
-                                  // care about the differences any
-                                  // more, so we can use them in a
-                                  // straightforward way, even if
-                                  // they are not identical.
+                                  // enough that we need to take care
+                                  // about the differences only once
+                                  // below, so we can use them in a
+                                  // rather straightforward way, even
+                                  // if they are not identical.
 
                                   // In order to now actually
                                   // generate a filename, we fill the
@@ -858,13 +859,15 @@ void LaplaceProblem<dim>::output_results (const unsigned int cycle) const
   
                                   // We can get whatever we wrote to
                                   // the stream using the ``str()''
-                                  // function. If the new stringstream
-                                   // classes are used, then the result is
-                                   // a string which we have to convert to
-                                   // a char* using the ``c_str()''
-                                   // function, otherwise the result is a
-                                   // char* right away.  Use that as filename
-                                  // for the output stream:
+                                  // function. If the new
+                                  // stringstream classes are used,
+                                  // then the result is a string
+                                  // which we have to convert to a
+                                  // char* using the ``c_str()''
+                                  // function, otherwise the result
+                                  // is a char* right away. Use that
+                                  // as filename for the output
+                                  // stream:
 #ifdef HAVE_STD_STRINGSTREAM
   std::ofstream output (filename.str().c_str());
 #else
index b0daa315ee39feb1245729a890bbfbc7324d5e59..bcfa77fb09d80b1ad41581c889b979c8c0e9d22b 100644 (file)
@@ -88,6 +88,7 @@
 #include <numerics/error_estimator.h>
 
 #include <fstream>
+#include <iostream>
 
 
                                 // The main class is again almost
index ee9ac38b67e31667696114e2fc0270d1d0fdc58a..2a119ec194296e43b7b0d5ba97bcc900b8704d67 100644 (file)
@@ -81,6 +81,7 @@
                                 // slightly more detail below.
 #include <typeinfo>
 #include <fstream>
+#include <iostream>
 
 
                                 // @sect3{Equation data}
index d5f0a1092f2546dfa7d76f76ba05ad8f5ccfb93d..37fdaf6c9a7ca29b1a9abf8034019ac8598f550f 100644 (file)
@@ -52,6 +52,7 @@
 
                                 // This again is C++:
 #include <fstream>
+#include <iostream>
 
 
                                 // The main class is, except for its
index 68efbfab795771fa8c658501613ce8e9366c87e5..4fd06faddc8b5051238a3f2aca0e8c9af9b11d5e 100644 (file)
@@ -77,6 +77,7 @@
                                 // This is C++, as we want to write
                                 // some output to disk:
 #include <fstream>
+#include <iostream>
 
 
 
index 73d9a04f0b4c7d31d3d08e450cae7deaeeb2393f..a43a6ab098b6878b37747b4ab416d03d1c4a0595 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 1998, 1999, 2000, 2001 by the deal.II authors
+//    Copyright (C) 1998, 1999, 2000, 2001, 2002 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -14,6 +14,7 @@
 
 #include <base/logstream.h>
 #include <fstream>
+#include <iostream>
 
 
 int main()
index 1b54a605a58bccd6c479aea590cbb0cd1e1e865d..f131b7e798bf8581353f034afe542516a9641a24 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 1998, 1999, 2000, 2001 by the deal.II authors
+//    Copyright (C) 1998, 1999, 2000, 2001, 2002 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -16,6 +16,7 @@
 #include <base/subscriptor.h>
 #include <base/smartpointer.h>
 #include <base/logstream.h>
+#include <iostream>
 
 
 class Test : public Subscriptor
index 80ea42b3bfa2212fa5c045e26391aeaf38d687ef..f0f7a137e1ed3081f719d935865fb1b68065e4ef 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 1998, 1999, 2000, 2001 by the deal.II authors
+//    Copyright (C) 1998, 1999, 2000, 2001, 2002 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -16,7 +16,7 @@
 #include <base/logstream.h>
 #include <lac/vector.h>
 #include <fstream>
-
+#include <iostream>
 
 int main ()
 {
index 3ed423716ddb1e12865f06ab71ff63e0b99cc5ec..55a1a6a0e981bb8d7030fb447e339eeae7a42b06 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 1998, 1999, 2000, 2001 by the deal.II authors
+//    Copyright (C) 1998, 1999, 2000, 2001, 2002 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -16,6 +16,7 @@
 #include <base/logstream.h>
 #include <fstream>
 #include <cmath>
+#include <iostream>
 
 // compute the ratio of two measurements and compare to
 // the expected value.
index f6207cefaa82ef6b6a18d84e81d91537a586e8b1..b069b6ca65b5761f90bbef66d07fcac0568850aa 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 1998, 1999, 2000, 2001 by the deal.II authors
+//    Copyright (C) 1998, 1999, 2000, 2001, 2002 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -22,6 +22,7 @@
 #include <fe/mapping_q.h>
 
 #include <fstream>
+#include <iostream>
 
 
 int main ()
index 08345f23bd59674e872f182b8c09e348b25a7468..a1d22da953c41505584650a69d51a7a3182bc7e7 100644 (file)
@@ -164,7 +164,7 @@ void test ()
                  ExcNumberMismatch(std::count (selected_dofs.begin(),
                                                selected_dofs.end(),
                                                true),
-                                   pow(cells_per_direction/2+1,dim)));
+                                   (int)pow(cells_per_direction/2+1,dim)));
        }
       deallog << "Check 4 (dim=" << dim << ") ok" << std::endl;      
     };
index 6813863354451609f3f565038c9923e61c961e87..d2f37933bac75dde6ee8968b7c71cb5971b7f006 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 2000, 2001 by the deal.II authors
+//    Copyright (C) 2000, 2001, 2002 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -17,6 +17,7 @@
 #include <lac/block_sparse_matrix.h>
 #include <lac/block_vector.h>
 #include <fstream>
+#include <iostream>
 #include <algorithm>
 
 
index 9820b91173ec079d12aa7ebbc9d84062de089c55..5dd982fe4246071014ca1c5282e7787a74f27ac9 100644 (file)
@@ -17,6 +17,7 @@
 #include <lac/block_sparse_matrix.h>
 #include <lac/block_vector.h>
 #include <fstream>
+#include <iostream>
 #include <vector>
 #include <list>
 
index fbde0466919c092d35c5d66461a67ec6ac4fb84e..3f0b5dbe6ed014152ddf6d867bde94ced54e92a0 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 2000, 2001 by the deal.II authors
+//    Copyright (C) 2000, 2001, 2002 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -15,6 +15,7 @@
 #include <base/logstream.h>
 #include <lac/block_vector.h>
 #include <fstream>
+#include <iostream>
 #include <vector>
 #include <algorithm>
 #include <numeric>
index f7a3e25c9d9f4187568b1b9e3419cdc45075e9e7..f859e5783d153fa3de3e0ec40188dad83aac755a 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 1998, 1999, 2000, 2001 by the deal.II authors
+//    Copyright (C) 1998, 1999, 2000, 2001, 2002 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -14,6 +14,7 @@
 
 #include <cmath>
 #include <fstream>
+#include <iostream>
 #include <iomanip>
 #include <cstdlib>
 
index c3d556f7559d69905e4549c5e7a40460c08e60d1..2e76b0f4b25fbf2f658448758e0d508bdfb28caa 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 2001 by the deal.II authors
+//    Copyright (C) 2001, 2002 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -16,6 +16,7 @@
 #include <lac/matrix_out.h>
 #include <lac/full_matrix.h>
 #include <fstream>
+#include <iostream>
 
 int main () 
 {
index 8e68395c6741e2b1cb5361efbff27c5b9694e47a..444407ec745a9a7c4eda0b43149477bb7f99540c 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 1998, 1999, 2000 by the deal.II authors
+//    Copyright (C) 1998, 1999, 2000, 2002 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -14,6 +14,7 @@
 
 #include <cmath>
 #include <fstream>
+#include <iostream>
 #include "testmatrix.h"
 #include <base/logstream.h>
 #include <lac/sparse_matrix.h>
index aa6756b5ddab95a77a87e46d0ceda16ad84d96a2..1397403493a9634b192dea4d16293ba68500c4ab 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 1998, 1999, 2000 by the deal.II authors
+//    Copyright (C) 1998, 1999, 2000, 2002 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -17,6 +17,7 @@
 #include <base/logstream.h>
 
 #include <fstream>
+#include <iostream>
 
 class TransferTest
   :
index 84ef074e844a7876f2307d6650ff6a71a89bb0fe..9d6597563fea2e720024a1cde650b60131720663 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 1998, 1999, 2000, 2001 by the deal.II authors
+//    Copyright (C) 1998, 1999, 2000, 2001, 2002 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -14,6 +14,7 @@
 
 #include <cmath>
 #include <fstream>
+#include <iostream>
 #include <iomanip>
 #include "testmatrix.h"
 #include <base/logstream.h>
index fb29d2d17679945a9177833c37463d5be4d0e1bb..723ec0743bc89f0eda8b24d4ff64644ad2ffef4a 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 2001 by the deal.II authors
+//    Copyright (C) 2001, 2002 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -17,6 +17,7 @@
 
 #include <cmath>
 #include <fstream>
+#include <iostream>
 #include <iomanip>
 #include <cstdlib>
 #include "testmatrix.h"
index 0eae668de2ef8e9b6f9d1eba4369cdb043dd3e5e..023540907b1b295bb870c0f30f8d454f98edf4b3 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 2001 by the deal.II authors
+//    Copyright (C) 2001, 2002 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -16,6 +16,7 @@
 #include <lac/sparsity_pattern.h>
 #include "testmatrix.h"
 #include <fstream>
+#include <iostream>
 #include <list>
 #include <set>
 
index d37aed418d312b1737fa61a80016461f5f08fada..534e2068f4b4fcfa468a6d9c5bb73c2a96d0dc0a 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 1998, 1999, 2000, 2001 by the deal.II authors
+//    Copyright (C) 1998, 1999, 2000, 2001, 2002 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -16,6 +16,7 @@
 #include <lac/vector.h>
 #include <cmath>
 #include <fstream>
+#include <iostream>
 
 
 

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.