Matlab Ahmed
Matlab Ahmed
clc;
clear;
format long;
format short;
clc;
clear;
% Calculate functions
a = 2 + t + t.^2;
c = cos(t).^2 + sin(t).^2;
d = atan(t);
clc;
clear;
G = [68, 83, 61, 70, 75, 82, 57, 5, 76, 85, 62, 71, 96, 78, 76, 68, 72, 75, 83,
93];
sortedG = sort(G);
numGrades = length(G);
% Statistical measures
meanG = mean(G);
medianG = median(G);
modeG = mode(G);
stdDevG = std(G);
% Display results
clc;
clear;
M1 = zeros(2, 4);
M2 = ones(4, 4) * 1201;
% Display matrices
disp(M1);
disp(M2);
clc;
clear;
% Input parameters
m = input('Enter the mass of the object in kg: ');
% Constants
% Print result
fprintf('An object with mass %.2f kg and frontal area %.2f m^2, has a
terminal velocity in air of Vt = %.2f m/s.\n', m, A, Vt);