Sei sulla pagina 1di 14

Computers in Engineering Lab Report

Title of Experiment: Practice Exercise

Experiment #: 1

Due Date: September 13, 2019

Name of Lecturer: Mr. R. Senior

Name of Laboratory Technologist: Mr. V. Alexander

Course name: Computers in Engineering

Student name: Landel Smith

Id number: 1607757

Date Given: September 13, 2019


Table of Contents Page
Problem Statement ....................................................................................................................................... 1
List of Variables ............................................................................................................................................. 1
Script ............................................................................................................................................................. 3
Conclusion ................................................................................................................................................... 12
Reference .................................................................................................................................................... 12
Problem Statement
1. How long will take a car to accelerate from 15.2 m/s to 23.5 m/s if the car has an average acceleration

of 3.2 m/s2?

2. An auto travels at a rate of 25 km/hr for 4 minutes, then at 50 km/hr for 8 minutes, and finally at 20

km/hr for 2 minutes. Find the total distance covered in km and the average speed for the complete trip in

m/s.

3. Two physics professors challenge each other to a 100 m race across the football field. The loser will

grade the winner's physics labs for one month. Dr. Rice runs the race in 10.40 s. Dr. De La Paz runs the

first 25.0 m with an average speed of 10.0 m/s, the next 50.0 m with an average speed of 9.50 m/s and the

last 25.0 m with an average speed of 11.1 m/s. Who gets stuck grading physics labs for the next month?

4. As she climbs a hill, a cyclist slows down from 25 mi/hr to 6 mi/hr in 10 seconds. What is her

deceleration?

List of Variables
Variable Name Data Type Description

U Integer Used to store the value of initial

Velocity

V Integer Used to store the value of final

Velocity

a Integer Used to store the value of

average acceleration

t Integer Used to store the value of time

v1 Integer Used to store the value of

Velocity

Page | 1
v2 Integer Used to store the value of

Velocity

v3 Integer Used to store the value of

Velocity

t1 Integer Used to store the value of time

t2 Integer Used to store the value of time

t3 Integer Used to store the value of time

St Integer Used to store the value of total

distance travelled

Vt Integer Used to store the value of total

speed

Vavrg Integer Used to store the value of

average speed

dis1 Integer Used to store the value of total

distance travelled

dis2 Integer Used to store the value of total

distance travelled

dis3 Integer Used to store the value of total

distance travelled

Vel2 Integer Used to store the value of

velocity

Vel3 Integer Used to store the value of

velocity

Vel4 Integer Used to store the value of

velocity

Page | 2
ti1 Integer Used to store the value of time

ti2 Integer Used to store the value of time

ti3 Integer Used to store the value of time

Tt Integer Used to store the value of total

time

Ui Integer Used to store the value of initial

velocity

Vf Integer Used to store the value of final

velocity

T Integer Used to store the value of time

da Integer Used to store the value of

deceleration

Script
%Initial velocity, U

U=15.2;

%Final velocity, V

V=23.5;

%Average acceleration, a

a=3.2

a=

3.2000

Page | 3
%Using equation [1] and transposing for t

t=(V-U)/a

t=

2.5938

%Question 2

v1=25;

%Converting from km/hr to m/s

v1=25*0.277778

v1 =

6.9445

t1=4;

%Converting from minutes to seconds

t1=4*60

t1 =

240

v2=50;

%Converting from km/hr to m/s

Page | 4
v2=50*0.277778

v2 =

13.8889

t2=8;

%Converting from minutes to seconds

t2=8*60

t2 =

480

v3=20;

%Converting from km/hr to m/s

v3=20*0.277778

v3 =

5.5556

t3=2;

%Converting from minutes to seconds

t3=2*60

Page | 5
t3 =

120

%Total distance,St

St=(v1+v2+v3)/(t1+t2+t3)

St =

0.0314

??? \

{_Error: Unexpected MATLAB operator.

}_

%Reworking Question 2

v1=25;

t1=4;

%Converting minutes to hours

t1=4/60

t1 =

0.0667

Page | 6
v2=50;

t2=8;

%Converting from minutes to hours

t2=8/60

t2 =

0.1333

v3=20;

t3=2;

%Converting from minutes to hours

t3=2/60

t3 =

0.0333

%Total distance, St

St=(v1+v2+v3)/(t1+t2+t3)

St =

407.1429

Page | 7
%Total speed, Vt

Vt=v1+v2+v3

Vt =

95

%Average speed, Vavrg

Vavrg=Vt/3

Vavrg =

31.6667

%Converting Vavrg to m/s

Vavrg=31.6667*0.277778

Vavrg =

8.7963

%Question 3

%dis = distance, m; Vel = average speed, m/s; ti = time,s

dis1 = 25;

dis2 = 50;

dis3 = 25;

Page | 8
Vel1 = 10;

Vel2 = 9.5;

Vel3 = 11.1;

%Using equation [6] and transposing for t

%ti = Vel/dis

ti1=25/10

ti1 =

2.5000

ti2 = 50/9.5

ti2 =

5.2632

ti3 = 25/11.1

ti3 =

2.2523

%Total time, Tt(s)

Tt = ti1+ti2+ti3

Page | 9
Tt =

10.0154

%Dr. Rice would be stuck grading physics labs for the next month

%Question 3

%Question 4

%Sp = Speed, mi/hr; da = deceleration, -mi/hr^2; T = time, s

Sp1= 25

Sp1 =

25

Sp2 = 6;

T = 10;

%Converting T from seconds to hours

T = 10/3600

T=

0.0028

%Using equation [1] and transposing for a = da

da = (Sp2-Sp1)/T

Page | 10
da =

-6840

%Reworking question 4

%Initial Velocity, mi/hr = Ui; Final Velocity, mi/hr = Vf; Time, s = T; Deceleration, -m/s^2 = da

%Converting mi/hr

%Disregard previous comment

Ui = 25;

Vf = 6;

T = 10;

%Converting mi/hr to m/s

Ui = 25*0.44704

Ui =

11.1760

Vf = 6*0.44704

Vf =

2.6822

%Using equation [1] and transposing for a gives

Page | 11
da = (Vf-Ui)/T

da =

-0.8494

diary off

Conclusion
1. Time taken to accelerate is 2.5938 s.

2. Total distance is 407.1429 m and the average speed is 8.7963 m/s.

3. Dr. Rice would be stuck grading physics labs for the next month.

4. Her deceleration is -0.8494 m/s2.

Reference
1. Google

2. Engineering Computing Lab Manual

Page | 12

Potrebbero piacerti anche