Thanks to visit codestin.com
Credit goes to www.scribd.com

0% found this document useful (0 votes)
9 views2 pages

MATLAB Exercises for Engineering Students

The document provides instructions for students to complete a MATLAB exercise. It includes 3 questions to solve using various MATLAB functions like quad, quadgk, trapz and eigenvectors. Students are asked to submit a single .m file with their solutions. The marking scheme allocates a total of 5 marks for the questions.

Uploaded by

Tayyab Ahmed
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
9 views2 pages

MATLAB Exercises for Engineering Students

The document provides instructions for students to complete a MATLAB exercise. It includes 3 questions to solve using various MATLAB functions like quad, quadgk, trapz and eigenvectors. Students are asked to submit a single .m file with their solutions. The marking scheme allocates a total of 5 marks for the questions.

Uploaded by

Tayyab Ahmed
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

Charles Darwin University

College of Engineering, IT and Environment

SMA102: MATLAB exercise 1


Please use MATLAB to solve the following questions. Submit a single .m file in
Learnline using the Unitcode_StudentID_Year as the file name. You can submit your
solution for exercise 1 in week 11 or submit solutions for both exercises by 8 October
2023.

To find the humps function type >> plot(humps). You will generate the curve below.

100

90

80

70

60

50

40

30

20

10

0
0 5 10 15 20 25

Question 1

(i) Use quad function in matlab to integrate the humps function from -1 to 2.

+∞ 1
(ii) Use quadgk function in matlab to evaluate∫1 𝑑𝑥.
𝑥2

Question 2

Use the trapz function in matlab to integrate the following function


π/2
dx

1
0 sin2 x + 4 cos 2 x

(Divide the interval [𝜋⁄2 − 0] into 100 subintervals)

Question 3

Find the eigenvectors and then diagonalize the following matrix:


4 2 2
𝐴 = [2 4 2]
2 2 4
Resources

1) Use the getting started, documentation, and demo resources in MATLAB to learn
about functions and syntax.

2) https://au.mathworks.com/videos/new-mathematics-features-in-matlab-75-
101542.html

Marking Scheme

The following table forms the basis for the marking of MATLAB exercise 1.

Question Section description Marks


1
i) Use quad function 1

ii) Use quadgk function 1

2 Use the trapz function 1

3 Find the:
eigenvectors of A 1

diagonalize A 1
Total 5

You might also like