Loading...
Searching...
No Matches
none.hpp
Go to the documentation of this file.
1#pragma once
2
3/**
4 * NoPreconditioner — the identity, used when preconditioning is disabled.
5 *
6 * Exists so that "no preconditioning" is an object like any other rather than
7 * an empty-container sentinel the mixers have to test for. Every mixer holds a
8 * preconditioner and calls it unconditionally.
9 */
10
11#include <string>
12#include <vector>
13
15
16namespace q3 {
17
18/// Identity preconditioner: leaves the residual untouched.
20 public:
21 [[nodiscard]] std::string name() const override {
22 return "none";
23 }
24
25 void apply(std::vector<Complex>& /*residual_g*/) const override {}
26};
27
28} // namespace q3
Identity preconditioner: leaves the residual untouched.
Definition none.hpp:19
void apply(std::vector< Complex > &) const override
Definition none.hpp:25
std::string name() const override
Definition none.hpp:21
Abstract base class for all SCF residual preconditioners.
Definition init.hpp:26