Skip to content
Snippets Groups Projects
Commit 80f4558b authored by Markus Blatt's avatar Markus Blatt
Browse files

used an ugly const_cast to recalculate Galerkin product.

[[Imported from SVN: r2771]]
parent 516cc0a6
No related branches found
No related tags found
No related merge requests found
......@@ -554,10 +554,10 @@ namespace Dune
GalerkinProduct productBuilder;
for(Iterator level = matrices_.finest(), coarsest=matrices_.coarsest(); level!=coarsest; ++amap) {
Matrix& fine = level->matrix();
const Matrix& fine = level->matrix();
++level;
Matrix& coarse = level->matrix();
productBuilder.calculate(fine, *(*amap), coarse);
//Matrix& coarse(level->matrix());
productBuilder.calculate(fine, *(*amap), const_cast<Matrix&>(level->matrix()));
}
}
......
......@@ -40,16 +40,15 @@ namespace Dune
* @brief Get the locally stored matrix.
* @return The locally stored matrix.
*/
const Matrix& matrix()
const Matrix& matrix() const
{
return *matrix_;
}
/**
* @brief Get the index set that maps global indices to matrix rows.
* @return The index set.
*/
const IndexSet& indexSet()
const IndexSet& indexSet() const
{
return *indices_;
}
......@@ -58,7 +57,7 @@ namespace Dune
* @brief Get the information about remote indices also present locally.
* @return The remote index information.
*/
const RemoteIndices& remoteIndices()
const RemoteIndices& remoteIndices() const
{
return *rIndices_;
}
......
......@@ -41,6 +41,9 @@ int main(int argc, char** argv)
hierarchy.build(criterion);
hierarchy.recalculateGalerkin();
MPI_Finalize();
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment