Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 4572 in orxonox.OLD for orxonox/trunk/src/lib/collision_detection


Ignore:
Timestamp:
Jun 10, 2005, 1:17:13 AM (19 years ago)
Author:
patrick
Message:

orxonox/trunk: newmat lib now works with cd and cd-subproject

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/lib/collision_detection/obb_tree_node.cc

    r4568 r4572  
    2323
    2424#include <math.h>
     25
     26
     27#define WANT_STREAM
     28#define WANT_MATH
     29#define WANT_FSTREAM
     30
     31
     32#include "include.h"
     33#include "newmat.h"
     34#include "newmatap.h"
     35#include "newmatio.h"
     36
     37
     38
    2539
    2640using namespace std;
     
    152166     vectors
    153167  */
     168   
     169  SymmetricMatrix C(3);
     170 
     171  C(1,1) = 1;
     172  C(1,2) = 4;
     173  C(1,3) = 4;
     174  C(2,1) = 4; 
     175  C(2,2) = 2;
     176  C(2,3) = 4;
     177  C(3,1) = 4;
     178  C(3,2) = 4;
     179  C(3,3) = 3;
     180 
     181  // cout << "The symmetrix matrix C" << endl;
     182  //cout << setw(5) << setprecision(0) << C << endl;
     183
     184  Matrix                V(3,3); // for eigenvectors
     185  DiagonalMatrix        D(3);   // for eigenvalues
     186 
     187  // the decomposition
     188  Jacobi(C, D, V);
     189
     190
     191  // Print the result
     192 /* cout << "The eigenvalues matrix:" << endl;
     193  cout << setw(10) << setprecision(5) << D << endl;
     194  cout << "The eigenvectors matrix:" << endl;*/
    154195 
    155196
Note: See TracChangeset for help on using the changeset viewer.