Project

Flow over bicycle

%function

function [DF] = drag_force(rho,a,v,cd)

DF=rho*a*v.^2*cd*0.5;

end

% Incorporate a function to plot Drag force vs Velocity

%inputs
%drag coefficient
cd=0.8;
%Area
a=0.5;
%Density
rho=1.225;

%veocity

v=linspace(0,100,20);

plot(V,drag_force(rho,a,v,cd));
xlabel(\'velocity(m/s)\')
ylabel(\'Drag force(N)\')
grid on;

%to plot drag force as a function of drag coeffiecient

%inputs
%Velocity
v=25;
%Area
a=0.5;
%Density
rho=1.225;

%drag coefficient

cd=linspace(0,1,20);

plot(cd,drag_force(rho,a,v,cd))
xlabel(\'Drag coefficient\');
ylabel(\'Drag force(N)\');
grid on;

Drag co-efficients for different shapes:

Your portfolio, next

Ship work like this
in your own course.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.