SCM

SCM Repository

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

Diff of /pkg/src/geMatrix.c

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

revision 305, Wed Oct 27 21:36:19 2004 UTC revision 306, Wed Oct 27 21:38:33 2004 UTC
# Line 270  Line 270 
270              lwork = -1, info;              lwork = -1, info;
271          int *iwork = Calloc(8 * mm, int);          int *iwork = Calloc(8 * mm, int);
272          double tmp, *work;          double tmp, *work;
273          int bdspac = 3*m*m + 4*m,  /*      int bdspac = 3*m*m + 4*m, */
274              wrkbl, maxwrk, minwrk, itmp,  /*          wrkbl, maxwrk, minwrk, itmp, */
275              ione = 1, iminus1 = -1;  /*          ione = 1, iminus1 = -1; */
276          int i1, i2, i3;  /*      int i1, i2, i3; */
277    
278          SET_VECTOR_ELT(val, 0, allocVector(REALSXP, mm));          SET_VECTOR_ELT(val, 0, allocVector(REALSXP, mm));
279          SET_VECTOR_ELT(val, 1, allocMatrix(REALSXP, m, mm));          SET_VECTOR_ELT(val, 1, allocMatrix(REALSXP, m, mm));
# Line 284  Line 284 
284                           REAL(VECTOR_ELT(val, 2)), &mm,                           REAL(VECTOR_ELT(val, 2)), &mm,
285                           &tmp, &lwork, iwork, &info);                           &tmp, &lwork, iwork, &info);
286          lwork = (int) tmp;          lwork = (int) tmp;
287          F77_CALL(foo)(&i1, &i2, &i3);  /*      F77_CALL(foo)(&i1, &i2, &i3); */
288          wrkbl = 3*m+(m+n)*i1;  /*      wrkbl = 3*m+(m+n)*i1; */
289          if (wrkbl < (itmp = 3*m + m*i2)) wrkbl = itmp;  /*      if (wrkbl < (itmp = 3*m + m*i2)) wrkbl = itmp; */
290          if (wrkbl < (itmp = 3*m + m*i3)) wrkbl = itmp;  /*      if (wrkbl < (itmp = 3*m + m*i3)) wrkbl = itmp; */
291          itmp = bdspac+3*m;  /*      itmp = bdspac+3*m; */
292          maxwrk = (wrkbl > itmp) ? wrkbl : itmp;  /*      maxwrk = (wrkbl > itmp) ? wrkbl : itmp; */
293          minwrk = 3*m + ((bdspac > n) ?  bdspac : n);  /*      minwrk = 3*m + ((bdspac > n) ?  bdspac : n); */
294          work = Calloc(lwork, double);          work = Calloc(lwork, double);
295          F77_CALL(dgesdd)("S", &m, &n, xx, &m,          F77_CALL(dgesdd)("S", &m, &n, xx, &m,
296                           REAL(VECTOR_ELT(val, 0)),                           REAL(VECTOR_ELT(val, 0)),

Legend:
Removed from v.305  
changed lines
  Added in v.306

root@r-forge.r-project.org
ViewVC Help
Powered by ViewVC 1.0.0  
Thanks to:
Vienna University of Economics and Business Powered By FusionForge