Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 09:54:35

0001 // -*- C++ -*-
0002 // $Id: FunctionConvolution.hh,v 1.2 2003/09/06 14:04:13 boudreau Exp $
0003 //------------------------------FunctionConvolution-------------------------//
0004 //                                                                          //
0005 // FunctionConvolution:  output of the Convolve[f,g] operation              //
0006 //                                                                          //
0007 // Petar Maksimovic, Joe Boudreau, November 1999                            //
0008 //                                                                          //
0009 //  Warning!  This is not a very good convolution algorithm!  Does anybody  //
0010 //  out there really know how to perform a reasonable numerical convolution //
0011 //  ? Wanna help the Generic Functions Project?                             //
0012 //                                                                          //
0013 //--------------------------------------------------------------------------//
0014 
0015 #ifndef FunctionConvolution_h
0016 #define FunctionConvolution_h 1
0017 #include "CLHEP/GenericFunctions/AbsFunction.hh"
0018 
0019 namespace Genfun {
0020 
0021   /**
0022    * @author
0023    * @ingroup genfun
0024    */
0025   class FunctionConvolution : public AbsFunction  {
0026 
0027     FUNCTION_OBJECT_DEF(FunctionConvolution)
0028 
0029       public:
0030 
0031     // Constructor
0032     FunctionConvolution(const AbsFunction *arg1, const AbsFunction *arg2, double x0, double x1);
0033   
0034     // Copy Constructor
0035     FunctionConvolution(const FunctionConvolution &right);
0036   
0037     // Destructor
0038     virtual ~FunctionConvolution();
0039   
0040     // Retrieve function value
0041     virtual double operator ()(double argument) const override;
0042     virtual double operator ()(const Argument & argument) const override {return operator() (argument[0]);}
0043   
0044   private:
0045 
0046     // It is illegal to assign a convolution
0047     const FunctionConvolution & operator=(const FunctionConvolution &right);
0048 
0049     // Input functions to convolution
0050     const AbsFunction *_arg1;
0051     const AbsFunction *_arg2;
0052     double _x0;
0053     double _x1;
0054 
0055   };
0056 } // namespace Genfun
0057 #endif