create a_regress_simple_evar
[liba.git] / lua / src / trajpoly3.h
blob05a5f6b3b63d5a744f4db77fe70bb32cda148aed
1 /***
2 cubic polynomial trajectory
3 @classmod a.trajpoly3
4 */
6 #ifndef LUA_LIBA_TRAJPOLY3_H
7 #define LUA_LIBA_TRAJPOLY3_H
9 #include "a.h"
11 /***
12 cubic polynomial trajectory
13 @field p coefficients of position
14 @field v coefficients of velocity
15 @field a coefficients of acceleration
16 @table a.trajpoly3
18 #if defined(__cplusplus)
19 extern "C" {
20 #endif /* __cplusplus */
22 /***
23 constructor for cubic polynomial trajectory
24 @tparam number ts difference between final time and initial time
25 @tparam number p0 initial position
26 @tparam number p1 final position
27 @tparam[opt] number v0 initial velocity
28 @tparam[opt] number v1 final velocity
29 @treturn a.trajpoly3 cubic polynomial trajectory userdata
30 @function new
32 int liba_trajpoly3_new(lua_State *L);
34 /***
35 generate for cubic polynomial trajectory
36 @tparam number ts difference between final time and initial time
37 @tparam number p0 initial position
38 @tparam number p1 final position
39 @tparam[opt] number v0 initial velocity
40 @tparam[opt] number v1 final velocity
41 @treturn a.trajpoly3 cubic polynomial trajectory userdata
42 @function gen
44 int liba_trajpoly3_gen(lua_State *L);
46 /***
47 calculate position for cubic polynomial trajectory
48 @tparam number x difference between current time and initial time
49 @treturn number position output
50 @function pos
52 int liba_trajpoly3_pos(lua_State *L);
54 /***
55 calculate velocity for cubic polynomial trajectory
56 @tparam number x difference between current time and initial time
57 @treturn number velocity output
58 @function vel
60 int liba_trajpoly3_vel(lua_State *L);
62 /***
63 calculate acceleration for cubic polynomial trajectory
64 @tparam number x difference between current time and initial time
65 @treturn number acceleration output
66 @function acc
68 int liba_trajpoly3_acc(lua_State *L);
70 #if defined(__cplusplus)
71 } /* extern "C" */
72 #endif /* __cplusplus */
74 #endif /* trajpoly3.h */