//アキマ(秋間 浩)の補間法2 for WIN32 API #include #ifndef AKIMA_NI #define AKIMA_NI const int MAX=64; class akima{ double x[7],f[7]; int N; //ユーザーが設定した分点の数 int PX[MAX],PF[MAX]; //ユーザーが設定した分点のコピー double zet(double d); double pow(double base,int n); double m(int j); double t(int j); double h(int j); double a(int j,int k); double P(int j,double xx); double A(int k,double xx,int n); double q(double xx,int n); void add_point(int pt[],int py[],int i); int count_point(int pt[],int i); int select_axis(int i); int set_point(int i); public: void set(int px[],int pf[],int n); void draw(HDC hdc,BOOL maru); void force(int px[],int pf[],int *n); }; #endif