Question

EFC 3213 COMPUTING II (NUMERICAL METHOD) Assignment 2. Group Assignment (3-4 person per group) Students must use MATLAB softw
0 0
Add a comment Improve this question Transcribed image text
Answer #1

%%% Matlab code %%%

clc;
close all;
clear all;
g=9.8;
m=68.1;
c=12.5;
t=1:15;
v_m=[10 16.3 23 27.5 31 35.6 39 41.5 42.9 45 46 45.5 46 49 50];
v1=g*m/c*(1-exp(-c/m*t));
v2=g*m/c*(t./(3.75+t));

mse1=sqrt(sum((v1-v_m).^2));

plot(t,v_m,'*')
hold on
plot(t,v1,'g');
hold on
plot(t,v2,'r');
legend('Measured value','Mathmatical model','Empirical model');
xlabel('Time t');
ylabel('Velocity v');
grid on
mse1=sqrt(sum((v1-v_m).^2));
mse2=sqrt(sum((v2-v_m).^2));
if (mse1 < mse2)
fprintf('Theoretical mathmetical model is better than empirical model');
else
fprintf('empirical model is better than Theoretical mathmetical model ');
end

OUTPUT:

Theoretical mathmetical model is better than empirical model

50 Measured value Mathmatical model 45 Empirical model 40 35 30 20 15 10 5 0 10 15 Time t Velocity v 25

Add a comment
Know the answer?
Add Answer to:
EFC 3213 COMPUTING II (NUMERICAL METHOD) Assignment 2. Group Assignment (3-4 person per group) Students must...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT