Suppose the curve is given implicitly by two equations: <br />
f(x, y, z) = 0<br />
\\ f(x, y, z) = 0<br /> Then the equations of motion are <br />
m\ddot{x} = F_x + \lambda f_x + \mu g_x<br />
\\m\ddot{y} = F_y + \lambda f_y + \mu g_y<br />
\\m\ddot{z} = F_z + \lambda f_z + \mu g_z<br /> Where F_x, \ F_y, \ F_z are projections of the external force onto the coordinate axes, and f_x, \ f_y, \ f_z, \ g_x, \ g_y, \ g_z are partial derivatives of f, \ g, and \lambda, \ \mu are Lagrange multipliers (which can be used to determine the reaction force). Note that with the equations of the curve you have five equations, and you have five unknowns. This is, however, usually too cumbersome. What is done instead, the natural coordinate frame of the curve are used. At any point of the curve, there is a tangent vector, a normal vector, and a binormal vector. Together they are always mutually perpendicular. Because the curve is given, they can easily be computed at any point on the curve. So the motion is treated in this coordinate frame.<br />
m\frac {d^2s} {dt^2} = F_{\tau}<br />
\\ \frac {mv^2} {\rho} = F_n + N_n<br />
\\ 0 = F_b + N_b<br /> where F_{\tau}, \ F_n, \ F_b are projections of the external force onto the tangent, normal, and binormal vectors; N_n, \ N_b are projections of the reaction force; s is the distance along the curve; \rho is the radius of curvature. In principle, you need only the first equation to integrate the system and obtain the law of motion. The other two are only required if you need to know the reaction force.