imate
C++/CUDA Reference
Loading...
Searching...
No Matches
c_affine_matrix_function.h
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: Copyright 2021, Siavash Ameli <sameli@berkeley.edu>
3 * SPDX-License-Identifier: BSD-3-Clause
4 * SPDX-FileType: SOURCE
5 *
6 * This program is free software: you can redistribute it and/or modify it
7 * under the terms of the license found in the LICENSE.txt file in the root
8 * directory of this source tree.
9 */
10
11
12#ifndef _C_LINEAR_OPERATOR_C_AFFINE_MATRIX_FUNCTION_H_
13#define _C_LINEAR_OPERATOR_C_AFFINE_MATRIX_FUNCTION_H_
14
15
16// =======
17// Headers
18// =======
19
20#include "../_definitions/types.h" // LongIndexType
21#include "./c_linear_operator.h" // cLinearOperator
22
23
24// ========================
25// c Affine Matrix Function
26// ========================
27
53
54template <typename DataType>
55class cAffineMatrixFunction : public cLinearOperator<DataType>
56{
57 public:
58
59 // Member methods
61
62 virtual ~cAffineMatrixFunction();
63
64 virtual void set_symmetry(FlagType symmetric) = 0;
65
66 DataType get_eigenvalue(
67 const DataType* known_parameters,
68 const DataType known_eigenvalue,
69 const DataType* inquiry_parameters) const;
70
71 protected:
72
73 // Member methods
75 const DataType* input_vector,
76 const LongIndexType vector_size,
77 const DataType scale,
78 DataType* output_vector) const;
79
80 // Member data
82};
83
84
85#endif // _C_LINEAR_OPERATOR_C_AFFINE_MATRIX_FUNCTION_H_
Base class for affine matrix functions of one parameter.
void _add_scaled_vector(const DataType *input_vector, const LongIndexType vector_size, const DataType scale, DataType *output_vector) const
Performs the operation , where is an input vector scaled by and it the output vector.
virtual ~cAffineMatrixFunction()
Virtual destructor.
DataType get_eigenvalue(const DataType *known_parameters, const DataType known_eigenvalue, const DataType *inquiry_parameters) const
This function defines an analytic relationship between a given set of parameters and the correspondin...
virtual void set_symmetry(FlagType symmetric)=0
Base class for linear operators. This class serves as interface for all derived classes.
int LongIndexType
Definition types.h:60
int FlagType
Definition types.h:68