CLHEP 2.4.6.4
C++ Class Library for High Energy Physics
Loading...
Searching...
No Matches
FunctionDirectProduct.hh
Go to the documentation of this file.
1// -*- C++ -*-
2// $Id: FunctionDirectProduct.hh,v 1.2 2003/09/06 14:04:13 boudreau Exp $
3//--------------------------FunctionDirectProduct---------------------------//
4// //
5// FunctionDirectProduct, result of multiplication of taking the direct //
6// product of two functions: f(x)*g(y)= h(x,y). The direct product always //
7// gives a function taking an argument of higher dimensionality than the //
8// arguments. //
9// //
10// Joe Boudreau, Petar Maksimovic, November 1999 //
11// //
12//--------------------------------------------------------------------------//
13#ifndef FunctionDirectProduct_h
14#define FunctionDirectProduct_h 1
15#include "CLHEP/GenericFunctions/AbsFunction.hh"
16
17namespace Genfun {
18
19 /**
20 * @author
21 * @ingroup genfun
22 */
24
26
27 public:
28
29 // Constructor
30 FunctionDirectProduct(const AbsFunction *arg1, const AbsFunction *arg2);
31
32 // Copy constructor
34
35 // Destructor
36 virtual ~FunctionDirectProduct();
37
38 // Retreive function value
39 virtual double operator ()(double argument) const override; // Gives an error.
40 virtual double operator ()(const Argument & argument) const override; // Must use this one
41
42 // Dimensionality
43 virtual unsigned int dimensionality() const override;
44
45 // Derivative.
46 Derivative partial (unsigned int) const override;
47
48 // Does this function have an analytic derivative?
49 virtual bool hasAnalyticDerivative() const override {return true;}
50
51 private:
52
53 // It is illegal to assign a FunctionDirectProduct
54 const FunctionDirectProduct & operator=(const FunctionDirectProduct &right);
55
56 AbsFunction *_arg1;
57 AbsFunction *_arg2;
58 unsigned int _m; // dimension of arg1
59 unsigned int _n; // dimension of arg2
60
61 };
62} // namespace Genfun
63#endif
#define FUNCTION_OBJECT_DEF(classname)
Definition: AbsFunction.hh:143
Derivative partial(unsigned int) const override
virtual bool hasAnalyticDerivative() const override
virtual double operator()(double argument) const override
virtual unsigned int dimensionality() const override
Definition: Abs.hh:14