Minimum-time trajectory planning of mechanical manipulators under dynamic constraints