This preview shows pages 1–3. Sign up to view the full content.
This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
Unformatted text preview: 0 2 5 7 >> AD ans = 2 2 1 1 >> DB' ans = 7 7 6 6 >> D77 ans = 78 77 75 74 >> A/2 ans = 0.5000 1.0000 1.5000 2.0000 >> 2*D ans = 2 0 4 6 1.10 – >> M(7) ans = 5 1.11 – >> partofM = M(:, 1:3) partofM = 0 2 3 7 3 8 1.12 – >> size(D) ans = 3 1 >> size(N) ans = 3 3 1.13 Code, plot attached a=0.5; b=0.5; t=0:0.1:70; for i=1:length(t) x(i)= sin(a*t(i))*exp(b*t(i)); x2(i)= sin(a*t(i))*cos(a*t(i)); v(i)= a*cos(a*t(i))*exp(b*t(i)) + b*sin(a*t(i))*exp(b*t(i)); end plot(t,x, '' ) 1.14Code, graph attached a=0.5; b=0.5; t=0:0.1:70; for i=1:length(t) x(i)= sin(a*t(i))*exp(b*t(i)); x2(i)= sin(a*t(i))*cos(a*t(i)); v(i)= a*cos(a*t(i))*exp(b*t(i)) + b*sin(a*t(i))*exp(b*t(i)); end plot(t,x, '' ) figure(3); plot( t, x, 'b' , t, v, 'r:' ); xlabel( 'Time' ); title( 'Position vs. Time and Velocity vs. Time' ); axis( [0 70/3 .15 .5 ] );...
View
Full
Document
This note was uploaded on 06/23/2011 for the course ME 218 taught by Professor Unknown during the Fall '08 term at University of Texas.
 Fall '08
 Unknown

Click to edit the document details