ginkgo/core/factorization/cholesky.hpp Source File

ginkgo/core/factorization/cholesky.hpp Source File#

Reference API: ginkgo/core/factorization/cholesky.hpp Source File
Reference API
cholesky.hpp
1// SPDX-FileCopyrightText: 2017 - 2025 The Ginkgo authors
2//
3// SPDX-License-Identifier: BSD-3-Clause
4
5#include <memory>
6
7#include <ginkgo/core/base/composition.hpp>
8#include <ginkgo/core/base/lin_op.hpp>
9#include <ginkgo/core/base/polymorphic_object.hpp>
10#include <ginkgo/core/config/config.hpp>
11#include <ginkgo/core/config/registry.hpp>
12#include <ginkgo/core/factorization/factorization.hpp>
13#include <ginkgo/core/matrix/csr.hpp>
14#include <ginkgo/core/matrix/sparsity_csr.hpp>
15
16
17namespace gko {
18namespace experimental {
19namespace factorization {
20
21
36template <typename ValueType, typename IndexType>
38 : public EnablePolymorphicObject<Cholesky<ValueType, IndexType>,
39 LinOpFactory>,
40 public EnablePolymorphicAssignment<Cholesky<ValueType, IndexType>> {
41public:
42 struct parameters_type;
45
46 using value_type = ValueType;
47 using index_type = IndexType;
51
53 : public enable_parameters_type<parameters_type, Cholesky> {
60 std::shared_ptr<const sparsity_pattern_type>
62
74 };
75
81 const parameters_type& get_parameters() { return parameters_; }
82
86 const parameters_type& get_parameters() const { return parameters_; }
87
95 std::unique_ptr<factorization_type> generate(
96 std::shared_ptr<const LinOp> system_matrix) const;
97
99 static parameters_type build() { return {}; }
100
115 const config::pnode& config, const config::registry& context,
116 const config::type_descriptor& td_for_child =
117 config::make_type_descriptor<ValueType, IndexType>());
118
119protected:
120 explicit Cholesky(std::shared_ptr<const Executor> exec,
121 const parameters_type& params = {});
122
123 std::unique_ptr<LinOp> generate_impl(
124 std::shared_ptr<const LinOp> system_matrix) const override;
125
126private:
127 parameters_type parameters_;
128};
129
130
131} // namespace factorization
132} // namespace experimental
133} // namespace gko
Definition polymorphic_object.hpp:743
Definition polymorphic_object.hpp:668
Definition lin_op.hpp:385
Definition property_tree.hpp:28
Definition registry.hpp:167
Definition type_descriptor.hpp:39
Definition abstract_factory.hpp:211
static parameters_type build()
Definition cholesky.hpp:99
const parameters_type & get_parameters() const
Definition cholesky.hpp:86
const parameters_type & get_parameters()
Definition cholesky.hpp:81
std::unique_ptr< factorization_type > generate(std::shared_ptr< const LinOp > system_matrix) const
static parameters_type parse(const config::pnode &config, const config::registry &context, const config::type_descriptor &td_for_child=config::make_type_descriptor< ValueType, IndexType >())
Definition csr.hpp:123
Definition sparsity_csr.hpp:55
#define GKO_FACTORY_PARAMETER_SCALAR(_name, _default)
Definition abstract_factory.hpp:445
The Ginkgo namespace.
Definition abstract_factory.hpp:20
std::shared_ptr< const sparsity_pattern_type > symbolic_factorization
Definition cholesky.hpp:61