A struct which stores the information for the initial input matrix of SMG2S. More...
#include <initMat.hpp>
Public Member Functions | |
initMat () | |
A constructor of struct `initMat`. More... | |
initMat (S diagl, S diagu) | |
A constructor of struct `initMat`. More... | |
initMat (S diagl, S diagu, double Sparsity) | |
A constructor of struct `initMat`. More... | |
initMat (S diagl, S diagu, double Scale, double Sparsity) | |
A constructor of struct `initMat`. More... | |
void | show () |
A member function of struct `initMat` to display all its variables. More... | |
Public Attributes | |
S | diag_l |
S | diag_u |
double | scale |
double | sparsity |
A struct which stores the information for the initial input matrix of SMG2S.
This struct defines a initial input matrix by the offset of lower diagonal `diag_l` and upper diagonal `diag_u`. The entries between diagonal `diag_l` and `diag_u` of lower-triangular part of initial matrix are set randomly with (0, 1). These entries can be modified by `scale`. The `sparsity` determines the possibility of the entries of initial matrix to be `0`.
S | type of integer to describes the dimension of matrices to be generated. |
A constructor of struct `initMat`.
This is a constructor of struct `initMat`, in which the variables are set with default values: `diag_l=-3`, `diag_u=-2`, `scale=1.0` and `sparsity=0.9`.
A constructor of struct `initMat`.
This is a constructor of struct `initMat` with default values `scale=1.0` and `sparsity=0.9`.
[in] | diagl | Offset of lower diagonal |
[in] | diagu | Offset of upper diagonal |
A constructor of struct `initMat`.
This is a constructor of struct `initMat` with default value `scale=1.0`.
[in] | diagl | Offset of lower diagonal |
[in] | diagu | Offset of upper diagonal |
[in] | Sparsity | Possibility of the entries of initial matrix to be `0` |
|
inline |
A constructor of struct `initMat`.
This is a constructor of struct `initMat` without any default values.
[in] | diagl | Offset of lower diagonal |
[in] | diagu | Offset of upper diagonal |
[in] | Scale | Number can be multiplied on the randomly generated entries of initial matrix |
[in] | Sparsity | Possibility of the entries of initial matrix to be `0` |
|
inline |
A member function of struct `initMat` to display all its variables.
This is a member function of struct `initMat` to display all its variables.
S initMat< S >::diag_l |
Offset of lower diagonal
S initMat< S >::diag_u |
Offset of upper diagonal
double initMat< S >::scale |
Number can be multiplied on the randomly generated entries of initial matrix
double initMat< S >::sparsity |
Possibility of the entries of initial matrix to be `0`