SCM Repository
[matrix] Diff of /pkg/src/Csparse.c
Diff of /pkg/src/Csparse.c
Parent Directory
|
Revision Log
|
Patch
1 |
/* Sparse matrices in compress column-oriented form */ |
/* Sparse matrices in compressed column-oriented form */ |
2 |
#include "Csparse.h" |
#include "Csparse.h" |
3 |
#include "chm_common.h" |
#include "chm_common.h" |
4 |
|
|
118 |
return chm_sparse_to_SEXP(chcp, 1); |
return chm_sparse_to_SEXP(chcp, 1); |
119 |
} |
} |
120 |
|
|
121 |
|
SEXP Csparse_horzcat(SEXP x, SEXP y) |
122 |
|
{ |
123 |
|
cholmod_sparse *chx = as_cholmod_sparse(x), |
124 |
|
*chy = as_cholmod_sparse(y), *ans; |
125 |
|
|
126 |
|
ans = cholmod_horzcat(chx, chy, 1, &c); |
127 |
|
Free(chx); Free(chy); |
128 |
|
return chm_sparse_to_SEXP(ans, 1); |
129 |
|
} |
130 |
|
|
131 |
|
SEXP Csparse_vertcat(SEXP x, SEXP y) |
132 |
|
{ |
133 |
|
cholmod_sparse *chx = as_cholmod_sparse(x), |
134 |
|
*chy = as_cholmod_sparse(y), *ans; |
135 |
|
|
136 |
|
ans = cholmod_vertcat(chx, chy, 1, &c); |
137 |
|
Free(chx); Free(chy); |
138 |
|
return chm_sparse_to_SEXP(ans, 1); |
139 |
|
} |
|
Legend:
Removed from v.1141 |
|
changed lines |
|
Added in v.1218 |
|
|