Professional Documents
Culture Documents
__________________________________________________________________________________
Please do this task in the editor window and save it as a M-file script with the file name :
yourname_NIM_task8
Your file should include appropriate comments (%) to identify each problem and to describe
your calculation process.
Please start your script with the comments:
% Name :
% NIM :
% Task #8
Divide each problem script using cell mode (%%).
When you finish, send the M-files to martinus.dewa@sampoernauniversity.ac.id before
Thursday, May 12th, at 08.00, with the subject : [ENG-COMP] Task 8
Late submission will not be accepted and automatically be graded as 0.
The submission of assignment for those who don’t come with a permission letter will be
announce later.
Wrong format (file name, script’s beginning, email subject, and file format) will result in
points deduction.
birthdays=
6 11 1983
3 11 1985
6 29 1986
12 12 1984
12 11 1987
Answer :
2. Create a cell array called sample_cell to store the following individual arrays:
Answer :
3. Find the kinetic energy of a car that weighs 2000 lbm and is traveling at 60 mph (see
Figure). Your units will be lbm mile2/h2. Once you’ve calculated this result, change it to
Btu by using the following conversion factors:
Answer:
4. Determine the first and second derivatives of the following functions, using MATLAB’s
symbolic functions:
a. 𝑓1 (𝑥) = 𝑦 = 𝑥 3 − 4𝑥 2 + 3𝑥 + 8
b. 𝑓2 (𝑥) = 𝑦 = (𝑥 2 − 2𝑥 + 1)(𝑥 − 1)
c. 𝑓3 (𝑥) = 𝑦 = cos(2𝑥) sin(𝑥)
2
d. 𝑓4 (𝑥) = 𝑦 = 3𝑥𝑒 4𝑥
(a) Use linear interpolation to estimate the pressure when the volume is 3.8 m3.
(b) Use cubic spline interpolation to estimate the pressure when the volume is 3.8 m3.
(c) Use linear interpolation to estimate the volume if the pressure is measured to be 1000
kPa.
(d) Use cubic spline interpolation to estimate the volume if the pressure is measured to be
1000 kPa.