CLHEP 2.0.4.7 Reference Documentation
   
CLHEP Home Page     CLHEP Documentation     CLHEP Bug Reports

PeriodicRectangular.hh

Go to the documentation of this file.
00001 // -*- C++ -*-
00002 // $Id: PeriodicRectangular.hh,v 1.2 2003/09/06 14:04:13 boudreau Exp $
00003 //---------------------Rectangular------------------------------------------//
00004 //                                                                          //
00005 // Class Exponential                                                        //
00006 // Joe Boudreau, Petar Maksimovic, November 1999                            //
00007 //                                                                          //
00008 //--------------------------------------------------------------------------//
00009 #ifndef PeriodicRectangular_h_
00010 #define PeriodicRectangular_h_ 1
00011 #include "CLHEP/GenericFunctions/AbsFunction.hh"
00012 #include "CLHEP/GenericFunctions/Parameter.hh"
00013 namespace Genfun {
00014 
00019   class PeriodicRectangular : public AbsFunction  {
00020 
00021     FUNCTION_OBJECT_DEF(PeriodicRectangular)
00022 
00023 
00024     public:
00025 
00026     // Constructor
00027     PeriodicRectangular();
00028 
00029     // Copy constructor
00030     PeriodicRectangular(const PeriodicRectangular &right);
00031   
00032     // Destructor
00033     virtual ~PeriodicRectangular();
00034   
00035     // Retreive function value
00036     virtual double operator ()(double argument) const;
00037     virtual double operator ()(const Argument & a) const {return operator() (a[0]);}
00038   
00039     // Get the position of the first discontinuity
00040     Parameter & a(); 
00041 
00042     // Get the position of the second discontinuity
00043     Parameter & b(); 
00044 
00045     // Get the value of the function at its top
00046     Parameter & height(); 
00047   
00048     // Derivative.  
00049     Derivative partial (unsigned int) const;
00050 
00051     // Does this function have an analytic derivative?
00052     virtual bool hasAnalyticDerivative() const {return true;}
00053 
00054   private:
00055 
00056     // It is illegal to assign an adjustable constant
00057     const PeriodicRectangular & operator=(const PeriodicRectangular &right);
00058 
00059     // Here is the decay constant
00060     Parameter _a;
00061     Parameter _b;
00062     Parameter _height;
00063 
00064   };
00065 } // namespace Genfun
00066 #endif

Generated on Thu Jul 1 22:02:30 2010 for CLHEP by  doxygen 1.4.7