Finding position of simple pendulum?

In summary, the conversation is about creating a program to model a simple pendulum. The person is having trouble solving for the position over time and is seeking help with specifying parameters such as string length, acceleration due to gravity, mass, and angle. They also mention that they are using a pendulum with a dampening force. The solution involves using Newton's second law to calculate the restoring and resistive forces, and then integrating to solve for the angle as a function of time. The value for the dampening parameter is also mentioned, and the person offers advice on how to solve for the initial parameters.
  • #1
DevonV
4
0
I'm trying to write a program to model a simple pendulum, and I'm having some trouble seeing how I would solve for the position w.r.t. time.

I would ultimately like to be able to specify a length of string, acceleration due to gravity, mass (though I know it has no effect on the period) and angle it's pulled back.

Any help would be great, thanks!

PS: I don't think this qualifies as homework because I'm doing it for fun, but I'm very sorry if I'm wrong!:smile:
 
Physics news on Phys.org
  • #2
I'm assuming you are using a pendulum with a dampening force such as air resistance. If not you will be able to exclude the resistive force parameters from this adaptation of Newtons second law, allowing your pendulum to follow free oscillation. the angle in this case is equal to phi and anything following after the symbol [tex]\cdot[/tex] is meant to be the time derivative of that variable.
Force=m(L [tex]\cdot[/tex] [tex]\cdot[/tex][tex]\phi[/tex])=restoring force+resistive force
=-mgsin([tex]\phi[/tex])-2m[tex]\sqrt{g/l}[/tex](L [tex]\cdot\phi[/tex]) [note: the rsistive force in this case is a obscure example. you will need to create your own depending on what you would like your program to do.

from here you will integrate solving for your angle as a function of time.
[tex]\phi[/tex](t)=(A+Bt)e^(-[tex]\sqrt{g/l}[/tex]t)

[note: the value [tex]\sqrt{g/l}[/tex] is considered your dampening parameter which i defined in this case. if you chose to exclude a dampening force or use a different dampening scenario this will not be similar]

to solve for A and B you need to use the first equation and the previous in combination and also set initial parameters. hope this helped!
 
  • #3


I would first like to commend you for taking on this project for fun. Science and programming can be very enjoyable and fulfilling hobbies. Now, let's discuss your question.

To solve for the position of a simple pendulum, you will need to use the equation of motion for a pendulum, which is:

θ(t) = A*cos(√(g/L)*t + φ)

Where:
θ(t) is the angular position of the pendulum at time t
A is the amplitude (maximum displacement)
g is the acceleration due to gravity
L is the length of the pendulum
φ is the phase constant (initial angle)

To solve for the position w.r.t. time, you will need to know the values of A, g, L, and φ. You can specify the length of the string, acceleration due to gravity, and initial angle. The amplitude can be calculated using the initial angle and length of the string. Once you have all the values, you can plug them into the equation and solve for θ(t) at different time intervals.

Additionally, you can also use a numerical integration method, such as the Euler method, to solve for the position at different time intervals. This method involves breaking down the motion into small time intervals and calculating the position at each interval.

I hope this helps you in your programming project. Keep exploring and experimenting, and don't hesitate to reach out for further assistance. Best of luck!
 

FAQ: Finding position of simple pendulum?

1. What is a simple pendulum?

A simple pendulum is a weight attached to a rod or string that is suspended from a fixed point. It is used to demonstrate the principles of periodic motion and is often used in experiments to measure time and gravity.

2. How do you find the position of a simple pendulum?

To find the position of a simple pendulum, you need to measure the length of the pendulum (from the point of suspension to the center of mass of the weight) and the angle at which the pendulum is displaced from its equilibrium position. You can then use mathematical equations to calculate the position of the pendulum at any given time.

3. What factors affect the position of a simple pendulum?

The position of a simple pendulum is affected by its length, the angle of displacement, and the acceleration due to gravity. Other factors such as air resistance and friction can also have a small impact on the position of the pendulum.

4. How does the position of a simple pendulum change over time?

The position of a simple pendulum changes over time in a predictable pattern known as simple harmonic motion. As the pendulum swings back and forth, it passes through its equilibrium position and reaches maximum displacement on either side. This motion repeats itself in a regular, cyclical pattern.

5. What are the applications of finding the position of a simple pendulum?

Finding the position of a simple pendulum has various applications in science and engineering. It can be used to measure time accurately, study the principles of periodic motion, and determine the value of acceleration due to gravity. It is also used in instruments such as metronomes and pendulum clocks.

Similar threads

Replies
1
Views
794
Replies
19
Views
2K
Replies
13
Views
3K
Replies
36
Views
3K
Replies
27
Views
1K
Replies
14
Views
888
Replies
4
Views
12K
Back
Top