|
STARS-H
Software for Testing Accuracy, Reliability and Scalability of Hierarchical computations
|
Cauchy example. More...
Typedefs | |
| typedef STARSH_particles | STARSH_cauchy |
Functions | |
| void | starsh_cauchy_block_kernel (int nrows, int ncols, STARSH_int *irow, STARSH_int *icol, void *row_data, void *col_data, void *result, int ld) |
| The Cauchy kernel for STARSH_cauchy object. More... | |
| int | starsh_cauchy_init (STARSH_cauchy **data, STARSH_int count, double *point) |
| Create container for Cauchy example. More... | |
| int | starsh_cauchy_new (STARSH_cauchy **data, STARSH_int count, double *point, double *diag) |
| Create container for Cauchy example. More... | |
| int | starsh_cauchy_new_va (STARSH_cauchy **data, STARSH_int count, va_list args) |
| Generate STARSH_cauchy object by incomplete set of parameters. More... | |
| int | starsh_cauchy_new_el (STARSH_cauchy **data, STARSH_int count,...) |
| Generate STARSH_cauchy object by incomplete set of parameters. More... | |
| void | starsh_cauchy_free (STARSH_cauchy *data) |
| int | starsh_cauchy_get_kernel (STARSH_kernel **kernel, STARSH_cauchy *data, enum STARSH_CAUCHY_KERNEL type) |
| Get kernel for minimal working example. More... | |
Cauchy example.
Uses STARSH_particles structure to hold locations of points (1-dimensional) and values for diagonal elements of corresponding matrix.
| typedef STARSH_particles STARSH_cauchy |
Cauchy problem reuses structure for particles.
| void starsh_cauchy_block_kernel | ( | int | nrows, |
| int | ncols, | ||
| STARSH_int * | irow, | ||
| STARSH_int * | icol, | ||
| void * | row_data, | ||
| void * | col_data, | ||
| void * | result, | ||
| int | ld | ||
| ) |
The Cauchy kernel for STARSH_cauchy object.
Each off-diagonal element is generated as
\[ A_{ij} = \frac{1}{x_i-y_j}, \]
where \( x \) and \( y \) are coordinates of points in one-dimensional space. Diagonal elements are simply set as
\[ A_{ii} = d_i, \]
with given values of \( d_i \).
| [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_cauchy object). |
| [in] | col_data | Pointer to physical data (STARSH_cauchy object). |
| [out] | result | Pointer to memory of \( A \). |
| [in] | ld | Leading dimension of result. |
| void starsh_cauchy_free | ( | STARSH_cauchy * | data | ) |
Free data.
| int starsh_cauchy_get_kernel | ( | STARSH_kernel ** | kernel, |
| STARSH_cauchy * | data, | ||
| enum STARSH_CAUCHY_KERNEL | type | ||
| ) |
Get kernel for minimal working example.
Kernel can be selected with this call or manually. Currently, there is only one kernel for STARSH_cauchy problem.
| [out] | kernel | Address of STARSH_kernel function. |
| [in] | data | Pointer to STARSH_cauchy object. |
| [in] | type | Type of kernel. For more info look at STARSH_CAUCHY_KERNEL. |
| int starsh_cauchy_init | ( | STARSH_cauchy ** | data, |
| STARSH_int | count, | ||
| double * | point | ||
| ) |
Create container for Cauchy example.
| [out] | data | Address of pointer to STARSH_cauchy object. |
| [in] | count | Size of matrix. |
| [in] | point | Coordinates of points (1D space) and values for diagonals of Cauchy matrix. |
| int starsh_cauchy_new | ( | STARSH_cauchy ** | data, |
| STARSH_int | count, | ||
| double * | point, | ||
| double * | diag | ||
| ) |
Create container for Cauchy example.
| [out] | data | Address of pointer to STARSH_cauchy object. |
| [in] | count | Size of matrix. |
| [in] | point | Coordinates of points (1D space). |
| [in] | diag | Values for diagonal of Cauchy matrix. |
| int starsh_cauchy_new_el | ( | STARSH_cauchy ** | data, |
| STARSH_int | count, | ||
| ... | |||
| ) |
Generate STARSH_cauchy object by incomplete set of parameters.
| int starsh_cauchy_new_va | ( | STARSH_cauchy ** | data, |
| STARSH_int | count, | ||
| va_list | args | ||
| ) |
Generate STARSH_cauchy object by incomplete set of parameters.