Solve the positions of two masses gravitating toward each other

  • Thread starter Happiness
  • Start date
  • Tags
    Two masses
In summary: You can do a few simple algebraic manipulations (like turn the integrand into the square root of a single fraction) to match an integral in an integral table.It's not that Mathematica is wrong, but it is not giving the solution that you need or is useful. Mathematica is useful, but as you've just discovered, you shouldn't always trust its output.
  • #1
Happiness
679
30
Consider two stationary masses, each 1 kg, placed a distance ##d_0## apart. Find the position ##x(t)## of each mass in terms of time ##t##. Consider only gravitation without relativistic effects.

Let the distance between the two masses at time ##t## be ##d(t)##. If we set the origin of our coordinate system at the centre of mass of the system, then ##d(t)=2\,x(t)## since the system is symmetrical about the origin.

Gain in kinetic energy = loss in gravitational potential energy
$$\frac{v^2}{2}=\frac{G}{d}-\frac{G}{d_0}$$
Substituting ##d=2x## and ##d_0=2x_0##,
$$v^2=\frac{G}{x}-\frac{G}{x_0}$$, where ##x_0=x(0)## is the initial ##x##.

$$\int\frac{1}{\sqrt{\frac{G}{x}-\frac{G}{x_0}}}dx=\int dt$$

Q1. We expect ##x<x_0## for ##t>0##. But when ##x<x_0##, LHS is complex while RHS is real. What's wrong?

Integration on LHS: http://www.wolframalpha.com/input/?i=integrate+(G/x-G/u)^(-1/2)dx (where ##u## represents ##x_0##)

Q2. When I solve the question using forces, I get a different expression for ##v^2## (shown below). What's wrong?

$$\ddot{x}=-\frac{G}{d^2}$$
Substituting ##d=2x##,
$$\ddot{x}=-\frac{G}{4x^2}$$
$$\frac{dv}{dt}=\frac{dx}{dt}\frac{dv}{dx}=-\frac{G}{4x^2}$$
$$\int vdv=\int-\frac{G}{4x^2}dx$$
$$\frac{v^2}{2}=\frac{G}{4x}-\frac{G}{4x_0}$$
$$v^2=\frac{G}{2x}-\frac{G}{2x_0}$$, which differs from the above equation by a factor of ##\frac{1}{2}##.
 
Last edited:
Physics news on Phys.org
  • #2
Happiness said:
Gain in kinetic energy = loss in gravitational potential energy
$$\frac{v^2}{2}=\frac{G}{d}-\frac{G}{d_0}$$
Substituting ##d=2x## and ##d_0=2x_0##,
$$v^2=\frac{G}{x}-\frac{G}{x_0}$$, where ##x_0=x(0)## is the initial ##x##.

$$\int\frac{1}{\sqrt{\frac{G}{x}-\frac{G}{x_0}}}dx=\int dt$$
Your first equation is not dimensionally consistent, it looks like you're missing a factor of ##m##.
Happiness said:
We expect x<x0x<x0xt>0t>0t>0. But when x<x0x<x0x LHS is complex while RHS is real
Mathematica is treating this integral as a contour integral in the complex plane. This is why you are seeing i's everywhere. For ##x<x_{0}## however, the integral should be real. Try and solve the integral by hand instead of relying on wolfram.
 
  • #3
Happiness said:
Q2. When I solve the question using forces, I get a different expression for ##v^2## (shown below). What's wrong?

$$\ddot{x}=-\frac{G}{d^2}$$
Substituting ##d=2x##.
$$\ddot{x}=-\frac{G}{4x^2}$$
$$\frac{dv}{dt}=\frac{dx}{dt}\frac{dv}{dx}=-\frac{G}{4x^2}$$
$$\int v\frac{dx}{dv}=\int-\frac{G}{4x^2}dx$$
$$\frac{v^2}{2}=\frac{G}{4x}-\frac{G}{4x_0}$$
$$v^2=\frac{G}{2x}-\frac{G}{2x_0}$$, which differs from the above equation by a factor of 2.
Use ##\ddot{d}## instead of ##\ddot{x}## in the first line. Also, I'm not sure if the integral is correct: one of the derivatives is inverted.
 
  • #4
NFuller said:
Your first equation is not dimensionally consistent, it looks like you're missing a factor of ##m##.

I let ##m=1## kg. If you like, you could take it that ##m## is absorbed into ##G## such that ##G## now has a dimension of its usual dimension ##\times## the dimension of ##m##.

NFuller said:
Mathematica is treating this integral as a contour integral in the complex plane. This is why you are seeing i's everywhere. For ##x<x_{0}## however, the integral should be real. Try and solve the integral by hand instead of relying on wolfram.

I tried it. It is still complex.
 
  • #5
Happiness said:
I tried it. It is still complex.
How? The integrand is real for ##x<x_{0}##.
 
  • #6
NFuller said:
Use ##\ddot{d}## instead of ##\ddot{x}## in the first line. Also, I'm not sure if the integral is correct: one of the derivatives is inverted.

I think ##\ddot{x}## is correct, because I am using ##ma=F##, and ##a=\ddot{x}## and ##F## depends on ##d##, the distance between the two masses.

Oh yes, there was a typo in the third last line. It has been corrected. But the answer still differs by a factor of ##\frac{1}{2}##.
 
Last edited:
  • #7
NFuller said:
How? The integrand is real for ##x<x_{0}##.

The thing inside the log is complex. After applying log to it, we get a complex number with a non-zero real part. This real part when multiplied by the ##i## in front gives us a complex number.
 
  • #8
Happiness said:
I think ¨xx¨\ddot{x} is correct, because I am using ma=Fma=Fma=F, and a=¨xa=x¨a=\ddot{x} and FFF depends on ddd, the distance between the two masses.
##x## and ##d## are in different coordinate frames, I would be cautious of mixing them.
Happiness said:
The thing inside the log is complex. After applying log to it, we get a complex number with a non-zero real part. This real part when multiplied by the ##i## in front gives us a complex number.
I mean how can you integrate a real function and end up with a complex value? If the integrand is real over the region of integration, then the integral must also be real.
 
  • #9
NFuller said:
##x## and ##d## are in different coordinate frames, I would be cautious of mixing them.

I thought ##x## and ##d## are in the same coordinate frame. No?

NFuller said:
I mean how can you integrate a real function and end up with a complex value? If the integrand is real over the region of integration, then the integral must also be real.

I see. But it doesn't look like it can be integrated by hand easily. Can the math involved be done by a second-year undergraduate?

And how could Wolfram Alpha end up with a wrong answer? I thought its answer would still be correct as long as we use the correct domain of ##x##?
 
  • #10
Happiness said:
I thought ##x## and ##d## are in the same coordinate frame. No?
I see. But it doesn't look like it can be integrated by hand easily. Can the math involved be done by a second-year undergraduate?

And how could Wolfram Alpha end up with a wrong answer? I thought its answer would still be correct as long as we use the correct domain of ##x##?
d is meauserd with respect to the moving object, x is measured with respect to the center of mass.

You can do a few simple algebraic manipulations (like turn the integrand into the square root of a single fraction) to match an integral in an integral table.

It's not that mathematica is wrong but it is not giving the solution that you need or is useful. Mathematica is useful, but as you've just discovered, you shouldn't always trust it.
 
  • #11
NFuller said:
d is meauserd with respect to the moving object, x is measured with respect to the center of mass.

x is measured in the reference frame where the center of mass of the system (CMS) is stationary and in the coordinate system when the CMS is the origin, and x is measured from the origin to one of the masses.

d is measured in the same reference frame and coordinate system, but d is measured from one mass to the other mass, and by symmetry, ##d=2x##.

So I don't understand why you say x and d are measured in different reference frames or coordinate systems. And in both measurements of x and d, the object(s) is moving.

NFuller said:
It's not that mathematica is wrong but it is not giving the solution that you need or is useful. Mathematica is useful, but as you've just discovered, you shouldn't always trust it.

But Mathematica's answer seems wrong because when I substitute ##x<x_0##, it gives me a complex number when it should be real.
 
  • #12
Happiness said:
d is measured in the same reference frame and coordinate system,
No because the origin of d's coordinate system moves with respect to the center of mass. The origin of x's coordinate system does not.
Happiness said:
But Mathematica's answer seems wrong because when I substitute x<x0x<x0x
Right, so you need to just do it by hand.
 
  • #13
NFuller said:
No because the origin of d's coordinate system moves with respect to the center of mass. The origin of x's coordinate system does not.

I suppose you are taking the origin of ##d##'s coordinate system to be at one of the moving masses, right? But there is no need to. I am taking the origin of d's coordinate system to be at the centre of mass of the system (CMS) and always so at all times. The CMS never moves, but the left end and right end of ##d## are always moving (after the masses are released).
 
  • #14
I've found the mistake! This equation is wrong.

Happiness said:
Gain in kinetic energy = loss in gravitational potential energy
$$\frac{v^2}{2}=\frac{G}{d}-\frac{G}{d_0}$$
 

Related to Solve the positions of two masses gravitating toward each other

1. How do you calculate the gravitational force between two masses?

The gravitational force between two masses can be calculated using the equation F = G(m1m2)/r^2, where G is the gravitational constant, m1 and m2 are the masses of the two objects, and r is the distance between them.

2. What is the relationship between mass and gravitational force?

The gravitational force between two objects is directly proportional to the product of their masses. This means that as the mass of one object increases, so does the gravitational force between the two objects.

3. How does the distance between two masses affect their gravitational force?

The gravitational force between two masses is inversely proportional to the square of the distance between them. This means that as the distance between the two objects increases, the gravitational force decreases.

4. What is the significance of the gravitational constant in this equation?

The gravitational constant, denoted by G, is a fundamental constant that relates the strength of the gravitational force to the masses and distance between two objects. Its value is approximately 6.67 x 10^-11 Nm^2/kg^2.

5. Can this equation be applied to objects of any size?

Yes, this equation can be applied to objects of any size, as long as their masses and distances are known. However, for very large or small masses, the effects of other factors such as relativity may need to be considered.

Similar threads

  • Mechanics
Replies
3
Views
1K
  • Mechanics
Replies
30
Views
846
Replies
68
Views
3K
  • Mechanics
Replies
18
Views
2K
  • Mechanics
Replies
20
Views
977
  • Introductory Physics Homework Help
Replies
3
Views
908
  • Advanced Physics Homework Help
Replies
9
Views
2K
  • Classical Physics
Replies
0
Views
215
Replies
4
Views
2K
  • Advanced Physics Homework Help
Replies
3
Views
571
Back
Top