# Combined Translation and Rotation of a disk possible? material and references?

I am considering building a robot that can rotate and move at the same time. Since it's just a theoretical idea at the time and I need read up material, I thought I would ask here.

I am thinking of a two wheeled robot that can spin on the spot. Fairly straight forward. If this robot needs to move from A to B. Most people would suggest to stop spinning circularly, point the direction of motion and move there through linear translation.

I am wondering if there is a way to do that without stopping the spin and pointing in a specific direction. Someway of combining both the translational and rotational motion of the device to move the whole system in a particular direction.

I am guessing that rather than both wheels spinning at a constant speed, such as during rotation, there would be two sinusoidal wave with a phase shift of some sort that will cause the robot to "drift" in the direction of choice.

I have some vague ideas, but would like more understanding about it or if it is even possible. I am not even sure if this sort of motion has a name. I tried google, but most of the hits I am getting are about a disk rolling down a plank kind of motion.

any references, books, articles, videos or any other material would be of great use

-

A two-wheeled robot cannot move in the direction parallel to the axis of its wheels. Therefore, it cannot move in an arbitrary direction independent of its rotation; it is not holonomic. This implies that your robot cannot move in a straight line while spinning about its center (as a weightless/frictionless body would). However, it sounds like you are OK with some wobbling, so I'll try to give some practical ways to think about such motions.

Let's assume you have perfect constant-speed motors and wheels. The tread of each wheel is being driven by each motor at some velocity; let's write these velocities as $(l,r)$.

1. First, consider your robot spinning in place clockwise - the left wheel running forward and one wheel back at the same speed. Call this condition $(+1 \text{ u/s}, -1\text{ u/s})$ where $\mathrm{u}$ is some distance unit and $\mathrm{s}$ is seconds.

2. Then, separately, consider your robot moving straight forward for a distance $1 \text{ u}$. If the robot is aimed in that direction, then this consists of running the motors at $(+1 \text{ u/s}, +1\text{ u/s})$ for 1 second. Or, equivalently, it could be done with +2 u/s for 1/2 second; speed × time = distance, of course.

Consider doing both motions simultaneously, by summing the velocities the motors should run at; at any given moment, this also results in summing the motions the robot is making (given an infinitesimal moment, the robot is not actually turning, so everything is linear). At any given moment, the robot will have a directly-forward velocity due to motion 2. At the same time, which direction is "forward" is changing.

Over any given time interval, the total change in position $∆s$ of the robot will be the integral of its velocity vector, which can be considered as its forward velocity $v$ times the unit vector which is its forward direction.

$$∆s = ∫_{t_0}^{t_1} v\langle \cos θ, \sin θ\rangle dt$$

(If you didn't understand that, don't worry about it; if you did, great.)

Now, you presumably want your robot to actually move in some specific direction. Suppose your robot performs motion 1 continuously, and additionally motion 2 only during the periods when it is almost pointed in that direction (i.e. during some range of angles $(θ - ε, θ + ε)$. You can consider the robot's $∆s$ during that time as being the sum of two components: one in the wanted direction of motion, and the other as perpendicular to it. Since the interval over which you are moving forward is symmetric about the desired direction, the perpendicular components will cancel out!

If you want less jerky motion, then you don't have to use a sharp-edged interval; you can gradually add the forward component as the angle gets closer to the desired one, as long as you do the same in reverse as it goes past. In fact, you can use any function of the angle which is periodic and even (some will result in no progress or going backward, but none will go in the wrong direction); a sine would be such a function.

So, for example, you could drive your motors with $(a + b\cos(θ_t - θ), -a + b\cos(θ_t - θ))$, where $θ$ is the current angle of the robot, $θ_t$ is the direction you want to make progress in, and $a$ and $b$ are arbitrary constants which set how fast the spins and wobbles are. Cosine (or anything which alternates positive and negative over one period) is a particularly good choice as the robot will drive both “forward” and “backward” to make progress in the wanted direction. Changing $a$ and $b$ will affect how the wobble looks.

If you want the robot to move a specific distance, then you will need to make the equation above more useful. Let $f$ be the function specifying forward motion (in the above example, $f(θ) = b\cos(θ_t - θ)$):

$$∆s = ∫_{t_0}^{t_1} f(θ)\langle \cos θ, \sin θ\rangle dt$$

If rotation (motion 1) is occurring with a wheel tread velocity $a$ (as in the motor formula I gave above), and the robot's radius (half the distance between wheels) is $r$, then the rotation speed of the robot is $a/r$, and the rotation angle is $θ_0 + (t - t_0)/r$. Therefore, $dθ/dt = a/r$, so we can rewrite the integral as

$$∆s = \frac{r}{a} ∫_{\frac{a}{r}θ_0}^{\frac{a}{r}θ_1} f(θ)\langle \cos θ, \sin θ\rangle dθ$$

If you evaluate this integral (with your particular $f$) over an interval of length $2π$, then you will find the change in position of the robot after one revolution. You can then use that value (specifically, the length of the vector $∆s$) to find the number of whole revolutions to move a given distance, and by changing the scale of $f$ (the parameter $b$ in my example), you can scale that distance per revolution.

-

This is actually fairly straightforward, at least based on what you've described. You have a left wheel which moves at an angular velocity $\omega_L$ and a right wheel which moves at an angular velocity $\omega_R$. The distance traveled by the edge of each wheel in a time $t$ is $r\omega t$, where $r$ is the radius of the wheel, and accordingly $r\omega t$ is the distance that side of the robot will move along the floor. If one wheel is spinning faster than the other, one side of the robot will move further than the other, which will cause it to move in a circle.

When the robot moves in a circle, the contact point of each wheel traces out a circular arc on the floor. Suppose the robot is turning right, then the left wheel will trace out an arc of radius $R_L = R + d/2$ (where $d$ is the width of the robot) and the right wheel will trace out an arc of radius $R_R = R - d/2$, and the ratio of the circumferences of these arcs $\frac{\theta R_R}{\theta R_L}$ has to equal to ratio of the distances traveled by the wheels $\frac{r\omega_R t}{r\omega_L t}$:

$$\frac{R - \frac{d}{2}}{R + \frac{d}{2}} = \frac{\omega_R}{\omega_L}$$

So you can get the robot to move to the right in a circular arc of any given radius $R$ (as measured from its center) by spinning its wheels at different angular speeds, whose ratio satisfies the equation above. Or you can have it move in a leftward circular arc by swapping the two angular velocities. The two extremes are $R = 0$, or $\omega_L = -\omega_R$ (wheels spinning in opposite directions at the same speed), which corresponds to the robot spinning in place in a circle, and $R \to \infty$, or $\omega_L = \omega_R$, which corresponds to straight line motion.

If you want to get the robot to move in an arbitrary, non-circular path, you can use the fact that any path has a radius of curvature at each point. Suppose your path is a parametric function of some parameter $t$, so that you want the coordinates of the robot at parameter $t$ to be $x(t)$ and $y(t)$. Then the radius of curvature at each point can be calculated as

$$R(t) = \frac{\Bigl(x'(t)^2 + y'(t)^2\Bigr)^2}{x'(t)y''(t)-x''(t)y'(t)}$$

Using this you can determine the ratio of angular velocities $\frac{\omega_R(t)}{\omega_L(t)}$ at each value of $t$, which will set the shape of the path. Then you just have to scale the rate at which $t$ increases with time so that the path comes out to the size you want.

-
Thanks for the quick reply David. Can you explain the second part of the parametric function? Lets say I am spinning the robot on the spot. I want to "Move" at a 45degree angle (lets say) how/where do I get the coordinate from that I can plug into the above equation? – Chaitanya Oct 30 '11 at 13:50
I don't understand what you're asking about here... what is this 45 degree angle? (Between what two directions?) And are you talking about a situation where the robot is spinning and then you stop its rotation and make it travel in some direction? Your question implied that you wanted to do something more than that. – David Z Oct 30 '11 at 16:59
You are right. Saying 45 degrees does sound arbitrary, and it is with respect to the robot itself. But lets say the robot is on the floor which is our grid, at the origin. Both wheels are spinning at constant speed and it is merrily spinning on the spot. Now I want to move it 45 degrees to the origin. Or along the +ve X or Y axis or the -ve X or Y axis. How should I adjust the relative speeds of the wheels to make it drift/hover in that direction without stopping the rotation. Even if it doesn't drift in a straight line, can i made it sinusoidally move it along a 45* path for example. – Chaitanya Oct 31 '11 at 0:15
Ah, I misunderstood your question. I'll edit in an addition to my answer soon. – David Z Oct 31 '11 at 0:50