Mercurial > octave-nkf
comparison liboctave/numeric/dbleQR.cc @ 18084:8e056300994b
Follow coding convention of defining and initializing only 1 variable per line in liboctave.
* liboctave/array/Array-b.cc, liboctave/array/Array-util.cc,
liboctave/array/Array.cc, liboctave/array/CDiagMatrix.cc,
liboctave/array/CMatrix.cc, liboctave/array/CSparse.cc,
liboctave/array/MDiagArray2.cc, liboctave/array/MatrixType.cc,
liboctave/array/PermMatrix.cc, liboctave/array/Sparse.cc,
liboctave/array/Sparse.h, liboctave/array/boolSparse.cc,
liboctave/array/dDiagMatrix.cc, liboctave/array/dMatrix.cc,
liboctave/array/dSparse.cc, liboctave/array/dim-vector.cc,
liboctave/array/fCDiagMatrix.cc, liboctave/array/fCMatrix.cc,
liboctave/array/fDiagMatrix.cc, liboctave/array/fMatrix.cc,
liboctave/array/idx-vector.cc, liboctave/array/idx-vector.h,
liboctave/numeric/CmplxLU.cc, liboctave/numeric/CmplxQR.cc,
liboctave/numeric/base-qr.cc, liboctave/numeric/bsxfun-defs.cc,
liboctave/numeric/bsxfun.h, liboctave/numeric/dbleLU.cc,
liboctave/numeric/dbleQR.cc, liboctave/numeric/fCmplxLU.cc,
liboctave/numeric/fCmplxQR.cc, liboctave/numeric/floatLU.cc,
liboctave/numeric/floatQR.cc, liboctave/numeric/lo-specfun.cc,
liboctave/numeric/oct-convn.cc, liboctave/numeric/oct-norm.cc,
liboctave/numeric/sparse-dmsolve.cc, liboctave/operators/mx-inlines.cc,
liboctave/operators/mx-op-defs.h, liboctave/util/caseless-str.h,
liboctave/util/kpse.cc, liboctave/util/lo-utils.cc,
liboctave/util/oct-binmap.h, liboctave/util/oct-cmplx.h,
liboctave/util/oct-inttypes.cc, liboctave/util/oct-inttypes.h,
liboctave/util/oct-sort.cc:
Follow coding convention of defining and initializing only 1 variable per line in liboctave.
author | Rik <rik@octave.org> |
---|---|
date | Wed, 04 Dec 2013 22:13:18 -0800 |
parents | 49a5a4be04a1 |
children | d47e50953abc |
comparison
equal
deleted
inserted
replaced
18083:938f01339043 | 18084:8e056300994b |
---|---|
136 } | 136 } |
137 | 137 |
138 void QR::form (octave_idx_type n, Matrix& afact, | 138 void QR::form (octave_idx_type n, Matrix& afact, |
139 double *tau, qr_type_t qr_type) | 139 double *tau, qr_type_t qr_type) |
140 { | 140 { |
141 octave_idx_type m = afact.rows (), min_mn = std::min (m, n); | 141 octave_idx_type m = afact.rows (); |
142 octave_idx_type min_mn = std::min (m, n); | |
142 octave_idx_type info; | 143 octave_idx_type info; |
143 | 144 |
144 if (qr_type == qr_type_raw) | 145 if (qr_type == qr_type_raw) |
145 { | 146 { |
146 for (octave_idx_type j = 0; j < min_mn; j++) | 147 for (octave_idx_type j = 0; j < min_mn; j++) |
212 octave_idx_type n = r.columns (); | 213 octave_idx_type n = r.columns (); |
213 octave_idx_type k = q.columns (); | 214 octave_idx_type k = q.columns (); |
214 | 215 |
215 if (u.length () == m && v.length () == n) | 216 if (u.length () == m && v.length () == n) |
216 { | 217 { |
217 ColumnVector utmp = u, vtmp = v; | 218 ColumnVector utmp = u; |
219 ColumnVector vtmp = v; | |
218 OCTAVE_LOCAL_BUFFER (double, w, 2*k); | 220 OCTAVE_LOCAL_BUFFER (double, w, 2*k); |
219 F77_XFCN (dqr1up, DQR1UP, (m, n, k, q.fortran_vec (), | 221 F77_XFCN (dqr1up, DQR1UP, (m, n, k, q.fortran_vec (), |
220 m, r.fortran_vec (), k, | 222 m, r.fortran_vec (), k, |
221 utmp.fortran_vec (), vtmp.fortran_vec (), w)); | 223 utmp.fortran_vec (), vtmp.fortran_vec (), w)); |
222 } | 224 } |
234 if (u.rows () == m && v.rows () == n && u.cols () == v.cols ()) | 236 if (u.rows () == m && v.rows () == n && u.cols () == v.cols ()) |
235 { | 237 { |
236 OCTAVE_LOCAL_BUFFER (double, w, 2*k); | 238 OCTAVE_LOCAL_BUFFER (double, w, 2*k); |
237 for (volatile octave_idx_type i = 0; i < u.cols (); i++) | 239 for (volatile octave_idx_type i = 0; i < u.cols (); i++) |
238 { | 240 { |
239 ColumnVector utmp = u.column (i), vtmp = v.column (i); | 241 ColumnVector utmp = u.column (i); |
242 ColumnVector vtmp = v.column (i); | |
240 F77_XFCN (dqr1up, DQR1UP, (m, n, k, q.fortran_vec (), | 243 F77_XFCN (dqr1up, DQR1UP, (m, n, k, q.fortran_vec (), |
241 m, r.fortran_vec (), k, | 244 m, r.fortran_vec (), k, |
242 utmp.fortran_vec (), vtmp.fortran_vec (), | 245 utmp.fortran_vec (), vtmp.fortran_vec (), |
243 w)); | 246 w)); |
244 } | 247 } |