Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-06-02 08:48:23

0001 #ifndef TRAPEZOIDAL_LOG_INTEGRATOR_1D_H
0002 #define TRAPEZOIDAL_LOG_INTEGRATOR_1D_H
0003 
0004 /**
0005  * @file TrapezoidalLogIntegrator1D.h
0006  * @author Pawel Sznajder (NCBJ, Warsaw)
0007  * @date 12 July 2017
0008  * @version 1.0
0009  */
0010 
0011 #include "QuadratureIntegrator1D.h"
0012 
0013 #include <ElementaryUtils/parameters/Parameters.h>
0014 #include <string>
0015 #include <vector>
0016 
0017 class FunctionType1D;
0018 
0019 namespace NumA {
0020 
0021 /**
0022  * @class TrapezoidalLogIntegrator1D
0023  *
0024  * @brief Trapezoidal integration with logarithmic step.
0025  *
0026  * See Integrator1D documentation for an example.
0027  */
0028 
0029 class TrapezoidalLogIntegrator1D: public QuadratureIntegrator1D {
0030 
0031 public:
0032 
0033     /**
0034      * Constructor.
0035      * @param N Order of the quadrature (number of nodes).
0036      */
0037     TrapezoidalLogIntegrator1D(unsigned int N = 40);
0038 
0039     /**
0040      * Default destructor.
0041      */
0042     virtual ~TrapezoidalLogIntegrator1D();
0043 
0044     virtual TrapezoidalLogIntegrator1D* clone() const;
0045     virtual void configure(const ElemUtils::Parameters &parameters);
0046     virtual void setN(unsigned int n);
0047     virtual double integrate(FunctionType1D* pFunction, double a, double b,
0048             std::vector<double> &parameters);
0049 
0050 protected:
0051 
0052     /**
0053      * Copy constructor.
0054      * Called by clone().
0055      * @param other TrapezoidalLogIntegrator1D object to copy.
0056      */
0057     TrapezoidalLogIntegrator1D(const TrapezoidalLogIntegrator1D &other);
0058 };
0059 
0060 } /* namespace NumA */
0061 
0062 #endif /* TRAPEZOIDAL_LOG_INTEGRATOR_1D_H */