Commit f890d7ae authored by christian.rheinbay's avatar christian.rheinbay
Browse files

Merge branch '336-clear-for-vectors' into 'feature'

[336-clear-for-vectors] added vectors clear and fixed added one in Precon

Closes #336

See merge request !311
parents 007b86da 7f08ffc4
Pipeline #168391 passed with stages
in 23 minutes and 23 seconds
......@@ -858,7 +858,11 @@ std::vector<double> Vectors::norm() {
no[i] = V[i]->norm();
return no;
}
void Vectors::Clear() {
for (int i = 0; i<this->size(); ++i){
(*this)[i].Clear();
}
}
double Vectors::normScalar() {
return std::sqrt((*this) * (*this));
}
......
......@@ -383,6 +383,8 @@ public:
void Average();
void SetAccumulateFlags(bool flag);
void Clear();
};
inline Saver &operator<<(Saver &saver, const Vectors &u) { return u.save(saver); }
......
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