hw_02solQtrCar - % Eqns: vdot= -(b/m)*v +(k/m)*delta -g...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
ME 457. Homework 2. Quarter Car Model. Quarter Car Model - equations. function xdot= QtrCarEqs_1(t,x) % QtrCarEqs_1.m Quarter car model - equations. % % x(1) is v, velocity upward of mass % x(2) is d, compression of spring from free length % m= 240; % kg k= 16000; % N/m b= 1000; % Ns/m % g= 9.81; % m/s^2 % Ygdot= 0.0; % Ygdot= 0.67 % ramp of 5 percent at 30 mph % xdot(1)= -(b/m)*x(1) + (k/m)*x(2) +(b/m)*Ygdot -g; xdot(2)= -1*x(1) +1*Ygdot; % xdot= xdot'; % return xdot as column vector % Quarter Car Model - solution set up. % hw2_rr.m script file for quarter-car model
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Background image of page 2
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: % Eqns: vdot= -(b/m)*v +(k/m)*delta -g +(b/m)*Ygdot % deltadot= -v +Ygdot % Variables: x(1)= v, car motion upward % x(2)= delta, spring compression from free length % Ygdot= upward velocity of tire on road % g= accel of gravity % Parameters: m, sprung mass (qtr car) % k, suspension spring stiffness % b, damper rate % ts= [0.0:0.05:5]; xo= [ 0; 0 ]; % [t,x] = ode23( 'QtrCarEqs_1' ,ts,xo ); % v= x(:,1); delta= x(:,2); plot (t,v, 'k-' ,t,delta, 'k--' ); grid; title( 'Quarter-car response, flat ground' ); xlabel( 'time (s)' ); ylabel( 'v (m/s) and delta (m)' ); %...
View Full Document

Page1 / 2

hw_02solQtrCar - % Eqns: vdot= -(b/m)*v +(k/m)*delta -g...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online