Project

Flow over Bicycle

# Attempt 1

You scored 50/50 in this challenge. Please see the below table for details

Requirement Explanation Maximum Marks Marks Obtained
Code Code should be attached with comments 20 20
Outputs Output plots/videos must be attached 10 10
Explanation Code and outputs must be explained 20 20

Grading Comments:

Remarks

good!

Your Question

Write a Matlab program to calculate drag force against a cyclist.

The factors involved are Velocity,Drag coefficient,Frontal Area,Density of air.

  • Write a program to plot Velocity vs Drag force.
  • Write a program to plot Drag Co-efficient vs Drag force.
    • Hint: For the same frontal area, the coefficient of drag varies for different shapes. Look for values of drag coefficient for various shapes in the internet.

  • The presentation of your code will be taken into consideration while grading.

Use the "INSERT CODE SAMPLE" option to paste your code.

SUBMISSION RULES

  • Use the "INSERT CODE SAMPLE" option to paste your code and attach screenshots of the output. 10 points will be reduced for not doing so
  • Just showing the code and not explaing the results. 20 points will be reduced if this happens.
  • If your program fails to compile then you will score 0, in that particular challenge. This is applicable only for challenges where you are asked to code
  • Copying code from others - If you copy code from others, your score will be 0. If you copy from others on more than 1 assignments your challenges will no longer be graded. You can still access the course but your challenges will not be graded.
  • If you have attached links to images or videos, make sure that they work before you hit submit. At the time of grading broken links will not be taken into account.
  • Once graded future submissions will not be valid

GENERAL INSTRUCTIONS:

  • The codes, plots, images, GIFs, and videos should be submitted only through the answer box.
  • Use the Google Drive to share only the cad models or other answers which couldn't be done through the answer box.

NOTE:

  • Violating the above instructions will lead to ZERO marks.
  • Link sharing should be enabled while sharing the Google Drive link, else the challenge will be awarded ZERO marks.

Please provide upto 2 weeks for challenges to be graded.

Your Answers

Aim :- To write a program in matlab to calculate drag force against a cyclist.

Objective :- The main objective is to

  • Write a program to plot Velocity vs Drag force. &
  • Write a program to plot Drag Co-efficient vs Drag force

Formula /Governing Equation:- formula to find the drag force is given as :-

`F_d = 1/ 2 × ρ × A × v^2 × C_d`

Where , Fd = Drag force (N)

`rho`= Density (Kg/`m^3`)

A = Frontal area (`m^2`)

v = velocity (m/s)

Cd = Drag coefficient (unitless)

Theory :- Drag force is the resistance forced applied on a body moving in a forward motion , it is just like an opposite force action on the body which is travelling in a particular direction

- Let’s take an example of a cyclist riding a bicycle at an uniform velocity say (v) in a particular direction , let (A) be the frontal area of the cyclist ,the force acting on the frontal area and causing air resistance action is called as drag force.

Body of the content :-

- Programing language used Matlab Online.

- Starting the program by using comments.

- providing the values for Velocity , Drag coefficient ,Frontal Area ,Density of air.

- Using the formula to calculate dragforce , formula:- drag force = rho*A*v.^2*Cd*0.5;

- Using plot commant to plot a graph by providing x&y label .

- To plot a graph of velovity vs dragforce the velocity values are placed in an array upto a specific limit, ie say velocity [1 to 100] to obtain a smooth curve

- Similarly to plot a graph for Drag Co-efficient vs Drag force the C_d values are taken in an array

Matlab Program :-

1 . program to plot a graph for Velocity vs Drag force.

% program to calculate drag for on a bicycle

close all
clear all
clc

% inputs used in program

% Drag coefficient 
c_d = 0.8

% Frontal Area in (m^2)
A = 0.2

% Density in (kg/m^3)
rho = 1.2

% velocity 
v = [1:65];

% Formula for Drag-force
drag_force = rho*A*v.^2*c_d*0.5;

plot(v , drag_force)
grid on 
xlabel ('velocity')
ylabel ('drag force')

Command window exicution:-

2 . program to plot a graph for Drag Co-efficient vs Drag force.

% program to calculate drag for on a bicycle

close all
clear all
clc

% inputs used in program

% Drag coefficient 
c_d = [ 1:50 ];

% Frontal Area in (m^2)
A = 0.2

% Density in (kg/m^3)
rho = 1.2

% velocity 
v = 0.25

% Formula for Drag-force
drag_force = rho*A*v.^2*c_d*0.5;

plot(c_d , drag_force , 'color', 'r')
grid on 
xlabel ('Drag coefficient')
ylabel ('Drag force')

Command window exicution:-

Result :- Thus we can create plot/graph by the above program for Velocity vs Drag force & Drag Co-efficient vs Drag force .

-below is the graph plotted for the Velocity vs Drag force & Drag Co-efficient vs Drag force

1. graph for Velocity vs Drag force.

x-axis is velocity & y-axis is for drag force , more the values for velocity results in smoother curve line is obtained . likewise when velocity values increases dragforce values also increases .

2. graph for Drag Co-efficient vs Drag force.

x-axis is drag-coefficient & y-axis is for drag force . it is seen that when C_d values increases dragforce values also increases .

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.