SCM

SCM Repository

[matrix] Diff of /pkg/Matrix/src/Csparse.c
ViewVC logotype

Diff of /pkg/Matrix/src/Csparse.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1218, Mon Feb 20 22:47:20 2006 UTC revision 1267, Tue May 16 19:12:13 2006 UTC
# Line 107  Line 107 
107      chcp = cholmod_aat((!tr) ? chxt : chx, (int *) NULL, 0, chx->xtype, &c);      chcp = cholmod_aat((!tr) ? chxt : chx, (int *) NULL, 0, chx->xtype, &c);
108      if(!chcp)      if(!chcp)
109          error("Csparse_crossprod(): error return from cholmod_aat()");          error("Csparse_crossprod(): error return from cholmod_aat()");
110        cholmod_band_inplace((tr) ? -(chcp->nrow) : 0, (tr) ? 0 : chcp->ncol,
111                             chcp->xtype, chcp, &c);
112      if (trip) {      if (trip) {
113          cholmod_free_sparse(&chx, &c);          cholmod_free_sparse(&chx, &c);
114          Free(cht);          Free(cht);
# Line 137  Line 138 
138      Free(chx); Free(chy);      Free(chx); Free(chy);
139      return chm_sparse_to_SEXP(ans, 1);      return chm_sparse_to_SEXP(ans, 1);
140  }  }
141    
142    SEXP Csparse_band(SEXP x, SEXP k1, SEXP k2)
143    {
144        cholmod_sparse *chx = as_cholmod_sparse(x), *ans;
145    
146        ans = cholmod_band(chx, asInteger(k1), asInteger(k2), chx->xtype, &c);
147        Free(chx);
148        return chm_sparse_to_SEXP(ans, 1);
149    }

Legend:
Removed from v.1218  
changed lines
  Added in v.1267

R-Forge@R-project.org
ViewVC Help
Powered by ViewVC 1.0.0  
Thanks to:
Vienna University of Economics and Business University of Wisconsin - Madison Powered By FusionForge