GHOST  1.1.2
General, Hybrid, and Optimized Sparse Toolkit
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Functions
Dense matrix views

Functions to create views of dense matrices/vectors. More...

Functions

ghost_error ghost_densemat_view_plain (ghost_densemat *x, void *data, ghost_lidx stride)
 View plain data which is stored with a given stride. More...
 
ghost_error ghost_densemat_create_and_view_densemat (ghost_densemat **x, ghost_densemat *src, ghost_lidx nr, ghost_lidx roffs, ghost_lidx nc, ghost_lidx coffs)
 Create a ghost_densemat as a view of compact data of another ghost_densemat. More...
 
ghost_error ghost_densemat_create_and_view_densemat_scattered (ghost_densemat **x, ghost_densemat *src, ghost_lidx nr, ghost_lidx *ridx, ghost_lidx nc, ghost_lidx *cidx)
 Create a ghost_densemat as a view of arbitrarily scattered data of another ghost_densemat. More...
 
ghost_error ghost_densemat_create_and_view_densemat_cols (ghost_densemat **x, ghost_densemat *src, ghost_lidx nc, ghost_lidx coffs)
 Create a ghost_densemat as a view of compact columns of another ghost_densemat. More...
 
ghost_error ghost_densemat_create_and_view_densemat_cols_scattered (ghost_densemat **x, ghost_densemat *src, ghost_lidx nc, ghost_lidx *cidx)
 Create a ghost_densemat as a view of full but scattered columns of another ghost_densemat. More...
 
ghost_error ghost_densemat_clone (ghost_densemat **x, ghost_densemat *src, ghost_lidx nc, ghost_lidx coffs)
 Create a ghost_densemat as a clone of another ghost_densemat at a column given offset. More...
 

Detailed Description

Functions to create views of dense matrices/vectors.

Function Documentation

ghost_error ghost_densemat_clone ( ghost_densemat **  x,
ghost_densemat src,
ghost_lidx  nc,
ghost_lidx  coffs 
)

Create a ghost_densemat as a clone of another ghost_densemat at a column given offset.

Parameters
xThe clone.
srcThe source densemat.
ncThe number of columsn of the new densemat.
coffsThe column offset into the source densemat.
Returns
GHOST_SUCCESS on success or an error indicator.

Here is the call graph for this function:

ghost_error ghost_densemat_create_and_view_densemat ( ghost_densemat **  x,
ghost_densemat src,
ghost_lidx  nr,
ghost_lidx  roffs,
ghost_lidx  nc,
ghost_lidx  coffs 
)

Create a ghost_densemat as a view of compact data of another ghost_densemat.

Parameters
xThe resulting scattered view.
srcThe source densemat with the data to be viewed.
nrThe number of rows of the new densemat.
roffsThe row offset into the source densemat.
ncThe number of columsn of the new densemat.
coffsThe column offset into the source densemat.
Returns
GHOST_SUCCESS on success or an error indicator.
ghost_error ghost_densemat_create_and_view_densemat_cols ( ghost_densemat **  x,
ghost_densemat src,
ghost_lidx  nc,
ghost_lidx  coffs 
)

Create a ghost_densemat as a view of compact columns of another ghost_densemat.

Parameters
xThe resulting scattered view.
srcThe source densemat with the data to be viewed.
ncThe number of columsn of the new densemat.
coffsThe column offset into the source densemat.
Returns
GHOST_SUCCESS on success or an error indicator.
ghost_error ghost_densemat_create_and_view_densemat_cols_scattered ( ghost_densemat **  x,
ghost_densemat src,
ghost_lidx  nc,
ghost_lidx cidx 
)

Create a ghost_densemat as a view of full but scattered columns of another ghost_densemat.

Parameters
xThe resulting scattered view.
srcThe source densemat with the data to be viewed.
ncThe number of columsn of the new densemat.
cidxThe column indices to be viewed.
Returns
GHOST_SUCCESS on success or an error indicator.
ghost_error ghost_densemat_create_and_view_densemat_scattered ( ghost_densemat **  x,
ghost_densemat src,
ghost_lidx  nr,
ghost_lidx ridx,
ghost_lidx  nc,
ghost_lidx cidx 
)

Create a ghost_densemat as a view of arbitrarily scattered data of another ghost_densemat.

Parameters
xThe resulting scattered view.
srcThe source densemat with the data to be viewed.
nrThe number of rows of the new densemat.
ridxThe row indices to be viewed.
ncThe number of columsn of the new densemat.
cidxThe column indices to be viewed.
Returns
GHOST_SUCCESS on success or an error indicator.
ghost_error ghost_densemat_view_plain ( ghost_densemat x,
void *  data,
ghost_lidx  stride 
)

View plain data which is stored with a given stride.

Parameters
xThe densemat.
dataMemory location of the data.
strideStride of the data.
Returns
GHOST_SUCCESS on success or an error indicator.