CLHEP 2.4.6.4
C++ Class Library for High Energy Physics
Loading...
Searching...
No Matches
Sigma.hh
Go to the documentation of this file.
1// -*- C++ -*-
2// $Id:
3//--------------------------Sigma-------------------------------------------//
4// //
5// Sigma, result of addition of N functions //
6// //
7//--------------------------------------------------------------------------//
8
9#ifndef Sigma_h
10#define Sigma_h 1
11#include "CLHEP/GenericFunctions/AbsFunction.hh"
12
13namespace Genfun {
14
15 /**
16 * @author
17 * @ingroup genfun
18 */
19 class Sigma : public AbsFunction {
20
22
23 public:
24
25 // Constructor
26 Sigma();
27
28 // Copy constructor
29 Sigma(const Sigma &right);
30
31 // Destructor
32 virtual ~Sigma();
33
34 // Retreive function value
35 virtual double operator ()(double argument) const override;
36 virtual double operator ()(const Argument & a) const override;
37
38 // Dimensionality
39 virtual unsigned int dimensionality() const override;
40
41 // Derivative.
42 Derivative partial (unsigned int) const override;
43
44 // Does this function have an analytic derivative?
45 virtual bool hasAnalyticDerivative() const override {return true;}
46
47 // Add a function to the sum:
48 void accumulate (const AbsFunction & fcn);
49
50 private:
51
52 // It is illegal to assign a Sigma
53 const Sigma & operator=(const Sigma &right);
54
55 std::vector<const AbsFunction *> _fcn;
56
57 };
58} // namespace Genfun
59#endif
#define FUNCTION_OBJECT_DEF(classname)
Definition: AbsFunction.hh:143
virtual unsigned int dimensionality() const override
Definition: Sigma.cc:24
Derivative partial(unsigned int) const override
Definition: Sigma.cc:53
virtual ~Sigma()
Definition: Sigma.cc:29
virtual bool hasAnalyticDerivative() const override
Definition: Sigma.hh:45
void accumulate(const AbsFunction &fcn)
Definition: Sigma.cc:9
virtual double operator()(double argument) const override
Definition: Sigma.cc:36
Definition: Abs.hh:14