/home/coin/SVN-release/OS-1.0.0/OS/src/OSUtils/MathUtil.h

Go to the documentation of this file.
00001 
00021 #ifndef MATHUTIL_H
00022 #define MATHUTIL_H
00023  
00024  #include "OSParameters.h"
00025 
00026 
00039 class MathUtil{
00040         public:
00041 
00043         MathUtil();
00044         
00046         ~MathUtil();
00047         
00055         /*public static double round (double x, int precision){
00056                 double mask = 0.0, y, result;           
00057                 try{
00058                         mask = Math.pow (10.0, -(double)precision);
00059                 }
00060                 catch(ArithmeticException e){
00061                         return x;
00062                 }
00063                 y  = mod(x, mask);
00064                 result  = x - y;
00065                 if (y / mask >= 0.5) result += mask;
00066                 return result;
00067         }//round
00068         */
00076         /*public static double mod (double x, double y){
00077                 return  x - Math.floor(x / y) * y;
00078         }//mod
00079         */
00094         static SparseMatrix* convertLinearConstraintCoefficientMatrixToTheOtherMajor(
00095                         bool isColumnMajor, int startSize, int valueSize, int* start, int* index, 
00096                         double* value, int dimension);
00097                         
00098 
00099 
00100 };//class MathUtil
00101 #endif

Generated on Thu May 15 22:15:05 2008 by  doxygen 1.4.7