00001
00002
00003
00004
00005
00006
00007
00008
00009
00010 #ifndef ROOT_Minuit2_MatrixInverse
00011 #define ROOT_Minuit2_MatrixInverse
00012
00013 #include "Minuit2/ABTypes.h"
00014 #include "Minuit2/ABObj.h"
00015
00016 namespace ROOT {
00017
00018 namespace Minuit2 {
00019
00020
00021 template<class mtype, class M, class T>
00022 class MatrixInverse {
00023
00024 public:
00025
00026 MatrixInverse(const M& obj) : fObject(obj) {}
00027
00028 ~MatrixInverse() {}
00029
00030 typedef mtype Type;
00031
00032 const M& Obj() const {return fObject;}
00033
00034 private:
00035
00036 M fObject;
00037 };
00038
00039 template<class M, class T>
00040 class MatrixInverse<vec, M, T> {
00041
00042 private:
00043
00044 MatrixInverse(const M& obj) : fObject(obj) {}
00045
00046 public:
00047
00048 ~MatrixInverse() {}
00049
00050 typedef vec Type;
00051
00052 const M& Obj() const {return fObject;}
00053
00054 private:
00055
00056 M fObject;
00057 };
00058
00059 template<class mt, class M, class T>
00060 inline ABObj<mt, MatrixInverse<mt, ABObj<mt, M, T>, T>, T> Inverse(const ABObj<mt, M, T>& obj) {
00061 return ABObj<mt, MatrixInverse<mt, ABObj<mt, M, T>, T>, T>(MatrixInverse<mt, ABObj<mt, M, T>, T>(obj));
00062 }
00063
00064 }
00065
00066 }
00067
00068 #endif // ROOT_Minuit2_MatrixInverse