Q2) The 2 kg block is supported by a spring of stiffness k-200 N/m. Initially th
ID: 2086238 • Letter: Q
Question
Q2) The 2 kg block is supported by a spring of stiffness k-200 N/m. Initially the spring is undeformed and the block is at rest. At the equilibrium position (time t-0), a constant force of 10 N is applied so that the block freely slides on the rod. a) Using hand calculations, find: Equilibrium position i) velocity of the block when it slides a 40 mm ii) maximum displacement of the block distance x 200 N/m 10 N b) Do the integrations using MATLAB and plot 2 kg the variation of block velocity i) with 'x )with stiffiess 'kExplanation / Answer
2b (i) We have initial conditions using Euler's Integration.i.e, At t=0, x(t)=0 and v(t)=x'(t)=0
First we specify the constants and the initial conditions in MATLAB
> m=2; k=200;
%we define a constant called final time to perform integration for one time period as tf
>tf = 2*pi/sqrt(m/k); %final time
%We define the number of time steps.
>n=10; %took 10 time steps initially, can be varied as required
>dt= tf/n; %Time step(del t)
%initial condition
>v=0; x=0;
%Time integration using Euler's method in a for loop for 'n' time steps (v=v + a*dt; x=x + v*dt)
for i=1:n
>a = -k*x/m; % F=ma
>x = x + v*dt;
>v = v + a*dt;
>plot(v,x);
end
%The result should plot the integrated velocity against x
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.