Perpetual motion in electric dipole restricted to a circular path with a charge at the centre This problem is from Griffith's Introduction to Electrodynamics (4th Ed.), Problem 4.31.

A point charge $Q$ is "nailed down" on a table. Around it, at radius $R$, is a frictionless circular track on which a dipole $\mathbf{p}$ rides, constrained always to point tangent to the circle. Use $\mathbf{F} = (\mathbf{p}\cdot\nabla)\mathbf{E}$ and show that the electric force on the dipole is
$$\mathbf{F} = \frac{Q}{4\pi\epsilon_0} \frac{\mathbf{p}}{R^3}$$
Notice that this force is always in the "forward" direction (you can easily confirm this by drawing a diagram showing the forces on the two ends of the dipole). Why isn't this a perpetual motion machine?$^{21}$
$^{21}$ This charming paradox was suggested by K. Brownstein.

I have done the first part and shown that the force on the dipole indeed is equal to what is given in the question. But can anyone help me with the perpetual motion bit? And for the circular motion, where is the centripetal force coming from? Is it due to the constraint?
 A: Let's write the electric field, $\vec E$
$$\vec E = \dfrac {kQ}{r^2}\hat r$$
So, we know the force on the dipole,
$$\begin{align*}\vec F &=(\vec p \cdot \nabla) \vec E\\&=\dfrac {kQ}{r^3} \dfrac{ \partial }{\partial \theta}\hat r\\&=\dfrac {kQ\vec p}{r^3}\\\Rightarrow \vec F &= \dfrac {Q}{4\pi \epsilon_0}\dfrac{\vec p}{R^3}\end{align*}$$
Now for the second part, for the dipole to go anticlockwise, $\hat\theta$ direction, there must be a centripetal acceleration and a clockwise torque provided be the constraint force and the charge $Q$ respectively. And this would oppose the tangential "forward" force, thus slowing down the dipole (or rather preventing it from starting to rotate) 
Griffith puts it beautifully as:

To keep the dipole going in a circle, there must be a centripetal force exerted by the track (we may as well
  take it to act at the center of the dipole, and it is irrelevant to the problem), and to keep it aiming in the
  tangential direction there must be a torque (which we could model by radial forces of equal magnitude acting at
  the two ends). Indeed, if the dipole has the orientation indicated in the figure, and is moving in the $\hat\theta$ direction,
  the torque exerted by $Q$ is clockwise, whereas the rotation is counterclockwise, so these constraint forces must
  actually be larger than the forces exerted by Q, and the net force will be in the “backward” direction—tending
  to slow the dipole down. [If the motion is in the $−\hat\theta$ direction, then the electrical forces will dominate, and the
  net force will be in the direction of p, but this again will tend to slow it down.] 

