Simple Energy Question based on SHM

  • Thread starter RJLiberator
  • Start date
  • Tags
    Energy Shm
In summary, the student attempted to solve homework problems related to linear harmonic motion, but was confused about the energy calculations. He thought the black curve should be flatlining at the 1800 mark like it does in the graph of motion, but it is not. He also thought red and blue didn't seem to be losing or gaining much energy in the graph of motion, but they shoot up linearly quite fast. He solved it while creating the post above by deleting a part of his code for his energy calculation.
  • #1
RJLiberator
Gold Member
1,095
63

Homework Statement


I am taksed with putting some simple harmonic motion (in this case linear harmonic motion) into graphs.
For my first graph, I am graphing theta vs. time and analyzing three different numerical methods for the solution (Euler, Euler-cramer, Runge Katta).
For my second graph, I am looking at the Energy vs. time based on these results.
Attached in the solutions are my results.

Homework Equations

The Attempt at a Solution



MOTION:
motion.JPG


ENERGY:
energy.JPG


Unfortuantely the labels are hard to read from jpg format. But the Euler method= black, the euler-cromer = red = runge-kutta method = blue.

My question is this: I know that my linear harmonic oscillator graph for motion is correct. I have a feeling my energy calculation is wrong, which is why I am posting here.
My energy calculation for euler method seems consistent. The energy continues to grow, infinite energy! Which is the problem with the Euler method here.

But my energy calculation for Runge-kutta and Euler-cromer method, I would have thought, were supposed to be a constant.
Or is my interpretation wrong and my graph actually correct?
 
Physics news on Phys.org
  • #2
I am going to post my second problem as it is highly related:
For this code, I am graphing Ideal Motion (red), Motion with dampening (black) , and then motion with dampening and a driving force (blue).

The energy calculations should be the same from my initial post, which is why it is relevant.

As we see, the black energy curve flatlines, which seems consistent with the graph of its motion. However, should it be flatlining at the 1800 mark like it does, or at the 0 mark? That's confusing to me.

Similiarly, red and blue don't seem to be losing or gaining much energy in the graph of motion, but they shoot up linearly quite fast.
3times.JPG
 
  • #3
I think I might have solved it while I was creating the post above!
I deleted a part of my code for my energy calculation, and I get this:
So the red curve we see a consistent energy which works with it's graph of motion.
The blue energy curve also works with the motion seen as at first it starts high then goes consistent.
The black curve now 0's out.

Looking good?

captur3333.JPG
 

Related to Simple Energy Question based on SHM

What is Simple Harmonic Motion (SHM)?

Simple Harmonic Motion (SHM) is a type of periodic motion where the restoring force is directly proportional to the displacement from the equilibrium position. In other words, it is a repetitive motion where the object oscillates back and forth around a fixed point. Common examples of SHM include the motion of a pendulum, a mass-spring system, or a vibrating guitar string.

What is the difference between SHM and regular periodic motion?

SHM is a type of periodic motion where the restoring force is directly proportional to the displacement, while regular periodic motion can have various forms of restoring forces. Additionally, in SHM, the displacement, velocity, and acceleration are all sinusoidal functions, while in regular periodic motion they can have different forms.

How is energy related to SHM?

In SHM, the total mechanical energy (potential energy + kinetic energy) is constantly changing as the object oscillates back and forth. At the equilibrium position, the kinetic energy is at its maximum while the potential energy is at its minimum. At the extremes of the oscillation, the opposite is true. This means that the total energy is conserved in SHM, with energy being transferred between potential and kinetic as the object moves.

What factors affect the period of SHM?

The period of SHM is affected by the mass of the object, the stiffness of the spring (if present), and the amplitude (maximum displacement) of the oscillation. The period is inversely proportional to the square root of the mass and directly proportional to the square root of the stiffness and amplitude.

Can SHM occur in real-life systems?

Yes, SHM can occur in many real-life systems, such as a swinging pendulum, a weight attached to a spring, or a vibrating guitar string. It is a common phenomenon in nature and has many practical applications, such as in clocks, musical instruments, and shock absorbers.

Similar threads

  • Introductory Physics Homework Help
Replies
20
Views
2K
  • Introductory Physics Homework Help
Replies
2
Views
215
  • Introductory Physics Homework Help
Replies
17
Views
1K
  • Introductory Physics Homework Help
Replies
3
Views
993
  • Introductory Physics Homework Help
Replies
30
Views
2K
  • Introductory Physics Homework Help
Replies
2
Views
1K
  • Differential Equations
Replies
5
Views
1K
Replies
9
Views
2K
Replies
16
Views
2K
  • Introductory Physics Homework Help
Replies
7
Views
2K
Back
Top