Biomechanical Joint Model
 Author: Anderson Maciel

comematrix.h

Go to the documentation of this file.
00001 /***************************************************************************
00002  *   Copyright (C) 2002 by Anderson Maciel                                 *
00003  *   andi.maciel@gmail.com                                                 *
00004  *                                                                         *
00005  *   This program is free software; you can redistribute it and/or modify  *
00006  *   it under the terms of the GNU General Public License as published by  *
00007  *   the Free Software Foundation; either version 2 of the License, or     *
00008  *   (at your option) any later version.                                   *
00009  *                                                                         *
00010  *   This program is distributed in the hope that it will be useful,       *
00011  *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
00012  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
00013  *   GNU General Public License for more details.                          *
00014  *                                                                         *
00015  *   You should have received a copy of the GNU General Public License     *
00016  *   along with this program; if not, write to the                         *
00017  *   Free Software Foundation, Inc.,                                       *
00018  *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
00019  **************************************************************************/
00020 
00022 //
00023 //  PROJECT.....: 
00024 //  RESPONSIBLE.: 
00025 //
00026 //  AUTHOR......: Anderson Maciel
00027 //  DATE........: 04/November/2002
00028 //  DESCRIPTION.: Class and new methods declaration.
00029 //
00031 
00032 #ifndef __COME_MATRIX_H
00033 #define __COME_MATRIX_H
00034 
00035 
00036 #include        <general/come.h>
00037 #include        <algebra/comepoint3d.h>
00038 
00039 #ifndef __COME_VECTOR3D_H
00040 class COME_Vector3D;
00041 #endif
00042 
00043 #ifndef __COME_VERTEX3D_H
00044 class COME_Vertex3D;
00045 #endif
00046 
00053 
00054 typedef double mat44 [4][4];
00055 
00056 class COME_Matrix : public COME {
00057 
00058 
00059         private:
00060                 double  data[4][4];
00061 
00062         protected:
00063                 COME_Matrix     getAdjoint( void );
00064                 double          getDet33( double, double, double, double, double, double, double, double, double );
00065                 double          getDet22( double, double, double, double );
00066 
00067         public:
00068                 COME_Matrix();
00069                 COME_Matrix( double[] );
00070                 COME_Matrix( double[][4] );
00071                 ~COME_Matrix();
00072                 
00073                 void                    setValueAt( int, int, double );
00074                 void                    setMatrix( const COME_Matrix& matrixN );
00075                 double                  getValueAt( int, int ) const;
00076                 const double**  getMatrixD( void );
00077                 void                    getMatrixD( double ** );
00078                 double*                 getMatrixVD( void );
00079 
00080                 COME_Matrix             getInverse( void );
00081                 COME_Matrix             getTransposed( void );
00082                 double                  getDeterminent( void );
00083 
00084                 COME_Matrix*    multiplyScalar( double );
00085                 COME_Matrix*    multiply( COME_Matrix );
00086                 COME_Matrix*    subtract( COME_Matrix );
00087                 COME_Matrix*    add( COME_Matrix );
00088                 COME_Point3D*           multiply ( COME_Point3D );
00089                 void                    reset();
00090 
00091                 COME_Matrix&    operator+= ( const COME_Matrix& mO );
00092                 COME_Matrix             operator+ ( const COME_Matrix& mO );
00093                 COME_Matrix             operator* ( double scalar );
00094                 COME_Matrix             operator* ( const COME_Matrix& mO );
00095                 COME_Vector3D           operator* ( COME_Vector3D& pO );
00096                 COME_Point3D            operator* ( const COME_Point3D& pO );
00097                 COME_Vertex3D           operator* ( const COME_Vertex3D& vO );
00098 };
00099 
00100 #endif

Generated on Thu Dec 1 10:13:34 2005 for COME - Biomechanical Joint Model by  doxygen 1.4.5