Reference documentation for deal.II version 8.5.1
trilinos_parallel_block_vector.cc
1 // ---------------------------------------------------------------------
2 //
3 // Copyright (C) 2015 by the deal.II authors
4 //
5 // This file is part of the deal.II library.
6 //
7 // The deal.II library is free software; you can use it, redistribute
8 // it, and/or modify it under the terms of the GNU Lesser General
9 // Public License as published by the Free Software Foundation; either
10 // version 2.1 of the License, or (at your option) any later version.
11 // The full text of the license can be found in the file LICENSE at
12 // the top level of the deal.II distribution.
13 //
14 // ---------------------------------------------------------------------
15 
16 
17 #include <deal.II/lac/trilinos_parallel_block_vector.h>
18 
19 #ifdef DEAL_II_WITH_TRILINOS
20 
21 DEAL_II_NAMESPACE_OPEN
22 
23 namespace TrilinosWrappers
24 {
25  namespace MPI
26  {
27  BlockVector::BlockVector (const std::vector<Epetra_Map> &parallel_partitioning)
28  {
29  reinit (parallel_partitioning, false);
30  }
31 
32 
33 
34  bool
36  {
37  bool compressed = true;
38  for (unsigned int row=0; row<n_blocks(); ++row)
39  if (block(row).is_compressed() == false)
40  {
41  compressed = false;
42  break;
43  }
44 
45  return compressed;
46  }
47  }
48 }
49 
50 DEAL_II_NAMESPACE_CLOSE
51 
52 #endif // DEAL_II_WITH_TRILINOS
void reinit(const std::vector< Epetra_Map > &parallel_partitioning, const bool omit_zeroing_entries=false) 1
unsigned int n_blocks() const
BlockType & block(const unsigned int i)