HW12_1 - title\gamma(t by Song Hwan xlabel'Time in sec...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
clear all close all clc c to = 0; tf = 20; tspan = [to, tf]; tt = [to:0.001:tf]; t x0 = 35*pi/180; xdot0 = 0; g0 = 0; gdot0 = 0; g omega = 2.5; g = 9.8; L = 6; m =3; m u0 = [ x0 xdot0 g0 gdot0 ]; dt = [to, tf]; options = odeset('RelTol', 1e-10,'AbsTol', [1e-12 1e-12 1e-12 1e-12]); [t,u] = ode45('fpen3d', tspan,u0, options); [ M = 2.*m.*L^2/3.*u(:,2).*omega.*cos(u(:,1)); M figure plot(t,u(:,1));
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: title({'\gamma (t) by Song, Hwan'}) xlabel('Time in sec') ylabel('\gamma in (^o)') y figure plot(t,M); title({'\Gamma (t) by Song, Hwan'}) xlabel('Time in sec') ylabel('\Gamma in (kg-m^2)/(s^2)') y figure plot(u(:,1),M); title({'\Gamma (\gamma) by Song, Hwan'}) xlabel('\gamma in (^o)') ylabel('\Gamma in (kg-m^2)/(s^2)') y...
View Full Document

{[ snackBarMessage ]}

Ask a homework question - tutors are online