Attention une mise à jour du service Gitlab va être effectuée le mardi 14 décembre entre 13h30 et 14h00. Cette mise à jour va générer une interruption du service dont nous ne maîtrisons pas complètement la durée mais qui ne devrait pas excéder quelques minutes.

Commit a69d4b0f authored by GILLES Sebastien's avatar GILLES Sebastien
Browse files

#1053 Operator FromVertexMatching: keep the matrix pattern in storage.

parent 59aa117c
......@@ -134,7 +134,10 @@ namespace HappyHeart
}));
Wrappers::Petsc::MatrixPattern matrix_pattern(non_zero_pattern_per_line);
matrix_pattern_ = std::make_unique<Wrappers::Petsc::MatrixPattern>(non_zero_pattern_per_line);
decltype(auto) matrix_pattern = GetMatrixPattern();
auto& interpolation_matrix = *interpolation_matrix_;
const auto& mpi = source.GetFEltSpace().MpiHappyHeart();
......
......@@ -134,6 +134,14 @@ namespace HappyHeart
//! Access to interpolation matrix.
const GlobalMatrix& GetInterpolationMatrix() const noexcept;
/*!
* \brief Pattern of the matrix.
*
* \note It is stored for the sake of tests; otherwise it could be dropped once the interpolation
* matrix is created/
*/
const Wrappers::Petsc::MatrixPattern& GetMatrixPattern() const noexcept;
private:
......@@ -152,6 +160,14 @@ namespace HappyHeart
//! Global matrix used for the interpolation.
GlobalMatrix::unique_ptr interpolation_matrix_ = nullptr;
/*!
* \brief Pattern of the matrix.
*
* \note It is stored for the sake of tests; otherwise it could be dropped once the interpolation
* matrix is created/
*/
Wrappers::Petsc::MatrixPattern::const_unique_ptr matrix_pattern_ = nullptr;
};
......
......@@ -38,6 +38,13 @@ namespace HappyHeart
assert(!(!interpolation_matrix_));
return *interpolation_matrix_;
}
inline const Wrappers::Petsc::MatrixPattern& FromVertexMatching::GetMatrixPattern() const noexcept
{
assert(!(!matrix_pattern_));
return *matrix_pattern_;
}
} // namespace NonConformInterpolatorNS
......
......@@ -118,8 +118,6 @@ namespace HappyHeart
//! jCSR part of the CSR pattern (see iCSR_ for more details).
std::vector<PetscInt> jCSR_;
};
} // namespace Petsc
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment