CSC 210

Week 8


Topics:


Assignment:

  1. Spring-Mass System:

  2. Period of Pendulum:

  3. Energy conserved: The Energy of planar pendulum without friction is given by the function
    E(Θ , Θ') = (1/2)m(L^2)(Θ'^2) + mgL(1- cos(Θ)).
    This Energy function is supposed to be conserved along the solutions of the pendulum. Show this assertion by computing dE/dt using the chain rule, keeping in mind that Θ and Θ' depend on t, and the differential equations for pendulum. Observe that dE/dt = 0, so it must be constant function of t.

  4. Free energy from EULER: Now, in the pendulum equation, take c= 0, m=1, l=1, g=1, the initial conditions Θ=0.5 and Θ'=0 and compute the solution for 20 time units using Euler's algorithm with step size of h=0.1. On the Time Panel of Phaser's Numerics Editor set "Skip iterations per plot" to 9 so that in the Xi Values view you will get the solution tabulated at integer values of time: you should have 21 rows of numbers. Now, with R, use these position and velocity numbers in the formula for the Energy of the pendulum above so that you will have 21 values of the Energy function. Plot these Energy values as a function of time. Are these Energy values constant? Increasing? Decreasing?

  5. WINDOWS USERS:
    Please watch the cygwin_installation_demo and install cygwin on your laptop.
    MAC USERS:
    Do not install anything. Mac comes equipped with what you need.