| STARS-H
    Software for Testing Accuracy, Reliability and  Scalability of Hierarchical computations | 
Synthetic random TLR matrix routines. More...
| Data Structures | |
| struct | starsh_randtlr | 
| Structure for synthetic TLR matrices.  More... | |
| Typedefs | |
| typedef struct starsh_randtlr | STARSH_randtlr | 
| Structure for synthetic TLR matrices. | |
| Enumerations | |
| enum | STARSH_RANDTLR_KERNEL { STARSH_RANDTLR_KERNEL1 = 1 } | 
| List of built-in kernels for starsh_randtlr_get_kernel().  More... | |
| enum | STARSH_RANDTLR_PARAM { STARSH_RANDTLR_NB = 1, STARSH_RANDTLR_DECAY = 2, STARSH_RANDTLR_DIAG = 3 } | 
| List of parameters for starsh_application().  More... | |
| Functions | |
| void | starsh_randtlr_block_kernel (int nrows, int ncols, STARSH_int *irow, STARSH_int *icol, void *row_data, void *col_data, void *result, int ld) | 
| The only kernel for STARSH_randtlr object.  More... | |
| int | starsh_randtlr_generate (STARSH_randtlr **data, STARSH_int count, STARSH_int block_size, double decay, double diag) | 
| Generate STARSH_randtlr object for random TLR matrix.  More... | |
| int | starsh_randtlr_generate_va (STARSH_randtlr **data, STARSH_int count, va_list args) | 
| Generate STARSH_randtlr object with incomplete set of parameters.  More... | |
| int | starsh_randtlr_generate_el (STARSH_randtlr **data, STARSH_int count,...) | 
| Generate STARSH_randtlr object with incomplete set of parameters.  More... | |
| int | starsh_randtlr_get_kernel (STARSH_kernel **kernel, STARSH_randtlr *data, enum STARSH_RANDTLR_KERNEL type) | 
| Get kernel for spatial statistics problem.  More... | |
| void | starsh_randtlr_free (STARSH_randtlr *data) | 
| Free memory of STARSH_randtlr object.  More... | |
Synthetic random TLR matrix routines.
STARSH_randtlr is about generation of TLR matrix in a special form. Each tile is generated as a multiplication of 3 matrices: \( U_i \), \( S \) and \( U_j \), where \( i \) and \( j \) are row and column indexes of some orthogonal matrix \( U \) and \( S \) is a diagonal matrix.
List of built-in kernels for starsh_randtlr_get_kernel().
There is only one kernel right now, this structure is to support future methods to generate synthetic matrices.
| Enumerator | |
|---|---|
| STARSH_RANDTLR_KERNEL1 | The only kernel. | 
| enum STARSH_RANDTLR_PARAM | 
List of parameters for starsh_application().
In the table below each constant correspond to a given argument and type for starsh_randtlr_generate(). These constants are used to generate problem with incomplete set of parameters via starsh_application(), starsh_randtlr_generate_va() or starsh_randtlr_generate_el().
| Enumerator | |
|---|---|
| STARSH_RANDTLR_NB | Size of tiles. | 
| STARSH_RANDTLR_DECAY | Decay of singular values, first singular value is 1.0. | 
| STARSH_RANDTLR_DIAG | Value to add to diagonal elements. | 
| void starsh_randtlr_block_kernel | ( | int | nrows, | 
| int | ncols, | ||
| STARSH_int * | irow, | ||
| STARSH_int * | icol, | ||
| void * | row_data, | ||
| void * | col_data, | ||
| void * | result, | ||
| int | ld | ||
| ) | 
The only kernel for STARSH_randtlr object.
| [in] | nrows | Number of rows of \( A \). | 
| [in] | ncols | Number of columns of \( A \). | 
| [in] | irow | Array of row indexes. | 
| [in] | icol | Array of column indexes. | 
| [in] | row_data | Pointer to physical data (STARSH_randtlr object). | 
| [in] | col_data | Pointer to physical data (STARSH_randtlr object). | 
| [out] | result | Pointer to memory of \( A \). | 
| [in] | ld | Leading dimension of result. | 
| void starsh_randtlr_free | ( | STARSH_randtlr * | data | ) | 
Free memory of STARSH_randtlr object.
| int starsh_randtlr_generate | ( | STARSH_randtlr ** | data, | 
| STARSH_int | count, | ||
| STARSH_int | block_size, | ||
| double | decay, | ||
| double | diag | ||
| ) | 
Generate STARSH_randtlr object for random TLR matrix.
| [out] | data | Address of pointer to STARSH_randtlr object. | 
| [in] | count | Size of matrix. | 
| [in] | block_size | Size of each tile. | 
| [in] | decay | Decay of singular values, first value is 1.0. | 
| [in] | diag | Value to add to each diagonal element. | 
| int starsh_randtlr_generate_el | ( | STARSH_randtlr ** | data, | 
| STARSH_int | count, | ||
| ... | |||
| ) | 
Generate STARSH_randtlr object with incomplete set of parameters.
Parses possibly incomplete set of parameters for starsh_randtlr_generate(). If argument is not in the ..., then its default value is used:
| Argument | Default value | Type – | 
|---|---|---|
| block_size | count | STARSH_int | 
| decay | 0.0 | double | 
| diag | 0.0 | double | 
List of arguments ... should look as pairs (Arg.constant, Value) with 0 as a last argument. For correspondance of arguments and arg.constants take a look at STARSH_RANDTLR_PARAM.
| [out] | data | Address of pointer to STARSH_randtlr object. | 
| [in] | count | Size of matrix. | 
| [in] | ... | Variable amount of arguments. | 
| int starsh_randtlr_generate_va | ( | STARSH_randtlr ** | data, | 
| STARSH_int | count, | ||
| va_list | args | ||
| ) | 
Generate STARSH_randtlr object with incomplete set of parameters.
Parse possibly incomplete set of parameters for starsh_randtlr_generate(). If argument is not in the args, then its default value is used:
| Argument | Default value | Type – | 
|---|---|---|
| block_size | count | STARSH_int | 
| decay | 0.0 | double | 
| diag | 0.0 | double | 
List of arguments args should look as pairs (Arg.constant, Value) with 0 as a last argument. For correspondance of arguments and arg.constants take a look at STARSH_RANDTLR_PARAM.
| [out] | data | Address of pointer to STARSH_randtlr object. | 
| [in] | count | Size of matrix. | 
| [in] | args | Arguments, packed into va_args. | 
| int starsh_randtlr_get_kernel | ( | STARSH_kernel ** | kernel, | 
| STARSH_randtlr * | data, | ||
| enum STARSH_RANDTLR_KERNEL | type | ||
| ) | 
Get kernel for spatial statistics problem.
Kernel can be selected with this call or manually. Currently, there is only one kernel for STARSH_randtlr problem.
| [out] | kernel | Address of pointer to STARSH_kernel function. | 
| [in] | data | Pointer to STARSH_randtlr object. | 
| [in] | type | Type of kernel. For more info look at STARSH_RANDTLR_KERNEL. |