3#include "CLHEP/GenericFunctions/Variable.hh"
4#include "CLHEP/GenericFunctions/FixedConstant.hh"
10 _selectionIndex(selectionIndex),
11 _dimensionality(dmsnlty)
16 _selectionIndex(right._selectionIndex),
17 _dimensionality(right._dimensionality)
25 if (_selectionIndex!=0)
throw std::runtime_error(
"Genfun::Variable: selection index !=0") ;
30 if (!(_selectionIndex<a.
dimension()))
throw std::runtime_error(
"Genfun::Varaible selection index out of bounds");
31 return a[_selectionIndex];
35 return _selectionIndex;
40 int kroneckerDelta = mindex==_selectionIndex ? 1 : 0;
43 for (
unsigned int i=1;i<_dimensionality;i++) {
54 return _dimensionality;
#define FUNCTION_OBJECT_IMP(classname)
unsigned int dimension() const
Variable(unsigned int selectionIndex=0, unsigned int dimensionality=1)
Derivative partial(unsigned int) const override
unsigned int index() const
virtual double operator()(double argument) const override
virtual unsigned int dimensionality() const override