matpow.c File Reference


Detailed Description

Sparse matrix-power-vector multiply implementation.

This module implements the matrix type-independent version, which performs error-checking first and then calls the the appropriate kernel implementation.

#include <oski/common.h>
#include <oski/matrix.h>
#include <oski/blas.h>

Functions

int oski_CheckArgsMatPowMult (const oski_matrix_t A_tunable, oski_matop_t opA, int power, oski_value_t alpha, const oski_vecview_t x_view, oski_value_t beta, const oski_vecview_t y_view, const oski_vecview_t T_view, const char *caller)
 Check arguments passed to oski_MatPowMult().
static void SplitVecsColwise (oski_vecview_t T, oski_index_t na, oski_vecview_t A, oski_vecview_t x, oski_index_t nb, oski_vecview_t B)
 Logically partition the columns of a multivector object into three.
static int DefaultMatPowMult (const oski_matrix_t A_tunable, oski_matop_t opA, int power, oski_value_t alpha, const oski_vecview_t x_view, oski_value_t beta, oski_vecview_t y_view, oski_vecview_t T_view)
 Default matrix-power-vector multiply routine.
int oski_MatPowMult (const oski_matrix_t A_tunable, oski_matop_t opA, int power, oski_value_t alpha, const oski_vecview_t x_view, oski_value_t beta, oski_vecview_t y_view, oski_vecview_t T_view)
 Computes a power of a matrix times a vector, or $y \leftarrow \alpha\cdot\mathrm{op}(A)^\rho x + \beta\cdot y$.
void oski_MakeArglistMatPowMult (oski_matop_t opA, int power, oski_value_t alpha, const oski_vecview_t x_view, oski_value_t beta, const oski_vecview_t y_view, const oski_vecview_t T_view, oski_traceargs_MatPowMult_t *args)
 Initialize a static argument signature for a call to oski_MatPowMult().


Function Documentation

static int DefaultMatPowMult const oski_matrix_t  A_tunable,
oski_matop_t  opA,
int  power,
oski_value_t  alpha,
const oski_vecview_t  x_view,
oski_value_t  beta,
oski_vecview_t  y_view,
oski_vecview_t  T_view
[static]
 

Default matrix-power-vector multiply routine.

This routine does not perform any argument error checking. If T_view is NULL, this routine may quietly attempt to allocate memory for one temporary vector, deleted before returning.

int oski_CheckArgsMatPowMult const oski_matrix_t  A_tunable,
oski_matop_t  opA,
int  power,
oski_value_t  alpha,
const oski_vecview_t  x_view,
oski_value_t  beta,
const oski_vecview_t  y_view,
const oski_vecview_t  T_view,
const char *  caller
 

Check arguments passed to oski_MatPowMult().

Returns:
0 if all arguments are OK, or an error code (plus a call to the error handler) otherwise.
Todo:
Need more verbose error messages in the event that the vectors have improper dimensions.


Generated on Wed Sep 19 16:41:22 2007 for BeBOP Optimized Sparse Kernel Interface Library by  doxygen 1.4.6