00001
00002
00004
00005 #if !defined(AFX_TABLE1D_H__F1D3EADA_899F_4335_95AC_21EE6135F5A9__INCLUDED_)
00006 #define AFX_TABLE1D_H__F1D3EADA_899F_4335_95AC_21EE6135F5A9__INCLUDED_
00007
00008 #if _MSC_VER > 1000
00009 #pragma once
00010 #endif // _MSC_VER > 1000
00011
00012
00013
00014 #include <string>
00015
00016 #include "Interpolator1D.h"
00017
00018 #include "GenericFileReader1D.h"
00019 #include "InterpolationData1D.h"
00020 #include "Table.h"
00021
00022 #include "Variable.h"
00023
00024 namespace Interpolator
00025 {
00030 class Table1D : public Table
00031 {
00032 public:
00033
00034 virtual ~Table1D();
00035
00036 Table1D(std::string sName,
00037 std::string sDescription,
00038 std::string sEntryPoint,
00039 std::string sOutputPoint,
00040 Variable* mEntryPoint,
00041 Interpolator1D* mInterpolator1D
00042 );
00043
00044 Table1D(std::string sName,
00045 std::string sDescription,
00046 std::string sEntryPoint,
00047 std::string sOutputPoint,
00048 Variable* mEntryPoint,
00049 std::string sInterpolationType,
00050 long lNbData,
00051 double* mX,
00052 double* mY);
00053
00054 Table1D(std::string sName,
00055 std::string sDescription,
00056 std::string sInterpolationType,
00057 std::string sFilePath,
00058 int iFirstColumn,
00059 int iSecondColumn);
00060
00061
00062 virtual double computeValue(double dValue);
00063 virtual double computeValue();
00064
00065 std::string getEntryPoint() const;
00066 std::string getOutputPoint() const;
00067 Variable* getEntryPointVariable() const;
00068
00069 virtual Interpolator1D* getInterpolator() const;
00070 virtual InterpolationData1D* getInterpolationData() const;
00071
00072 virtual void printInfos();
00073
00074 void setXValue(int i,double dNewValue);
00075 void setYValue(int i,double dNewValue);
00076 void setValues(long lNbData,double* dNewXValues,double* dNewYValues);
00077
00078 double getXValue(int i) const;
00079 double getYValue(int i) const;
00080 double* getXValues() const;
00081 double* getYValues() const;
00082
00083 long getNbData() const;
00084
00085 void checkDataAreCorrects();
00086
00087 void WriteTable();
00088
00089 private:
00090
00091 std::string _sEntryPoint;
00092 std::string _sOutputPoint;
00093 Variable* _mEntryPoint;
00094
00095 Interpolator1D* _mInterpolator;
00096 InterpolationData1D* _mData;
00097
00098
00099
00100
00101
00102
00103
00104
00105
00106 };
00107 }
00108 #endif // !defined(AFX_TABLE1D_H__F1D3EADA_899F_4335_95AC_21EE6135F5A9__INCLUDED_)