Logo ROOT   6.30.04
Reference Guide
 All Namespaces Files Pages
VectorOuterProduct.h
Go to the documentation of this file.
1 // @(#)root/minuit2:$Id$
2 // Authors: M. Winkler, F. James, L. Moneta, A. Zsenei 2003-2005
3 
4 /**********************************************************************
5  * *
6  * Copyright (c) 2005 LCG ROOT Math team, CERN/PH-SFT *
7  * *
8  **********************************************************************/
9 
10 #ifndef ROOT_Minuit2_VectorOuterProduct
11 #define ROOT_Minuit2_VectorOuterProduct
12 
13 #include "Minuit2/ABTypes.h"
14 #include "Minuit2/ABObj.h"
15 
16 namespace ROOT {
17 
18  namespace Minuit2 {
19 
20 
21 template<class M, class T>
22 class VectorOuterProduct {
23 
24 public:
25 
26  VectorOuterProduct(const M& obj) : fObject(obj) {}
27 
28  ~VectorOuterProduct() {}
29 
30  typedef sym Type;
31 
32  const M& Obj() const {return fObject;}
33 
34 private:
35 
36  M fObject;
37 };
38 
39 template<class M, class T>
40 inline ABObj<sym, VectorOuterProduct<ABObj<vec, M, T>, T>, T> Outer_product(const ABObj<vec, M, T>& obj) {
41  return ABObj<sym, VectorOuterProduct<ABObj<vec, M, T>, T>, T>(VectorOuterProduct<ABObj<vec, M, T>, T>(obj));
42 }
43 
44  } // namespace Minuit2
45 
46 } // namespace ROOT
47 
48 #endif // ROOT_Minuit2_VectorOuterProduct