The Pendulum

In this project you will investigate the built-in Mathematica commands to solve a differential equation by looking at equations which model the motion of a pendulum.  You will look at some increasingly complicated versions of the  problem and investigate the behavior of the model.

Model 1 -  a linear model

A pendulum is made of a "bob" which hands from a rigid stick of length, say L.  The other end of the stick is free to rotate on a frictionless pin.  

We assume that  initially, i.e., at T=0, the bob is given an angular displacement of (Subscript[θ, 0]) and then released.  The problem is to determine the position of the bob over time.

The equation for the angle θ can be written as:

                    θ '' = - (G / L) * sin( θ )
                   
where G is the gravitational acceleration constant.  If  θ  is small, we can approximate sin( θ ) by   θ , obtaining the linearized pendulum equation

                   θ '' = - (G / L) *  θ 

with initial connditions
           
                   θ (0) =  (Subscript[θ, 0])
                    θ '(0) = 0         
                    
In order to use most ODE packages, we need to write this second order ODE as a pair of first order equations.  Let U be another name for θ  and V denote θ '.  We then have

                  U ' = V
                  V ' = - ( G / L) * U
                  U(0) =(Subscript[θ, 0])
                  V(0) = 0

1.  For this simple system of equations we can obtain both an exact and an approximate solution.
In these calculations use G=386.09 inches/second and L=10 iches and  θ=π/6.  Choose T so that the pendulum swings back and forth at least 3 times.    In each case plot the displacement and estimate the period of the pendulum, i.e., the length of time it takes before its motion repeats.

a.  Use the command DSolve to find the exact solution.

Clear[u, v, t]\(G = 386.09; 
L = 10; 
theta = Pi/6; 

     DSolve[\ {\ v[t] == \(u'\)[t], \(-\((G/L)\)\)*u[t] == \ \(v'\)[t]\ ,          u[0] == theta, 
		v[0] == 0}, {u[t], v[t]}, t]\)

Plot[.523599*Cos[6.2136*t], {t, 0, 5}]

b.  Use the command NDSolve to find an approximate solution.

\(		NDSolve[
       \ {\ \(u'\)[t] == v[t], \ \(v'\)[t]\  == \(-\((G/L)\)\)*u[t],          u[0] == theta, 
		v[0] == 0}, {u[t], v[t]}, {t, 0, 10}]\)Plot[Evaluate[u[t]  /.  %], {t, 0, 5}]Plot[Evaluate[v[t]  /.  %%], {t, 0, 5}]

Model 2 - a nonlinear model

In the first model we made the assumption that θ = sin( θ ), which of course is not exactly true.
However, the equation
                   θ  '' = - (G / L) * sin (θ )
is much more complicated because the unknown, θ , appears nonlinearly in the term  sin(θ ).
If we rewrite this equation as  a first order system, we have
 
                  U ' = V
                  V ' = - ( G / L) * sin(U)
                  U(0) =(Subscript[θ, 0])
                  V(0) = 0

3.   Assume the same values for L, G, and U(0) as before.
a.  Use the command DSolve to try to find the exact solution.  What happens?

b.  Use the command NDSolve to find an approximate solution.

c.  Estimate graphically the period of the pendulum for the following initial displacements.
Do your results seem reasonable physically?
π / 6,  π / 4,  π / 3,  π / 2,  2, 3

d.  There is an exact formula for the period given by

               period = 4 * sqrt ( L / G ) * K ( (Subscript[θ, 0]) / 2 )
 
 where K is the complete elliptic function of the first kind.  Find a way to evaluate this function, draw a plot of the period as predicted by this formula for  0   ≤  (Subscript[θ, 0])   ≤  π /2.  Compare your results with your "eyeball estimates" in (c).

Model 3 - pendulum with a driving force

It is interesting to consider the case where the pendulum has a driving force; that is,
                  θ  '' = - (  G - A *   (ω^2) * sin (ω t )  ) * sin( θ ) / L

4.   Approximate the solution to this problem for the following choices of parameters:

          A                       ω                       (Subscript[θ, 0])
_______________________________________          
          0.5	           5.3                  0.05
          10.0	          5.3	         0.05
           10.0                 5.3                  0.5 
        
Discuss your results.