You are on page 1of 3

ENG1060: Computing for Engineers

Faculty of Engineering
ENG1060: Computing for Engineers
2016 - Semester 1

Laboratory #1: Questions

This laboratory comprises 2% of your final grade. The questions are designed to test your
recollection of the lecture material. You will be assessed during your laboratory session by
the demonstrators. You will be assessed on the quality of your programming style as well as
the results produced by your programs. Save your work in M-Files named lab1t1.m,
lab2t2.m, etc.

Note: Students are expected to attempt these questions during their own self-study time.
There may be questions which require functions that may not have been covered in the
lecture slides. If so, use MATLAB’s built-in help to learn how to use them.

Task 1 [1 mark]:
Use MATLAB’s help command to understand and provide at least 2 examples of each of the
functions below. You will need to be able to describe the functions to your demonstrators.

A. linspace
B. cos
C. mod
D. exp
E. floor

Task 2 [1 mark]:
Assume x=32, y=15 and z=4.9.

1. 𝑎𝑎 = 𝑥𝑥𝑥𝑥𝑥𝑥
𝑦𝑦 0.25
2. 𝑏𝑏 = 𝑥𝑥 0.45 +
𝑧𝑧 0.25
𝜋𝜋𝜋𝜋
3. 𝑐𝑐 = 𝑥𝑥 cos � �
𝑥𝑥𝑥𝑥
4. 𝑑𝑑 = mod(𝑦𝑦, 𝑧𝑧)
5. 𝑒𝑒 = linspace(𝑧𝑧, 𝑥𝑥, 𝑦𝑦)

Laboratory #1 Page 1 of 3
ENG1060: Computing for Engineers

Task 3 [1 mark]:
The equivalent resistance Req of four resistors R1, R2, R3 and R4 connected in series is given as
𝑅𝑅𝑒𝑒𝑒𝑒,𝑠𝑠𝑠𝑠𝑠𝑠𝑠𝑠𝑠𝑠𝑠𝑠 = 𝑅𝑅1 + 𝑅𝑅2 + 𝑅𝑅3 + 𝑅𝑅4 .

The equivalent resistance Req of four resistors R1, R2, R3 and R4 connected in parallel is given as
1 1 1 1 1
= + + + .
𝑅𝑅𝑒𝑒𝑒𝑒,𝑝𝑝𝑝𝑝𝑝𝑝𝑝𝑝𝑝𝑝𝑝𝑝𝑝𝑝𝑝𝑝 𝑅𝑅1 𝑅𝑅2 𝑅𝑅3 𝑅𝑅4

What is the equivalent resistance of four resistors (270Ω, 1kΩ, 800Ω and 3000Ω) if they are
connected in series? What is the equivalent resistance if they are connected in parallel?

Task 4 [1 mark]:
𝐿𝐿
The period T of an oscillating pendulum is given as 𝑇𝑇 = 2𝜋𝜋� where L is the length of the pendulum
𝑔𝑔

and g is the acceleration due to gravity (use g=9.81 m/s2). Calculate the period of a 100mm long
pendulum.

Task 5 [1 mark]:
𝑒𝑒 𝑥𝑥 −𝑒𝑒 −𝑥𝑥
The hyperbolic tangent function is defined by the equation: tanh 𝑥𝑥 = .
𝑒𝑒 𝑥𝑥 +𝑒𝑒 −𝑥𝑥
Calculate the value of tanh(0.2) and confirm the value using MATLAB’s inbuilt ‘tanh’ command.

Task 6 [1 mark]:
If a stationary ball is released at a height h above the surface of the Earth, the velocity of the ball v
when it hits the earth is given by the equation:
𝑣𝑣 = �2𝑔𝑔ℎ
where g is the acceleration due to gravity, and h is the height above the surface of the Earth
(assuming no air friction). Calculate the velocity of a stationary ball when it hits the earth, if it is
released at 5m above ground. (Use g = 9.81 m/s2)

Task 7 [1 mark]:
A diver looking for an old shipwreck jumps of his boat and swims 60m east and 25m south on the
water surface and then dives 30m below the water surface to reach his target.

Calculate the minimum distance the diver would cover if he swam towards the target in a straight
line.

Hint: Apply Pythagoras theorem.

Laboratory #1 Page 2 of 3
ENG1060: Computing for Engineers

Task 8 [1 mark]:
You are given a 5cm diameter water hose to fill up a 15 m3 tank. How long will it take to fill up the
tank if the water flows at 10 m/s.

Hint: Time taken = Tank volume/volumetric flow rate

Task 9 [1 mark]:
A satellite is orbiting around the Earth. The following formulas calculate its geodetic position.
Determine the θ position of the satellite when t=10. Keep θ in radians.

Task 10 [1 mark]:
In fracture mechanics, the stress intensity factor, K, at an edge crack can be calculated using the
simple equation
𝐾𝐾 = 𝐹𝐹𝐹𝐹√𝜋𝜋𝜋𝜋
where σ is the applied stress, a is the crack length and F is the geometry dependent constant, which
for a flat plate is given by
tan 𝛽𝛽 0.5 𝑎𝑎
𝐹𝐹 = sec 𝛽𝛽 � � �0.752 + 2.02 � � + 0.37(1 − sin 𝛽𝛽)3 �
𝛽𝛽 𝑊𝑊
and
𝜋𝜋𝜋𝜋
𝛽𝛽 =
2𝑊𝑊

Calculate the stress intensity factor given a=1.5 mm, W=10 cm and σ=17 N/mm2.

Laboratory #1 Page 3 of 3

You might also like