ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/OpenMD/branches/development/src/math/SVD.hpp
(Generate patch)

Comparing trunk/src/math/SVD.hpp (file contents):
Revision 1349 by cli2, Wed May 20 19:35:05 2009 UTC vs.
Revision 1390 by gezelter, Wed Nov 25 20:02:06 2009 UTC

# Line 8 | Line 8
8   #include <cmath>
9   // for abs() below
10  
11 < using namespace oopse;
11 > using namespace OpenMD;
12   using namespace std;
13  
14   namespace JAMA
# Line 42 | Line 42 | namespace JAMA
42      
43      
44      SVD (const DynamicRectMatrix<Real> &Arg) {
45            
45        m = Arg.getNRow();
46        n = Arg.getNCol();
47        int nu = min(m,n);
# Line 52 | Line 51 | namespace JAMA
51        DynamicVector<Real> e(n);
52        DynamicVector<Real> work(m);
53        DynamicRectMatrix<Real> A(Arg);
54 <      int wantu = 1;                                    /* boolean */
55 <      int wantv = 1;                                    /* boolean */
54 >
55 >      int wantu = 1;    /* boolean */
56 >      int wantv = 1;    /* boolean */
57        int i=0, j=0, k=0;
58        
59        // Reduce A to bidiagonal form, storing the diagonal elements
# Line 61 | Line 61 | namespace JAMA
61        
62        int nct = min(m-1,n);
63        int nrt = max(0,min(n-2,m));
64 +
65        for (k = 0; k < max(nct,nrt); k++) {
66          if (k < nct) {
67            

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines