Divide by Zero Error: Solving Pendulum Radius

In summary, the speaker is using data from a pendulum to calculate its radius, but encounters a problem with large peaks in the graph due to dividing by zero at the pendulum's extremes. They suggest filtering the data to use only the figures with the largest x velocity, but this approach did not work for all data sets. The speaker hopes to cross check their results for accuracy.
  • #1
Sam Smith
37
0
I have data from a pendulum and I am using it to work out the radius of the pendulum. I have acceleration in the x and y directions and so thought this would be easy enough. Simply I determine the (velocity in the x direction)^2/acceleration in the y direction. However when I use python to give me a graph I notice that I get a graph with a large peak at the extremes (ie where the pendulum monetarily stops at the extremes and I am therefore dividing by zero) Any way around this?
 
Mathematics news on Phys.org
  • #2
By "x" and "y", one assumes that this amounts to "tangential" and "radial" for an accelerometer mounted on the pendulum. Your complaint is that at the ends of the pendulum's arc you have [near] zero tangential velocity and [near] zero radial acceleration. You suffer from a loss of significance because the error bounds on the two values are as large as the quantities themselves.

One possibility is obvious. Filter your data to use the figures where x velocity is largest.
 
  • #3
Yes I took this approach taking instantaneous readings. It was correct for some data but not another set. I am hoping to cross check them now so that I can be sure I can always get these values correct
 

1. What is a "Divide by Zero" error?

A "Divide by Zero" error is an error that occurs when a number is attempted to be divided by zero. This operation is mathematically undefined and cannot be computed.

2. How does a "Divide by Zero" error occur when solving for pendulum radius?

In the context of solving for pendulum radius, a "Divide by Zero" error can occur when the length of the pendulum is zero. This would result in a zero denominator in the equation, causing the error to occur.

3. How can a "Divide by Zero" error be avoided when solving for pendulum radius?

To avoid a "Divide by Zero" error when solving for pendulum radius, it is important to ensure that the length of the pendulum is not equal to zero. This can be achieved by accurately measuring the length of the pendulum or by using a non-zero length in the equation.

4. Can a "Divide by Zero" error be fixed once it occurs when solving for pendulum radius?

Once a "Divide by Zero" error occurs, it cannot be fixed. The error is caused by attempting to perform a mathematically undefined operation and cannot be resolved. It is important to take preventative measures to avoid this error from occurring.

5. Are there any alternative methods to solve for pendulum radius that do not result in a "Divide by Zero" error?

Yes, there are alternative methods to solve for pendulum radius that do not involve dividing by zero. For example, instead of using the length of the pendulum, the period or frequency of the pendulum's oscillation can be used in the calculation. Alternatively, one can use a numerical solver method to approximate the solution without encountering a "Divide by Zero" error.

Similar threads

Replies
13
Views
2K
  • Introductory Physics Homework Help
Replies
9
Views
696
  • General Math
Replies
2
Views
1K
  • Classical Physics
Replies
3
Views
2K
Replies
4
Views
1K
Replies
8
Views
3K
Replies
39
Views
3K
  • Introductory Physics Homework Help
Replies
3
Views
1K
Replies
1
Views
1K
Replies
8
Views
1K
Back
Top