4

Blog | Gravitational Force Interaction | MATLAB Helper ®

 3 years ago
source link: https://matlabhelper.com/blog/matlab/gravitational-force-interaction/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

Introduction

The Gravitational Force is one of the oldest forces that has been discovered by Physicists and is still baffling on some levels. Sir Isaac Newton was the first to define the force mathematically. He presented an analytical relation between the magnitude of the force and the masses interacting and the distance of separation between them. In his first law of motion, Newton said that force is the amount of change in momentum producing it. (i.e., a force applied to an object has an equal and opposite reaction) Hence, Gravitational force results from mass and momentum interaction according to gravitation equations as stated below.

Originally, gravitational force was defined by Newton as a result of two masses. It was discovered that such a situation typically did not occur in nature. Still, the realization didn't stop scientists from exploring further into this force which would eventually become known as gravitational interaction. The main problem with this theory is its inability to predict experimental results accurately when another body was brought into play. Eventually, it was discovered that an increase in the number of objects (m1, m2) involved in the equation would prove to be more accurate.

So far, there hasn't been any experimentation conducted to test the validity of this theory or any conservation of energy equations in general. How can one be able to confirm a conservation equation if they haven't conducted any experiments? The closest thing to an experiment would be observations. We can confirm that gravitational interaction exists between two bodies, which means we have confirmation about the conservation of energy for sure. However, keeping these problems for the core Physicists, we will just look upon the basic form of the equation and use it to describe motions using MATLAB.

Simulating Gravitational Force in free space

The Gravitation Equation is an approximation that has been derived based on Newton's Law of Universal Gravitation. In Physics, Newton's Law states that each point mass attracts every other point mass by a directly proportional force to the product of their masses and inversely proportional to the square of the distance between them. The proportionality constant, the gravitational constant, in this case, has a very precise value of devised by very sophisticated experimentations.

While two bodies in free space is a very trivial and straightforward model of Gravitational force interaction, it is fundamental in describing every other complex motion. So, we will begin our simulation journey by having a mass of 10kg fixed in spatial dimensions at a point and a free body interacting in its Gravitational field. A free-body model is one where no external forces act on it andare simply subject to its mass and gravity.

We have our object of mass 10kg and an empty space where another object of unspecified mass will be our free body. Since this is a Newtonian simulation, with every tick of time, the force applied to the mass will be equal to the Gravitational constant * mass of Earth * distance between them. Since we are not computing acceleration but using the time taken to reach an equilibrium state, we will need a function that calculates how long it takes a given mass at rest to come to rest (i.e., distance reduction).

While the formula is descriptive enough for calculations, it cannot be used directly for simulating the scenario. The formula must be converted into an ordinary differential equation (ODE) format describing the conditions or forces it depends on. So, the ODE analog of the equation is as shown below.

where g also depends upon the masses concerned and the distance between the objects, as already mentioned before. Here is the respective MATLAB code for using the ODE for simulating the scenario described above.


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK