Loop-the-loop question 
Problem: The marble rolls down the track and around a loop-the-loop of radius R. The marble has mass $m$ and radius $r$. What minimum height $h$ must the track have for the marble to make it around the loop-the-loop without falling off?
  Express your answer in terms of the variables $R$ and $r$.

I found this solution to be very reasonable:
$$mg = m a_c = m \frac{V^2}R $$
which leads to
$$V = \sqrt{g R} $$
The energy at the top of the loop KE = Delta PE
$$\frac12 m V^2 + m g (2R) = m g h \\
\frac12 (g R) + g (2R) = g h \\
\left(\frac12+2\right) R = h $$
so $h = 5/2 R $
However the correct answer is actually $\frac52(R-r)$, I think it's because the radius of the loop is measured from the center of the ball rolling on it, so the they subtracted $R$ from $r$, but how would you derive that? I tried the same steps just using $R-r$ instead of $R$ but I got a different answer.
 A: Your expression for the velocity looks right; but we have to get a few other things taken care of.
First - the center of the marble doesn't move from 0 to 2R, it moves from r to 2R-r - so the potential energy due to this is smaller than mg(2R) which is what you had in your expression.
On the other hand, you need to take account of the energy of the sphere rolling (which is stated explicitly). The moment of inertia for a solid sphere (the usual case for a "marble") is
$$I=\frac25 m r^2 \\$$
This leads to rolling energy
$$E=\frac12I\omega^2=\frac12\frac25 m r^2 (\frac v r)^2 = \frac15mv^2\\$$
Thus your energy equation has to be corrected to
$$\frac12 m v^2 + m g (2R-2r) + \frac15mv^2 = m g h \\$$
Also - note that the marble is moving in a path with radius R-r not radius R; you need to take that into account when you compute the limiting velocity ("fast enough to stick to the track") - you have to put R-r where you have R in your velocity equation:
$$\frac{mv^2}{R-r}=mg\\
v=\sqrt{g(R-r)}$$
Combining these:
$$\frac{7}{10}mg(R-r) +2mg(R-r)=mgh\\
h = \frac{27}{10}(R-r)$$
Note that it is sometimes said that "you can ignore the rotational energy of the marble if it is very small", but that is emphatically not true - the rotational energy for a solid sphere is always 2/5 of the (linear) kinetic energy, regardless of the size of the marble. It can therefore only be ignored for the case of a (frictionless) sliding object.
Finally - since no physics problem is complete without a diagram:

This shows clearly where the R-r term is coming from.
Thus if you ignore the rolling, the diagram explains the "correct" answer (which in a way was your question). If you include rolling, then you need to modify the solution as shown.
A: First of all, I would like to say that the answer Floris gave is the correct way to do the problem you've set forward, but I thought it worthwhile to note that the result ${5 \over 2}(R-r)$ is the answer if, rather than rolling a marble down the track, you are sliding a cube. If this problem comes from a textbook, there were some unstated assumptions in providing the solution, namely ignoring the rotational energy.
Thus, with an object sliding (i.e. no rotational energy present) the conservation of energy equation is this:
$$ {1 \over 2} mv^2+mg(2R-r)=mg(h+r)$$Where $$v= \sqrt{g(R-r)}$$
This will simplify to the solution you expect.
