Matrix  $Rev: 3071 $ at $LastChangedDate: 2015-03-26 15:35:47 +0100 (Thu, 26 Mar 2015) $
Csparse.h
Go to the documentation of this file.
1 
2 #ifndef MATRIX_CSPARSE_H
3 #define MATRIX_CSPARSE_H
4 
5 #include "Mutils.h"
6 
7 Rboolean isValid_Csparse(SEXP x);
8 SEXP Csp_dense_products(SEXP a, SEXP b,
9  Rboolean transp_a, Rboolean transp_b, Rboolean transp_ans);
10 
11 SEXP Csparse_band(SEXP x, SEXP k1, SEXP k2);
12 SEXP Csparse_Csparse_prod(SEXP a, SEXP b, SEXP bool_arith);
13 SEXP Csparse_Csparse_crossprod(SEXP a, SEXP b, SEXP trans, SEXP bool_arith);
14 SEXP Csparse_crossprod(SEXP x, SEXP trans, SEXP triplet, SEXP bool_arith);
15 SEXP Csparse_dense_crossprod(SEXP a, SEXP b, SEXP transp);
16 SEXP Csparse_dense_prod (SEXP a, SEXP b, SEXP transp);
17 SEXP Csparse_diagU2N(SEXP x);
18 SEXP Csparse_diagN2U(SEXP x);
19 SEXP Csparse_drop(SEXP x, SEXP tol);
20 SEXP Csparse_horzcat(SEXP x, SEXP y);
21 SEXP Csparse_submatrix(SEXP x, SEXP i, SEXP j);
22 SEXP dCsparse_subassign(SEXP x, SEXP i_, SEXP j_, SEXP value);
23 SEXP lCsparse_subassign(SEXP x, SEXP i_, SEXP j_, SEXP value);
24 SEXP iCsparse_subassign(SEXP x, SEXP i_, SEXP j_, SEXP value);
25 SEXP nCsparse_subassign(SEXP x, SEXP i_, SEXP j_, SEXP value);
26 SEXP zCsparse_subassign(SEXP x, SEXP i_, SEXP j_, SEXP value);
27 SEXP Csparse_symmetric_to_general(SEXP x);
28 SEXP Csparse_general_to_symmetric(SEXP x, SEXP uplo, SEXP sym_dmns);
29 SEXP Csparse_MatrixMarket(SEXP x, SEXP fname);
30 SEXP Csparse_sort (SEXP x);
31 SEXP Csparse_to_Tsparse(SEXP x, SEXP tri);
32 SEXP Csparse_to_tCsparse(SEXP x, SEXP uplo, SEXP diag);
33 SEXP Csparse_to_tTsparse(SEXP x, SEXP uplo, SEXP diag);
34 SEXP Csparse_to_dense(SEXP x, SEXP symm_or_tri);
35 SEXP Csparse2nz (SEXP x, Rboolean tri);
36 SEXP Csparse_to_nz_pattern(SEXP x, SEXP tri);
37 SEXP nz_pattern_to_Csparse(SEXP x, SEXP res_kind);
38 SEXP nz2Csparse (SEXP x, enum x_slot_kind r_kind);
39 SEXP Csparse_to_matrix(SEXP x, SEXP chk, SEXP symm);
40 SEXP Csparse_to_vector(SEXP x);
41 SEXP Csparse_transpose(SEXP x, SEXP tri);
42 SEXP Csparse_validate (SEXP x);
43 SEXP Csparse_validate2(SEXP x, SEXP maybe_modify);
44 SEXP Csparse_validate_(SEXP x, Rboolean maybe_modify);
45 SEXP Csparse_vertcat(SEXP x, SEXP y);
46 
47 SEXP Rsparse_validate(SEXP x);
48 
49 SEXP diag_tC_ptr(int n, int *x_p, double *x_x, Rboolean is_U, int *perm,
50  SEXP resultKind);
51 SEXP diag_tC(SEXP obj, SEXP resultKind);
52 
53 // FIXME: these are nowhere used (are they?)
54 SEXP create_Csparse(char* cls, int* i, int* j, int* p, int np,
55  void* x, int nnz, int* dims, SEXP dimnames,
56  int index1);
57 #define DG_I_J(i, j, x, nnz) create_Csparse("dgCMatrix", i, j, (int*)NULL, 0, (void*)x, nnz, (int*)NULL, R_NilValue, 1)
58 #define NG_I_J(i, j, nnz) create_Csparse("ngCMatrix", i, j, (int*)NULL, 0, (void*)NULL, nnz, (int*)NULL, R_NilValue, 1)
59 #define DG_I_P(i, p, np, x, nnz) create_Csparse("dgCMatrix", i, (int*)NULL, p, np, (void*)x, nnz, (int*)NULL, R_NilValue, 1)
60 #define NG_I_P(i, p, np, nnz) create_Csparse("ngCMatrix", i, (int*)NULL, p, np, (void*)NULL, nnz, (int*)NULL, R_NilValue, 1)
61 
62 #endif
x_slot_kind
Definition: Mutils.h:184
SEXP Csparse_drop(SEXP x, SEXP tol)
SEXP Csparse_to_matrix(SEXP x, SEXP chk, SEXP symm)
Definition: Csparse.c:284
SEXP diag_tC_ptr(int n, int *x_p, double *x_x, Rboolean is_U, int *perm, SEXP resultKind)
SEXP nCsparse_subassign(SEXP x, SEXP i_, SEXP j_, SEXP value)
SEXP Csparse_to_vector(SEXP x)
Definition: Csparse.c:300
SEXP Csp_dense_products(SEXP a, SEXP b, Rboolean transp_a, Rboolean transp_b, Rboolean transp_ans)
SEXP Csparse_submatrix(SEXP x, SEXP i, SEXP j)
SEXP Csparse_crossprod(SEXP x, SEXP trans, SEXP triplet, SEXP bool_arith)
SEXP Csparse_MatrixMarket(SEXP x, SEXP fname)
SEXP Csparse_validate_(SEXP x, Rboolean maybe_modify)
SEXP Csparse_Csparse_crossprod(SEXP a, SEXP b, SEXP trans, SEXP bool_arith)
[t]crossprod (, )
Definition: Csparse.c:520
SEXP nz2Csparse(SEXP x, enum x_slot_kind r_kind)
Definition: Csparse.c:228
SEXP Csparse_validate(SEXP x)
Definition: Csparse.c:39
SEXP Csparse_to_tTsparse(SEXP x, SEXP uplo, SEXP diag)
Definition: Csparse.c:330
SEXP Csparse_to_Tsparse(SEXP x, SEXP tri)
Definition: Csparse.c:305
SEXP Csparse_horzcat(SEXP x, SEXP y)
SEXP dCsparse_subassign(SEXP x, SEXP i_, SEXP j_, SEXP value)
SEXP Csparse_band(SEXP x, SEXP k1, SEXP k2)
SEXP Csparse_validate2(SEXP x, SEXP maybe_modify)
Definition: Csparse.c:51
SEXP Csparse_general_to_symmetric(SEXP x, SEXP uplo, SEXP sym_dmns)
Definition: Csparse.c:357
SEXP zCsparse_subassign(SEXP x, SEXP i_, SEXP j_, SEXP value)
SEXP create_Csparse(char *cls, int *i, int *j, int *p, int np, void *x, int nnz, int *dims, SEXP dimnames, int index1)
SEXP Csparse_symmetric_to_general(SEXP x)
Definition: Csparse.c:343
SEXP iCsparse_subassign(SEXP x, SEXP i_, SEXP j_, SEXP value)
SEXP diag_tC(SEXP obj, SEXP resultKind)
Rboolean isValid_Csparse(SEXP x)
"Cheap" C version of Csparse_validate() - not sorting :
Definition: Csparse.c:11
SEXP Csparse_diagN2U(SEXP x)
SEXP Csparse_sort(SEXP x)
Definition: Csparse.c:56
SEXP Csparse2nz(SEXP x, Rboolean tri)
Definition: Csparse.c:198
SEXP Csparse_diagU2N(SEXP x)
SEXP lCsparse_subassign(SEXP x, SEXP i_, SEXP j_, SEXP value)
SEXP nz_pattern_to_Csparse(SEXP x, SEXP res_kind)
Definition: Csparse.c:221
SEXP Csparse_to_tCsparse(SEXP x, SEXP uplo, SEXP diag)
Definition: Csparse.c:319
SEXP Csparse_to_nz_pattern(SEXP x, SEXP tri)
Definition: Csparse.c:210
SEXP Csparse_vertcat(SEXP x, SEXP y)
SEXP Csparse_dense_prod(SEXP a, SEXP b, SEXP transp)
SEXP Csparse_transpose(SEXP x, SEXP tri)
Definition: Csparse.c:402
SEXP Csparse_dense_crossprod(SEXP a, SEXP b, SEXP transp)
SEXP Rsparse_validate(SEXP x)
Definition: Csparse.c:62
SEXP Csparse_to_dense(SEXP x, SEXP symm_or_tri)
From a CsparseMatrix, produce a dense one.
Definition: Csparse.c:121
SEXP Csparse_Csparse_prod(SEXP a, SEXP b, SEXP bool_arith)
A %*% B - for matrices of class CsparseMatrix (R package "Matrix")
Definition: Csparse.c:446