Whatβs the action of a simple harmonic oscillator? And how does this change depending upon the path? Some mates of mine and I worked through this recently. This is my write-up of that calculation.
While discussing special relativity recently, some friends of mine and I realised that weβd not understood the concept of action. It seems that this isnβt a well-understood concept, at least not at an intuitive level: it βjust worksβ and most people seem happy with that. As mentioned in a Veritasium video a while ago, Euler and Lagrange gave the concept of action a firm mathematical foundation. The idea that action is minimised is known as the principle of least action.
To understand this topic better (or at least, try to), we decided to consider a simple harmonic oscillator as a toy example. Since we know the solution, we could then calculate the action for the path matching the known solution and, as a comparison, the path of a linear ramp. The idea here being that weβd find the action to be minimised over an oscillatory path and that a path differing from that would give a non-minimal action. Thus, we could develop a better intuition for the principle of least action and hence for why the Lagrangian formalism works the way it does.
Letβs look at how to calculate the action for a simple harmonic oscillator.
Setting the stage
Consider a simple harmonic oscillator (SHO) such as a mass on a spring. We wish to calculate the action for a quarter oscillation of this system to try and convince ourselves that the standard solution for the equations of motion of a SHO (in a simplified form) gives the minimal (and hence optimal) action. We will later compare this to an alternative motion with the same boundary conditions1βbut following a different path between themβto see that the standard solution minimises the action. We will also show that the general solution for the action of a SHO reduces to the same value as our simplified form when considering these boundary conditions.
with
q
and
qΛβ
being the generalised positions and velocities of the objects in motion, and where
t
is time. The values
t1β
and
t2β
denote the start and end points of the interval over which we are measuring the action. The quantity
L
is the Lagrangian, which is defined by
L=TβV,ββ
with
T
being the kinetic energy and
V
being the potential energy.
We simplify the situation by considering only motion in the
x
-direction. Hence,
q
and
qΛβ
reduce to
x
and
xΛ
, respectively.
The kinetic energy is written in its familiar form:
T=21βmv2ββ
which, given we only consider motion in the
x
-direction, we write as:
T=21βmxΛ2ββ
For motion under the influence of a conservative force,2 the potential energy is the negative of the integral of all forces in the system, i.e.
V=ββ«FΒ dx,ββ
where in this case we only consider forces acting in the
x
-direction. To find the potential energy of a mass on a spring, we use Hookeβs Law for the force:
F=βkxββ
and thus integrate over
x
. Hence we have
V=ββ«FΒ dxββ
=β«kxΒ dxββ
=21βkx2.ββ
Combining (4) and (9) we write the Lagrangian like so:
With the general form for the action of a simple harmonic oscillator in hand, we can consider the action over different paths of motion.
Action for sinusoidal motion
For the mass-on-a-spring example weβre considering here, we choose the situation where the mass has its maximum speed (and hence maximum kinetic energy) at
t1β=0
corresponding to the position
x(t1β)=0
. The endpoint, at
t2β
, we choose to be where the mass has maximum amplitude and hence maximum potential energy. In other words, the final position is
x(t2β)=A
, where
A
is the amplitude of oscillation.
We can visualise this situation like so:
The interval over which we wish to calculate the action is thus a quarter oscillation of the SHO.
where
x(t)
is the massβ position along the
x
-axis at time
t
,
A
is the amplitude,
Ο
is the angular velocity of the oscillation and
Ο
is the phase offset. In our situation, weβve chosen the boundary conditions such that the phase offset can be set to zero; hence, we now have this reduced form of the equation describing the motion:
x(t)=Asin(Οt).ββ
Differentiating this with respect to time, we obtain a relation for the velocity
xΛ(t)=ΟAcos(Οt).ββ
With this information in hand, weβre now able to write the action (Equation 11) explicitly in terms of
t
This now makes it possible to perform the integral. Before we can do that, however, we need to work out what the limits of integration are.
The boundary conditions
x(t1β)=0andββ
x(t2β)=A,ββ
imply that the limits of integration become
t1β=0andββ
t2β=2ΟΟβ.ββ
The squared sine and cosine terms in (15) make performing the integral difficult. We can simplify things by using the trigonometric double-angle identities:
cos2ΞΈ=21+cos(2ΞΈ)βandββ
sin2ΞΈ=21βcos(2ΞΈ)β.ββ
Therefore, we can replace the squared sine and cosine expressions with simpler expressions only in terms of cosine. The integral calculating the action thus becomes:
Combining Equations (30) and (38), we can write the equation for the action specified in (22) as:
S=81βΟmΟA2β81βΟΟkA2β,ββ
which simplifies to
S=81βΟA2[mΟβΟkβ].ββ
From the solution of the differential equation describing simple harmonic oscillation, we know that
Ο
can be written in terms of the spring constant
k
and the objectβs mass
m
, i.e.:
Ο=mkββ.ββ
Substituting this value into (40), we get:
S=81βΟA2[mΟβΟkβ]ββ
=81βΟA2[mmkβββkkmββ]ββ
=81βΟA2[mm2kβββkmk2ββ]ββ
=81βΟA2[mkββmkβ]ββ
=0.ββ
Thus, we find that the action for a simple harmonic oscillator for the boundary conditions
x(0)=0andββ
x(Ο/2Ο)=Aββ
is equal to zero. This result implies that the action is minimised over the path described by the equations of motion of a simple harmonic oscillator.
We can see thatβfor the boundary conditions considered hereβthe general solution for the action reduces to the same result as that given by our simplified SHO solution in (13).
Weβve now convinced ourselves that the action for the simple harmonic oscillator seems to be minimised over the path given by the standard solution. What happens if we choose another path? What effect does that have on the action? Letβs look into this now.
A different path
Consider a situation other than simple sinusoidal motion. For instance, a linear ramp from zero amplitude up to maximum amplitude, progressing over the same time interval. The mass now moves with constant velocity from the beginning (
x(t=0)=0
) to the end (
x(t=Ο/2Ο)=A
). What is the action in this situation? If the action for the simple harmonic oscillator solution is
0
(and hence minimal), then we expect this alternate path to give a larger action.
Letβs calculate everything and see. The main point about considering such a situation is that the system now takes a different path between the two boundary conditions. Whether or not the motion itself is 100% physical is irrelevant for the calculation. The goal in performing this calculation is to support our intuition about the action being minimised in the optimum situation.
As before, we write the Lagrangian like so:
L=TβVββ
with
T=21βmv2=21βmxΛ2andββ
V=21βkx2.ββ
Because the mass moves between the start and end points with constant velocityβand we want the equations of motion to match these boundary conditionsβwe write the position and velocity of the mass over time as:
Although this equation follows from the sinusoidal result we derived above, we still need to use it in the linear ramp case due to our boundary conditions. This is in particular due to the expression for
t2β
(Equation (19)), which is defined in terms of
Ο
.
Substituting the expression for
Ο
from (68) into (67), we get:
S=ΟA2Οβ[mβ121βkΟ2Ο2β]ββ
=ΟA2βmkββ[mβ121βkΟ2kmβ]ββ
=ΟA2βmkββm[1β12Ο2β]ββ
=ΟA2βkmβ[1β12Ο2β].ββ
Since
[1β12Ο2β]ββ
is greater than zero (and hence greater than the action calculated in the sinusoidal case), we can conclude that this motion is not optimal. Thus, the simple harmonic oscillation path gives the best result because it minimises the action.
In other words, it worked! We confirmed our premise from the beginning. π
If you want a deeper understanding, you have to put in the work
Going through this process really helped my understanding. For instance, when I first watched the Veritasium video about action, I thought βThatβs interestingβ, but nothing much more. After having done the calculation above myself, I re-watched the video and was like βOh, thatβs what they were talking about!β.
Going over the material after someone has presented it to you consolidates your knowledge of the topic. Who wouldβve thought? π
Top comments (0)