Gravitational Potential Energy Earth Question

Gravitational Potential Energy (U) = -(GMm)/R
Also, U = mgy.
I need help making a connection between these two equations. For U = -(GMm)/R, it is saying that because R = radius of the Earth, an object on the surface of the Earth has a gravitational potential energy, correct?
U = mgy seems to be saying otherwise because y = 0.
Can anybody explain this to me?

Doc Al
Mentor
What matters when talking about gravitational PE is the change in PE measured from some reference point.
Gravitational Potential Energy (U) = -(GMm)/R
Note that R stands for the distance between the two masses. This formula assumes that the zero PE point is at R = infinity, when the masses are infinitely far apart.
Also, U = mgy.
This formula is useful near the Earth's surface. It takes the zero PE point to be wherever you set y = 0.
I need help making a connection between these two equations. For U = -(GMm)/R, it is saying that because R = radius of the Earth, an object on the surface of the Earth has a gravitational potential energy, correct?
Right. If you plug in R = Radius of Earth, it will give you the gravitational PE compared to when they were infinitely far away.
U = mgy seems to be saying otherwise because y = 0.
That formula uses y = 0 as a reference, so you can't directly compare those results.

But as I said up front, what really matters is the change in PE. For example, if you lift the mass m from y = 0 to y = h, what's the change in gravitational PE? Using the second equation, you'll get ΔU = mgΔy = mgh.

You could use the first equation to measure that change in PE. In that case you'd need to compare the PE when the masses moved from R = Radius of Earth (Re) to R = Re + h. Like so:
ΔU = [-(GMm)/(Re + h)] - [-(GMm)/(Re)]

For values of h near the Earth's surface where h << Re, you can work it out and find that
ΔU = (GMm)/(Re)2*h = mgh

You get the same answer either way. (If h is too big, then the value of g will vary too much, making the mgy version unusable.)

Thanks so much for the answer. It makes sense now. =)

Something just came up again. What if I wanted to conserve mechanical energy? Do I use U=mgh or U=-(GMm)/R? I've noticed that I use U=mgh for objects close to the Earth and is falling to the surface of the Earth and U=-(GMm)/R for objects really far away from Earth. Can someone clarify this for me?

Doc Al
Mentor
Something just came up again. What if I wanted to conserve mechanical energy? Do I use U=mgh or U=-(GMm)/R? I've noticed that I use U=mgh for objects close to the Earth and is falling to the surface of the Earth and U=-(GMm)/R for objects really far away from Earth. Can someone clarify this for me?
U = mgh only applies when the object is near the surface of the Earth, where g is relatively constant. When the object is far enough from the surface that variation in g matters, you'll need the other formula.