imate
C++/CUDA Reference
Loading...
Searching...
No Matches
cu_csr_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 _CU_LINEAR_OPERATOR_CU_CSR_AFFINE_MATRIX_FUNCTION_H_
13#define _CU_LINEAR_OPERATOR_CU_CSR_AFFINE_MATRIX_FUNCTION_H_
14
15
16// =======
17// Headers
18// =======
19
20#include "../_definitions/types.h" // FlagType, LongIndexType
21#include "./cu_csr_matrix.h" // cuCSRMatrix
22#include "./cu_affine_matrix_function.h" // cuAffineMatrixFunction
23
24
25// =============================
26// cu CSR Affine Matrix Function
27// =============================
28
43
44template <typename DataType>
46{
47 public:
48
49 // Member methods
51 const DataType* A_data_,
52 const LongIndexType* A_indices_,
53 const LongIndexType* A_index_pointer_,
54 const LongIndexType num_rows_,
55 const LongIndexType num_columns_,
56 const FlagType A_is_symmetric_,
57 const int num_gpu_devices_);
58
60 const DataType* A_data_,
61 const LongIndexType* A_indices_,
62 const LongIndexType* A_index_pointer_,
63 const LongIndexType num_rows_,
64 const LongIndexType num_columns_,
65 const FlagType A_is_symmetric_,
66 const DataType* B_data_,
67 const LongIndexType* B_indices_,
68 const LongIndexType* B_index_pointer_,
69 const FlagType B_is_symmetric_,
70 const int num_gpu_devices_);
71
73
74 virtual void set_symmetry(const FlagType symmetric);
75
76 virtual void dot(
77 const DataType* vector,
78 DataType* product);
79
80 virtual void transpose_dot(
81 const DataType* vector,
82 DataType* product);
83
84 protected:
85
86 // Member data
89};
90
91#endif // _CU_LINEAR_OPERATOR_CU_CSR_AFFINE_MATRIX_FUNCTION_H_
Base class for affine matrix functions of one parameter.
Container for CSR affine matrix functions of one parameter.
virtual void set_symmetry(const FlagType symmetric)
Specify whether the matrices are symmetic or non-symmetric.
virtual void dot(const DataType *vector, DataType *product)
Matrix vector product.
virtual void transpose_dot(const DataType *vector, DataType *product)
Matrix vector product written in place.
Container for CSR matrices.
int LongIndexType
Definition types.h:60
int FlagType
Definition types.h:68