2 cubic polynomial trajectory
6 #ifndef LUA_LIBA_TRAJPOLY3_H
7 #define LUA_LIBA_TRAJPOLY3_H
12 cubic polynomial trajectory
13 @field p coefficients of position
14 @field v coefficients of velocity
15 @field a coefficients of acceleration
18 #if defined(__cplusplus)
20 #endif /* __cplusplus */
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
32 int liba_trajpoly3_new(lua_State
*L
);
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
44 int liba_trajpoly3_gen(lua_State
*L
);
47 calculate position for cubic polynomial trajectory
48 @tparam number x difference between current time and initial time
49 @treturn number position output
52 int liba_trajpoly3_pos(lua_State
*L
);
55 calculate velocity for cubic polynomial trajectory
56 @tparam number x difference between current time and initial time
57 @treturn number velocity output
60 int liba_trajpoly3_vel(lua_State
*L
);
63 calculate acceleration for cubic polynomial trajectory
64 @tparam number x difference between current time and initial time
65 @treturn number acceleration output
68 int liba_trajpoly3_acc(lua_State
*L
);
70 #if defined(__cplusplus)
72 #endif /* __cplusplus */
74 #endif /* trajpoly3.h */