I'm developing some python code that controls an end effector moving in a two-dimensional plane (XY). It moves through a list of points sequentially and I'd like to estimate the time it will take as precisely as possible.
My constant variables are:
Max_Speed: 30 mm/s Max_Acceleration: 60 mm/s^2 Max_Jerk: 20 mm/s
For simplicity, we can assume the acceleration curve to be linear. In practice, it's much closer to a sigmoid curve.
For now, let's assume the end-effector will move from the origin to another point.
pt1: 0,0 pt2: 20,20
My current implementation only takes Max speed into account, any improvement would be hugely appreciated. However, given my very limited mathematical background, I'll favour simplicity at the expense of accuracy. A pythonic explanation would also be hugely appreciated.
distance = euclidean_distance(pt1, pt2) = 28.284271 time = distance / Max_Speed = 28.284271 / 30 = 0.9428090333
For the above example, it would be reasonable to assume that the maximum speed was not reached and therefore the calculation is off. The end effector carries a lot of mass, hence the relatively low acceleration value and the assumption that the maximum speed was not reached.