Commit 48bb3924 authored by Praetorius, Simon's avatar Praetorius, Simon
Browse files

Cached type of ProblemStat::getSolutionVector() from shared_ptr to reference

parent 18c95e67
...@@ -78,8 +78,8 @@ int main(int argc, char** argv) ...@@ -78,8 +78,8 @@ int main(int argc, char** argv)
// write matrix to file // write matrix to file
mtl::io::matrix_market_ostream out("matrix_stokes0.mtx"); mtl::io::matrix_market_ostream out("matrix_stokes0.mtx");
out << prob.getSystemMatrix()->getMatrix(); out << prob.getSystemMatrix().getMatrix();
std::cout << prob.getSystemMatrix()->getMatrix() << '\n'; std::cout << prob.getSystemMatrix().getMatrix() << '\n';
prob.solve(adaptInfo); prob.solve(adaptInfo);
......
...@@ -79,8 +79,8 @@ int main(int argc, char** argv) ...@@ -79,8 +79,8 @@ int main(int argc, char** argv)
// write matrix to file // write matrix to file
mtl::io::matrix_market_ostream out("matrix_stokes1.mtx"); mtl::io::matrix_market_ostream out("matrix_stokes1.mtx");
out << prob.getSystemMatrix()->getMatrix(); out << prob.getSystemMatrix().getMatrix();
std::cout << prob.getSystemMatrix()->getMatrix() << '\n'; std::cout << prob.getSystemMatrix().getMatrix() << '\n';
prob.solve(adaptInfo); prob.solve(adaptInfo);
......
...@@ -41,9 +41,9 @@ int main(int argc, char** argv) ...@@ -41,9 +41,9 @@ int main(int argc, char** argv)
// write matrix to file // write matrix to file
if (Parameters::get<int>("elliptMesh->global refinements").value_or(0) < 4) { if (Parameters::get<int>("elliptMesh->global refinements").value_or(0) < 4) {
mtl::io::matrix_market_ostream out("matrix.mtx"); mtl::io::matrix_market_ostream out("matrix.mtx");
out << prob.getSystemMatrix()->getMatrix(); out << prob.getSystemMatrix().getMatrix();
std::cout << prob.getSystemMatrix()->getMatrix() << '\n'; std::cout << prob.getSystemMatrix().getMatrix() << '\n';
} }
prob.solve(adaptInfo); prob.solve(adaptInfo);
......
...@@ -53,7 +53,7 @@ template <class Traits> ...@@ -53,7 +53,7 @@ template <class Traits>
void ProblemInstat<Traits>::initTimestep(AdaptInfo&) void ProblemInstat<Traits>::initTimestep(AdaptInfo&)
{ {
if (oldSolution) if (oldSolution)
oldSolution->copy(*problemStat.getSolutionVector()); oldSolution->copy(problemStat.getSolutionVector());
} }
} // end namespace AMDiS } // end namespace AMDiS
Supports Markdown
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