ginkgo/core/solver/batch_cg.hpp Source File

ginkgo/core/solver/batch_cg.hpp Source File#

Reference API: ginkgo/core/solver/batch_cg.hpp Source File
Reference API
batch_cg.hpp
1// SPDX-FileCopyrightText: 2017 - 2025 The Ginkgo authors
2//
3// SPDX-License-Identifier: BSD-3-Clause
4
5#ifndef GKO_PUBLIC_CORE_SOLVER_BATCH_CG_HPP_
6#define GKO_PUBLIC_CORE_SOLVER_BATCH_CG_HPP_
7
8
9#include <vector>
10
11#include <ginkgo/core/base/batch_lin_op.hpp>
12#include <ginkgo/core/base/batch_multi_vector.hpp>
13#include <ginkgo/core/base/exception_helpers.hpp>
14#include <ginkgo/core/base/lin_op.hpp>
15#include <ginkgo/core/base/types.hpp>
16#include <ginkgo/core/solver/batch_solver_base.hpp>
17#include <ginkgo/core/stop/batch_stop_enum.hpp>
18
19
20namespace gko {
21namespace batch {
22namespace solver {
23
24
48template <typename ValueType = default_precision>
49class Cg final : public EnableBatchSolver<Cg<ValueType>, ValueType> {
50 friend class EnableBatchLinOp<Cg>;
52
53public:
54 using value_type = ValueType;
55 using real_type = gko::remove_complex<ValueType>;
56
57 class Factory;
58
64
65private:
66 explicit Cg(std::shared_ptr<const Executor> exec);
67
68 explicit Cg(const Factory* factory,
69 std::shared_ptr<const BatchLinOp> system_matrix);
70
71 void solver_apply(
73 log::detail::log_data<real_type>* log_data) const override;
74};
75
76
77} // namespace solver
78} // namespace batch
79} // namespace gko
80
81
82#endif // GKO_PUBLIC_CORE_SOLVER_BATCH_CG_HPP_
Definition polymorphic_object.hpp:668
Definition batch_lin_op.hpp:59
Definition batch_lin_op.hpp:252
Definition batch_multi_vector.hpp:59
Definition batch_cg.hpp:62
Definition batch_cg.hpp:49
Definition batch_solver_base.hpp:206
#define GKO_ENABLE_BATCH_LIN_OP_FACTORY(_batch_lin_op, _parameters_name, _factory_name)
Definition batch_lin_op.hpp:358
#define GKO_ENABLE_BUILD_METHOD(_factory_name)
Definition abstract_factory.hpp:394
The Ginkgo namespace.
Definition abstract_factory.hpp:20
typename detail::remove_complex_s< T >::type remove_complex
Definition math.hpp:260
Definition batch_cg.hpp:61