CLHEP VERSION Reference Documentation
CLHEP Home Page
CLHEP Documentation
CLHEP Bug Reports
Main Page
Namespaces
Classes
Files
File List
File Members
GenericFunctions
CLHEP
GenericFunctions
CLHEP/GenericFunctions/ConstTimesFunction.hh
Go to the documentation of this file.
1
// -*- C++ -*-
2
// $Id: ConstTimesFunction.hh,v 1.2 2003/09/06 14:04:13 boudreau Exp $
3
//--------------------------ConstOverFunction-------------------------------//
4
// //
5
// ConstOverFunction, result of multiplying a constant and a function //
6
// Joe Boudreau, Petar Maksimovic, November 1999 //
7
// //
8
//--------------------------------------------------------------------------//
9
10
#ifndef ConstTimesFunction_h
11
#define ConstTimesFunction_h 1
12
#include "
CLHEP/GenericFunctions/AbsFunction.hh
"
13
namespace
Genfun {
14
19
class
ConstTimesFunction
:
public
AbsFunction
{
20
21
FUNCTION_OBJECT_DEF
(
ConstTimesFunction
)
22
23
public
:
24
25
// Constructor
26
ConstTimesFunction
(
double
constant,
const
AbsFunction
*arg);
27
28
// Copy constructor
29
ConstTimesFunction
(
const
ConstTimesFunction
&right);
30
31
// Destructor
32
virtual
~ConstTimesFunction
();
33
34
// Retreive function value
35
virtual
double
operator ()
(
double
argument)
const
;
36
virtual
double
operator ()
(
const
Argument
&
a
)
const
;
37
38
// Dimensionality
39
virtual
unsigned
int
dimensionality
()
const
;
40
41
// Derivative.
42
Derivative
partial
(
unsigned
int
)
const
;
43
44
// Does this function have an analytic derivative?
45
virtual
bool
hasAnalyticDerivative
()
const
{
return
true
;}
46
47
private
:
48
49
// It is illegal to assign a ConstTimesFunction
50
const
ConstTimesFunction
& operator=(
const
ConstTimesFunction
&right);
51
52
double
_constant;
53
const
AbsFunction
*_arg;
54
};
55
}
// namespace Genfun
56
#endif
Generated on Sun Jun 17 2012 08:08:26 for CLHEP by
1.8.1.1