Maj terminée. Pour consulter la release notes associée voici le lien :
https://about.gitlab.com/releases/2021/07/07/critical-security-release-gitlab-14-0-4-released/

rational_function.h 1.47 KB
Newer Older
1 2 3 4 5 6 7 8
#pragma once

// Include STL
#include <vector>
#include <string>

// Interface
#include <core/function.h>
Laurent Belcour's avatar
Laurent Belcour committed
9
#include <core/rational_function.h>
10 11 12
#include <core/data.h>
#include <core/fitter.h>
#include <core/args.h>
13
#include <core/common.h>
14

15 16 17 18 19
class rational_function_chebychev_1d : public rational_function_1d
{
public: // methods

    rational_function_chebychev_1d() ;
20
    rational_function_chebychev_1d(int nX, int np, int nq) ;
21 22 23 24 25 26 27 28 29 30
    virtual ~rational_function_chebychev_1d() {}

    // Get the p_i and q_j function
    virtual double p(const vec& x, int i) const ;
    virtual double q(const vec& x, int j) const ;

protected:  // methods

} ;

Laurent Belcour's avatar
Laurent Belcour committed
31
class rational_function_chebychev : public rational_function
32
{
Laurent Belcour's avatar
Laurent Belcour committed
33
	public: // methods
34

Laurent Belcour's avatar
Laurent Belcour committed
35 36
		rational_function_chebychev() ;
		virtual ~rational_function_chebychev() ;
37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52
		
		//! Get the 1D function associated with color channel i. If no one exist, 
		//! this function allocates a new element. If i > nY, it returns NULL.
		virtual rational_function_1d* get(int i) ;

		//! Update the y-1D function for the ith dimension.
		//! \note It will test if the 1D function provided is of the dynamic type
		//! \name rational_function_chebychev_1d
		virtual void update(int i, rational_function_1d* r)
		{
			if(dynamic_cast<rational_function_chebychev_1d*>(r) != NULL)
			{
				rational_function::update(i, r);
			}
			else
			{
53
#ifdef DEBUG
54
				std::cerr << "<<ERROR>> the function provided is not of type \"rational_function_chebychev\"" << std::endl;
55
#endif
56 57
			}
		}
58 59
} ;