]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Merge from mainline.
authorBruno Turcksin <bruno.turcksin@gmail.com>
Mon, 25 Mar 2013 14:11:54 +0000 (14:11 +0000)
committerBruno Turcksin <bruno.turcksin@gmail.com>
Mon, 25 Mar 2013 14:11:54 +0000 (14:11 +0000)
git-svn-id: https://svn.dealii.org/branches/branch_bigger_global_dof_indices_4@29024 0785d39b-7218-0410-832d-ea1e28bc413d

1  2 
deal.II/examples/step-17/step-17.cc
deal.II/examples/step-36/step-36.cc
deal.II/examples/step-42/step-42.cc
deal.II/include/deal.II/base/index_set.h
deal.II/include/deal.II/lac/petsc_matrix_base.h
deal.II/include/deal.II/lac/slepc_solver.h
deal.II/source/lac/petsc_sparse_matrix.cc
deal.II/source/lac/slepc_solver.cc
deal.II/source/lac/trilinos_sparse_matrix.cc

Simple merge
Simple merge
Simple merge
index 587e440e8030489944a25ca46437d1d438ac2b53,c0cf5a1ddd3cc471d464501aa60cec30e0176bf2..9a4a09006c9e6d0cf4ba05a3d562be2e1b742aa2
@@@ -244,9 -244,19 +244,19 @@@ public
     * index set with the interval, shifted
     * to the range <tt>[0,
     * end-begin)</tt>.
+    *
+    * In other words, the result of this operation is the
+    * intersection of the set represented by the current object
+    * and the interval <tt>[begin, end)</tt>, as seen
+    * <i>within the interval <tt>[begin, end)</tt></i> by
+    * shifting the result of the intersection operation to
+    * the left by <tt>begin</tt>. This corresponds to the notion
+    * of a <i>view</i>: The interval <tt>[begin, end)</tt> is
+    * a <i>window</i> through which we see the set represented
+    * by the current object.
     */
 -  IndexSet get_view (const unsigned int begin,
 -                     const unsigned int end) const;
 +  IndexSet get_view (const types::global_dof_index begin,
 +                     const types::global_dof_index end) const;
  
  
    /**
index a76a1ba299f3ea8c58976b58eb23f87d75551ec8,1f955323813880c5a39885ac71cdff9411f749aa..c843c90ebfde291d5d84202a07bc0acca8c5e12d
@@@ -641,9 -654,12 +658,12 @@@ namespace SLEPcWrapper
    SolverBase::solve (const PETScWrappers::MatrixBase &A,
                       std::vector<double>             &kr,
                       std::vector<OutputVector>       &vr,
 -                     const unsigned int               n_eigenvectors = 1)
 +                     const size_type                  n_eigenvectors = 1)
    {
 -    unsigned int n_converged = 0;
+     // Panic if no eigenpairs are wanted.
+     AssertThrow (n_eigenvectors != 0, ExcSLEPcWrappersUsageError());
 +    size_type n_converged = 0;
  
      // Set the matrices of the problem
      set_matrices (A);
                       const PETScWrappers::MatrixBase &B,
                       std::vector<double>             &kr,
                       std::vector<OutputVector>       &vr,
 -                     const unsigned int               n_eigenvectors = 1)
 +                     const size_type                  n_eigenvectors = 1)
    {
 -    unsigned int n_converged = 0;
+     // Panic if no eigenpairs are wanted.
+     AssertThrow (n_eigenvectors != 0, ExcSLEPcWrappersUsageError());
 +    size_type n_converged = 0;
  
      // Set the matrices of the problem
      set_matrices (A, B);
index 65ee384621d33abccebebb2de7dd29fc6396b102,e77038d6cd50ba45ac1eb37061d4f44ef86f72e5..d1a747ec91639be0b39da31ef165be03c58813ea
@@@ -250,26 -247,17 +247,16 @@@ namespace PETScWrapper
      // class.
      if (preset_nonzero_locations == true)
        {
- #ifdef PETSC_USE_64BIT_INDICES
-         std::vector<PetscInt>
- #else
-         std::vector<int>
- #endif
-         row_entries;
+         std::vector<PetscInt>    row_entries;
          std::vector<PetscScalar> row_values;
 -
 -        for (unsigned int i=0; i<sparsity_pattern.n_rows(); ++i)
 +        for (size_type i=0; i<sparsity_pattern.n_rows(); ++i)
            {
              row_entries.resize (row_lengths[i]);
              row_values.resize (row_lengths[i], 0.0);
 -            for (unsigned int j=0; j<row_lengths[i]; ++j)
 +            for (size_type j=0; j<row_lengths[i]; ++j)
                row_entries[j] = sparsity_pattern.column_number (i,j);
  
- #ifdef PETSC_USE_64BIT_INDICES
-             const PetscInt
- #else
-             const int
- #endif
-             int_row = i;
+             const PetscInt int_row = i;
              MatSetValues (matrix, 1, &int_row,
                            row_lengths[i], &row_entries[0],
                            &row_values[0], INSERT_VALUES);
Simple merge
index 391e7ae9edcadce9eb5b9b4e1c9110c472c4fa6b,29030f6e47a829181a452c3b99585eb601d964d8..d90ad93733c20796993df3350754d4f4ded43304
@@@ -426,11 -426,11 +426,11 @@@ namespace TrilinosWrapper
  
      column_space_map.reset (new Epetra_Map (input_col_map));
  
-     const size_t first_row = input_row_map.MinMyGID(),
 -    const unsigned int first_row = input_row_map.MinMyGID(),
++    const size_type first_row = input_row_map.MinMyGID(),
                         last_row = input_row_map.MaxMyGID()+1;
 -    std::vector<int> n_entries_per_row(last_row-first_row);
 +    std::vector<TrilinosWrappers::types::int_type> n_entries_per_row(last_row-first_row);
  
 -    for (unsigned int row=first_row; row<last_row; ++row)
 +    for (size_type row=first_row; row<last_row; ++row)
        n_entries_per_row[row-first_row] = sparsity_pattern.row_length(row);
  
      // The deal.II notation of a Sparsity pattern corresponds to the Epetra

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.