English Assignment

OkOk
matlabcoursework.pdf

AM1S50 - Mathematics for Mechanical and Aeronautical Engineers Referral Coursework (2017-18)

This coursework is worth 25% of your module and is marked out of 100. You should attempt all questions. Please make sure to include the front sheet as the front pages of your report. Your report must be typed with all calculations done using MATLAB. You must show all workings by providing copies of all MATLAB code. For full marks all scripts/functions should be commented with a written explanation of the code given in your report.

Submission is via Turnitin ONLY by 23:59 on the submission date given. Please ensure to use your STUDENT NUMBER as the file name for your submission. Turnitin includes a plagiarism detector so please ensure that you have not submitted work which would be considered plagiarised from one of your class mates.

In some questions you will see the term α: You have been assigned a value for α which you should use in these questions. You will be emailed instructions for the coursework including the assigned value. Please ask your lecturer if you are unsure about any of these instructions.

1. (a) Evaluate 6α5 − 3α2 + 15α− 3.

(2 marks)

(b) Evaluate sin−1

( 3

ln 2α

) in degrees and in radians

(4 marks)

(c) Calculate ATB where A =

 α −α 2α 6 −11 −3 2 2α α −1 9 −1

 and B =

−5 15 3α 5 α 3 −1 4 −α 7 17 −8

.

(6 marks)

(d) Find the roots, expressed to 4 decimal places, of the equation x4 − αx+ 20 = 1.

(5 marks)

(e) Let y = e3x(5 cos √

3x− 4 sin √

3x+ α e−2x) and calculate in its simplest form

d2y

dx2 − 6

dy

dx + 12y.

(8 marks)

(f) Let y = 5 sin (x− 2)

x + 1 then between x = 2 and x = α calculate the area under the

curve and the volume of the solid formed when the curve is rotated about the x axis, each expressed to 4 decimal places.

(10 marks)

1

2. An object of mass 5α is to be hung from the end of an uniform rigid 12 metre horizontal pole of mass 8, as shown in Figure 1. The pole is attached to a wall by a pivot and is supported by a 9 metre cable which is attached to the wall at a higher point.

c

b

a

Figure 1: A weight suspended from an uniform rigid bar supported by a cable

The tension on the cable is given by the following equation: T = a · b · (Mog + 1

2 Mpg)

c √ a2 − c2

where T is the tension on the cable (N), a is the length of the cable in metres (m), b is the length of the pole in metres (m), Mo is the mass of the object (kg), g is the gravitational constant (9.80665m/s2), Mp is the mass of the pole (kg) and c is the distance from the wall to the attachment point of the cable in metres (m).

(a) Write an m-file script to determine the distance c at which the cable should be attached to the pole to minimize the tension in the cable. To do this, the algorithm should calculate the tension at 0.75 metre intervals from c = 1.25 metres to c = 8.5 metres. Expand this script so that it also plots the tension of the cable as a function of c, with appropriate titles and axis labels.

(30 marks)

(b) Write an m-file function to determine the distance c that minimizes T , this time making use of differentiation and stationary points. This function should accept inputs for a, b, Mo and Mp.

(20 marks)

3. Consider the following integral:

I =

∫ 2.5

0

5

α x cos(x+ 5) dx

Use MATLAB to approximate I using the midpoint rule, trapezium rule and Simpson’s rule. In each case use 4 and 8 intervals and compare the absolute error for each method. Write a summary of your findings looking at the relationship between the number of intervals and the absolute error in the approximation. Your summary should document your approach, results and findings.

(15 marks)

2