Vous êtes sur la page 1sur 68

Faculty of Engineering Science and Built Environment

Course: BEng Building Services Engineering Mode: Part Time Level: Two Unit: Engineering Mathematical Methods Coursework Unit Code: SCE-2-203 Date: Semester 1, 2010

Prepared By Douglas Buchan

Contents

Page

Past Paper 1
Question 1 Question 2 Question 3 Question 4 Question 5 Question 6 Question 7 Question 8 3 7 12 17 22 25 30 32

Past Paper 2
Question 1 Question 2 Question 3 Question 4 Question 5 Question 6 Question 7 Question 8 Bibliography 35 40 42 50 54 56 59 61 68

Question 1 (a) Arrange the equations below into diagonally dominant form giving a motivation for doing so. (5 Marks)

By arranging the matrix into a diagonally dominant form convergence is guaranteed, when using both the Jacobi and the Gauss-Seidel iteration schemes, without arranging the matrix into diagonally dominant form the equation may not converge.

(b) Perform one cycle of the Gauss-Seidel iteration scheme for solving a system of linear equations on your diagonally dominant equations and hence obtain an approximation to the exact solution. Start with trial solution w= 0.0, x= 0.0, y= 0.0, z= 0.0 (15 Marks)

Multiply out first line to find w Solving row 1 for w;

Rearranged this gives;

Solving row 2 for x;

Rearranged this gives;

Solving row 3 for y;

Rearranged this gives;

Solving row 4 for z;

Rearranged this gives;

I will now start by using the given trial solution in the above rearranged equations; If w = y = x = z = 0 Then;

The resultant values can now be used in the next cycle, note: because Im using the Gauss-Seidel iteration scheme the values are updated as they are calculated for each equation;

Summary of results

w Cycle using given figures 1st cycle Results of 1st cycle Resultant Values 0 -0.05 -0.0014 0

x 0 -0.987 -1 -1

y 0 1.02 0.999 1

z 0 1.002 1 1

I shall now replace w, x, y, z with the resultant values

It can be seen that convergence has been achieved and that the resultant values have been proved to be accurate.
6

(c) Explain the difference between Gauss-Seidel and Jacobi methods. (5 Marks) The difference between the Gauss-Seidel and Jacobi methods is that the GaussSeidal method involves updating the equations as soon as a new component (x, y, z etc) value has been calculated during the cycle. The Jacobi method only uses the full cycle values for each of the component values i.e. once a full cycle has been completed and values are found for all components. This makes the Gauss-Seidel method far quicker to use in order to get the required values. Question 2 (a) Perform a Triangular Decomposition on the symmetrical Matrix; (10 Marks)

Triangular decomposition involves splitting this symmetrical Matrix (A) into two component parts a Lower (L);

As well as an Upper (U);

It follows that the symmetrical matrix (A) equals the product of the component parts (L and U) giving us; A = LxU = Multiplication of the matrices (L U) gives the following results;

Having multiplied the matrices I can now calculate the component values by solving the resultant equations;

The component values can now be inserted into the equation , this will complete the triangular decomposition; A=LxU =

(b) Use your result from (a) above to solve the symmetrical system of linear equations. (10 Marks)

= A X B

The above symmetrical system of linear equations can be expressed as;

I have proved above that;

= The equation can now be expressed as;

In order to complete the calculation I will create new matrix Y, it is equal to the product of matrices U and X;

= Therefore;

I will now calculate the components of Y as follows;

The components of the Y matrix can now be used to calculate the components of X;

And since

then;

10

Multiplication of the matrices (U X) gives the following results;

I shall now replace x, y, z with the resultant values

It can be seen that convergence has been achieved and that the resultant values have been proved to be accurate.

(c) Briefly discuss the methods you would use for solving various types of systems of linear equations. (5 Marks) Systems of linear equations are linear equations that need to be solved simultaneously, the methods I would use would depend on the type of system. If the system of linear equations was small and dense (i.e. packed with numbers) I would use a direct method such as the Inverse method or Triangular Decomposition. Matrix Inverse Method This method involves using the inverse of Matrix A (A-1). The inverse matrix is calculated by finding the determinant and the adjoint. The adjoint is divided by the determinant and the resultant inverse matrix (A-1) is then multiplied to both sides of the system; A-1 x = A-1x B
11

X = A-1 x B Values for X are then used for the initial condition; AxX=B Triangular Decomposition This method involves creating two new matrices an upper (U) and a lower matrix (L) from the initial Matrix (A), U and L are used to find a new matrix (Y) which can in turn be used to find matrix X components; A x X = B (original condition) U x L x X =B ( lower and upper forms) L x Y = B ( Y can be calculated) U x X = Y (X can now be calculated using the values calculated for Y)

If The matrix is larger and is more sparse i.e. has many zeros or small values then an indirect method such as Gauss-Seidel of Jacobi iteration scheme would be used. Gauss-Seidel and Jacobi Methods Both of these method start by changing the matrix( A) so that it is diagonally dominant ( this guarantees convergence). The figures for components in the X matrix are then estimated and from the resultant equations the true figures are calculated. The Gauss-Seidel method involves updating the equations as soon as a new component (x, y, z etc) value has been calculated during the cycle. The Jacobi method only uses the full cycle values for each of the component values i.e. once a full cycle has been completed and values are found for all components. This makes the Gauss-Seidel method far quicker to use in order to get the required values.

Question 3 (a) Evaluate the determinant of the matrix: (3 Marks)

In order to evaluate the determinant I must first choose a pivot point then calculate a scalar matrix, the pivot point is shown in blue the matrix components are shown in red;
12

A=

Giving;

The rest of the matrix is calculated in a similar way;

det(A) = a (e i - h f) - d (b i - h c) + g (b f - e c) det(A)= The determinant of matrix A can now be calculated det(A)= 2 det(A) = 2 (-1-1) det(A) = - 4 (b) Using your result from (a) above calculate the inverse of (10 Marks) -0+0

Determinant from previous calculation; det(A) = -4

Now I will Form Cofactor of Matrix A (coA);

13

I must now transpose the cofactor matrix to produce the adjoint, in this case the adjoint is same (as the cofactor matrix is symmetrical it will not be affected by transposition)

In order to find the inverse of the matrix the following formula is used;

I shall now use this inverse matrix to prove that the calculations undertaken are correct;

14

It can be seen that equality has been achieved and that the inverse values have been proved to be accurate.

(c) From the results from (a) and (b) above Solve
=

(6Marks)

In order to solve this set of linear equations the inverse matrix (A-1) is then multiplied to both sides of the system; A-1 x = A-1x B

This can then be simplified to; X = A-1 x B

Values for X can now be used for the initial set of equations;

15

It can be seen that equality has been achieved and that the x, y z values of matrix X have been proved to be accurate.

(d) Evaluate the double integral

(6 Marks)

In order to evaluate the double integral I will first integrate with respect to y,

Now I need to integrate with respect to x;

16

= 27

Question 4 (a) A dynamical engineering system has 2 time (t) dependent generalised coordinates X,Y which obey the simultaneous differential equations;

Verify that a specific solution to the above equation is = a exp (1t) 1 + b exp (2t) 2 Where a, b are time independent coefficients. 1, 2 are Eigen values and 1, 2 are normalised eigenvectors of the matrix; (12 Marks)

Inputting the Eigen values and eigenvectors will give me;

Now I must differentiate the expressions; a a +b +b

On the other side of the equation Ill have: = [a +b ]


17

=a =a +b

+b

This confirms of the specific solution to the above equation is: =a +b

(b) The matrix in (a) above

has eigenvalues 0, 2 and normalised eigenvectors 1, 2 given by;

Use this result for the eigenvalues and normalised eigenvectors to calculate the coefficients a, b for the initial condition; = (13 Marks)

I need to find the secular determinant (Det) as follows;

I shall now check the values using the trace (Tr) method;
18

=2
The Trace confirms that the calculations are correct Now I can find the 1st Eigen Vector

Input the values calculated from the secular determinant

Multiplication of the matrices gives

So

The gives me a ratio of the Eigen vectors of 1:1

In order to normalise the Eigen vector I must scale by a factor of S

19

Now I can find the 2nd Eigen Vector

This gives me the Ratio of the Eigen vector of 1:1

In order to normalise the Eigen vector I must scale by a factor of S

20

Where:

Table of

Coefficient a(0)

21

Coefficient b(0)

Initial condition coefficients a(0) and b(0)

Question 5 (a) Obtain the general solution to the differential equation. + + y =0 (10 Marks)

In order to obtain a general solution for this differential equation I will use the trial solution method;

22

I have supposed that

Now I must substitute;

The general solution for the differential equation is therefore;

(b) Use the techniques of Laplace transformation to solve the differential equation

+ 2y =0,

= 3, y(0) =4

(15 Marks)

23

From Laplace transforms table;

Given;

Therefore;

24

Therefore;

Question 6 (a) By deriving an expression for s verify that the Fourier Series

Is a solution to the partial differential equation + (10 marks)

Left Hand Side

25

Right Hand Side

This therefore verifies that the Fourier equation is a solution to the PDE.

(b) Set up the finite difference equations to numerically estimate a solution for the temperature at (a,b,c) to the Laplace equation + below = 0 for a sheet of metal with the boundary conditions shown (8 marks)

26

X
Equations for calculating Temperature in the X Direction;

Equations for calculating Temperature in the Y Direction;

Equations for calculating Temperature in the X and Y Direction;

If x=y then;

27

The function at steady state;

Temperature at point A;

Temperature at point B;

Temperature at point C;

Diagonally Dominant Matrix;

From the diagonally dominant matrix I can now calculate the following; Temperature at point A;

Temperature at point B;

Temperature at point C;

28

Therefore;

/4

(c) Solve your equations iteratively performing 2 cycles of your iteration scheme Taking the guesses for the temperatures at (a,b,c) all as 25 degrees centigrade (7 marks)

I shall use the Gauss-Seidal iteration scheme to solve the set of equations;

First cycle

Second cycle

29

B=

Ta Cycle using given figures 1st cycle 2nd cycle Resultant Values 25 30 30.16 30

Tb 25 35.63 36.33 36

Tc 25 25.16 25.33 25

Question 7 A square rectangular box (with a lid) has a height (h) and side (s). It is desired by a designer to minimise manufacturing costs by maximising the volume of the box but with the constraint that the surface area is 10m 2. a) By considering the constrained surface area and the volume of the box use Lagrange undetermined multipliers to derive 3 equations describing the above optimisation problem. Ignore the thickness of the material used.

Volume of the box can be found using the following equation;

30

Surface area of the box has the following constraint;

Lagrange equations

b) Solve your equations for the optimal values of s and h

Therefore;

I can now combine and simplify the equations;

Therefore;

This would indicate that the height would need to be the same length as the sides; therefore the box would have to be a cube and as such will have square surfaces instead of rectangular. Length of box side;

31

Therefore the length of the sides will be 1.29 m As stated the height would have to be the same as the side length shown above in order for optimisation to occur within the set constraints. Area Check; One surface = 1.292 = 1.664m2 As there are six surfaces to find the total area; 6 x 1.664 = 9.985m2 Therefore total area is 9.985 m2 this is 99.9% of the total allowed material. Question 8 (a) If = x y z3 find div grad (8 marks)

(b) If A = xzi y2 z2 j_ + xy2 k Find div A at (x,y,z)=(1,2,3). Is A solenoidal at this point? (4 marks)

32

33 At the point (x,y,z)=(1,2,3) the function A is not solenoidal. I can determine this due to that fact that there is divergence occurring (-33), in order for A to be Solenoidal at this point it wound need to be divergenceless1 or in other words the divergence wound need to be equal to zero. (c) If B = xi + y j , sketch the vector field B (6 marks)

Point (X,Y) (1,1) (1,-1) (-1,-1) (-1,1) (2,1) (1,2) (2,-1) (1,-2) (-2,-1) (-1,-2) (-2,1) (-1,2)

V (X,Y) =1i + 1j =1i - 1j =-1i -1j =-1i + -1j =2i + 1j =1i + 2j =2i - 1j =1i - 2j =-2i - 1j =-1i -2j =-2i - 1j =-1i - 2j

Direction of vector From (X,Y) Co-ordinate 1,1 1,-1 -1,-1 -1,1 2,1 1,2 2,-1 1,-2 -2,-1 -1,-2 -2,1 -1,2

Advanced electromagnetism: foundations, theory and applications By Terence William Barrett, Dale M. Grimes

33

I can now plot the points;


Y

(d) Find curl B for the vector field B defined in (c) above. Is B irrotational? (7 marks) Curl is a function of (x,y,z) B=xi + yj

The fact that the curl is equal to zero would indicate that the vector field is irrotational (conservative)
34

Past paper 2 Question1 (a) The fluid levels h1 and h2 in two tanks are computer controlled to obey the pair of simultaneous differential equations;

Where t is the time. By calculating the eigenvalues and eigen vectors of an appropriate matrix verify that a general solution to the above equation is

Where p,q are time independent co-efficients.

(18 marks)

I need to find the secular determinant (Det) as follows;

35

I shall now check the values using the trace (Tr) method;

= -2
The Trace confirms that the calculations are correct Now I can find the 1st Eigen Vector

Input the values calculated from the secular determinant

Multiplication of the matrices gives

The gives me a ratio of the Eigen vectors of 1:1

In order to normalise the Eigen vector I must scale by a factor of S

36

Now I can find the 2nd Eigen Vector

This gives me the Ratio of the Eigen vector of 1:1

In order to normalise the Eigen vector I must scale by a factor of S

37

In order to verify that a specific solution exists the following equation can be expanded to include the calculated Eigen vectors; Right hand side:

Left hand side:

This verifies the specific solution exists as the left hand side is equal to the right..

38

(a) Use your result for the eigenvalues and normalised eigenvectors to calculate the coefficients p and q for the initial condition (t = 0) (7 marks)

Table of

Coefficient p(0)

39

Coefficient q(0)

Initial condition coefficients are the same

Question 2 (a) Perform a Triangular Decomposition on the symmetrical Matrix; (10 Marks)

Triangular decomposition involves splitting this symmetrical Matrix (A) into two component parts a Lower (L);
40

As well as an Upper (U);

It follows that the symmetrical matrix (A) equals the product of the component parts (L and U) giving us; A = LxU = Multiplication of the matrices (L U) gives the following results;

41

Having multiplied the matrices I can now calculate the component values by solving the resultant equations;

The component values can now be inserted into the equation , this will complete the triangular decomposition; A=LxU =

42

(b) Use your result from (a) above to solve the symmetrical system of linear equations. (10 Marks)

= A X B

The above symmetrical system of linear equations can be expressed as;

I have proved above that;

The equation can now be expressed as;

In order to complete the calculation I will create new matrix Y, it is equal to the product of matrices U and X;

= Therefore;

I will now calculate the components of Y as follows;

43

The components of the Y matrix can now be used to calculate the components of X;

And since

then;

Multiplication of the matrices (U X) gives the following results;

I shall now replace x, y, z with the resultant values

It can be seen that convergence has been achieved and that the resultant values have been proved to be accurate.

44

(c) Briefly discuss the methods you would use for solving various types of systems of linear equations. (5 Marks) Systems of linear equations are linear equations that need to be solved simultaneously, the methods I would use would depend on the type of system. If the system of linear equations was small and dense (i.e. packed with numbers) I would use a direct method such as the Inverse method or Triangular Decomposition. Matrix Inverse Method This method involves using the inverse of Matrix A (A-1). The inverse matrix is calculated by finding the determinant and the adjoint. The adjoint is divided by the determinant and the resultant inverse matrix (A-1) is then multiplied to both sides of the system; A-1 x X = A-1 x B Values for X are then used for the initial condition; AxX=B Triangular Decomposition This method involves creating two new matrices an upper (U) and a lower matrix (L) from the initial Matrix (A), U and L are used to find a new matrix (Y) which can in turn be used to find matrix X components; A x X = B (original condition) U x L x X =B ( lower and upper forms) L x Y = B ( Y can be calculated) U x X = Y (X can now be calculated using the values calculated for Y) = A-1x B

If The matrix is larger and is more sparse i.e. has many zeros or are small then an indirect method such as Gauss-Seidel of Jacobi iteration scheme would be used. Gauss-Seidel and Jacobi Methods Both of these method start by changing the matrix( A) so that it is diagonally dominant ( this guarantees convergence). The figures for components in the X matrix are then estimated and from the resultant equations the true figures are calculated. The Gauss-Seidel method involves updating the equations as soon as a new component (x, y, z etc) value has been calculated during the cycle. The Jacobi
45

method only uses the full cycle values for each of the component values i.e. once a full cycle has been completed and values are found for all components. This makes the Gauss-Seidel method far quicker to use in order to get the required values.

Question 3 (a) Arrange the equations below into diagonally dominant form giving a motivation for doing so. (8 Marks)

By arranging the matrix into a diagonally dominant form convergence is guaranteed, when using both the Jacobi and the Gauss-Seidel iteration schemes, without arranging the matrix into diagonally dominant form the equation may not converge.

(b) Derive an expression for the Gauss-Seidel or Jacobi iteration scheme in matrix form. (8 Marks) An expression for the Gauss-Seidel or Jacobi iteration scheme can be derived from the above set of equations; Multiply out first line to find w Solving row 1 for w;

Rearranged this gives;

46

Solving row 2 for x;

Rearranged this gives;

Solving row 3 for y;

Rearranged this gives;

Solving row 4 for z;

Rearranged this gives;

(c) Perform one cycle of the Gauss-Seidel iteration scheme for solving a

system of linear equations on your diagonally dominant equations and hence obtain an approximation to the exact solution. Start with trial solution w= 0.0, x= 0.0, y= 0.0, z= 0.0 (12 Marks) I will now start by using the given trial solution in the above rearranged equations; If w = y = x = z = 0 Then;

47

The resultant values can now be used in the next cycle, note: because Im using the Gauss-Seidel iteration scheme the values are updated as they are calculated for each equation;

48

Summary of results

w Cycle using given figures 1st cycle Results of 1st cycle Resultant Values 0 -0.05 -0.0045 0

x 0 0.99 0.999 1

y 0 -1 -1.001 -1

z 0 0.1 -0.005 0

49

I shall now replace w, x, y, z with the resultant values

It can be seen that convergence has been achieved and that the resultant values have been proved to be accurate.

Question 4 (a) Multiply the matrices

(5 marks)

(b) If Then use the turn over rule to evaluate (5 marks)

The following formula applies to the turn over rule

50

(c) Calculate the determinant of; (5 marks) In order to evaluate the determinant I must first choose a pivot point then calculate a scalar matrix, the pivot point is shown in blue the matrix components are shown in red; M=

Giving;

The rest of the matrix is calculated in a similar way;

Determinant of matrix m

(d) Use your result for (c) to evaluate the inverse of; (5 marks)

51

Now I will Form Cofactor of Matrix M (coM);

I must now transpose the cofactor matrix to produce the adjoint, in this case the adjoint is same (as the cofactor matrix is symmetrical it will not be affected by transposition)

In order to find the inverse of the matrix the following formula is used;

To verify the correctness of the inverse matrix

52

It can be seen that equality has been achieved and that the inverse values have been proved to be accurate. Therefore; The inverse of

(e) Use your result from (c) to solve the simultaneous linear equations

(5 marks)

In order to solve this set of linear equations the inverse matrix (M -1) is then multiplied to both sides of the system; M-1 x = M-1x B

This can then be simplified to; X = M-1 x B

Values for X can now be used for the initial set of equations;

53

It can be seen that equality has been achieved and that the x, y z values of matrix X have been proved to be accurate. Therfore;

Section B Question 5 (a) The vibration of a mass (m) on the end spring with stiffness constant k and damping constant obeys the differential equation; + + kx =0 (10 marks)

Find the general solution to the differential equation above.

In order to obtain a general solution for this differential equation I will use the trial solution method;

I have supposed that

54

The general solution for the differential equation is therefore;

(b) Use the technique of laplace transformation to solve the differential equation given y(0) = 0 A table of Laplace transforms are given in the appendix (15 marks)

LAPLACE TRANSFORMATION

From Laplace transforms table;

Given;

55

Therefore;

Question 6 A manufacturer wants to make a tin can (radius r and height h) with the largest possible volume out of exactly 1 metre squared of material of negligible thickness. (a) Using Lagrange undetermined multipliers derive 3 equations describing the above optimisation problem. (15 marks)

Volume of the box can be found using the following equation;

Surface area of the box has the following constraint;

Lagrange equations

56

(b) Solve your equations for the optimal values of r and h.

(10 marks)

Therefore;

Therefore;

I can now combine and simplify the equations;

This would indicate that the height would need to be twice the length of the radius. To calculate the radius;

Because I have calculated that;

57

To calculate the Height;

Optimised Radius and height;

Area check; Rectangular component = Height x circumference = 0.46 x (0.46 x ) = 0.664 m Circular area = x = 0.333m

Total area = 0.664 x 0.333 = 0.997 so 99.7% of the allowed material has been used.

58

Question 7 (a) A liquid in a two-dimensional film is moving with a position dependent velocity field V given by V = (y 1) i (x-1) j_ Sketch this vector field at the (x,y) points (0,1), (1,2), (2,1), (1,0), (1,1) giving the magnitude and direction of V at these five points. (8 marks)

Point (X,Y) (0,1) (1,2) (2,1) (1,0) (1,1)

V (X,Y) =0i+1j =1i-0j =0i-1j =-1i-0j =0i-0j

Direction of vector From (X,Y) Co-ordinate 0,1 1,0 0,-1 -1,0 0,0

Y
[1,2]

[0,1] [1,1] [1,0]

[2,1]

(b) Find div V at (x,y)=(1,1). Is V solenoidal at this point?

(4 marks)

At the point (x,y,)=(1,1) the function V is solenoidal. I can determine this due to that fact that there is zero divergence occurring.

59

(c) Find Curl V at (x,y)=(1,1). Is V irrotational at this point?

(10 marks)

Curl is three dimensional function therefore it will be function of (x,y,z)

The function V is not irrotational at any point due to the fact that the curl does not equal zero. (d) Evaluate V2 (3 marks)

60

Question 8 (a) Fluid in an oil reservoir is diffusing through a two-dimensional slab of porous rock. In the steady state the concentration C(x,y) obeys the Laplace Equation; + =0 (10 marks)

Set up the finite difference equations to numerically estimate a solution for the concentration of fluid at the points for the rock slab with the boundary conditions shown below; (10 marks)

Equations for calculating Temperature in the X Direction;

61

Equations for calculating Temperature in the Y Direction;

Equations for calculating Temperature in the X and Y Direction;

If x=y then;

The function at steady state;

Temperature at point ;

Temperature at point ;

62

Temperature at point ;

Therefore;

Diagonally Dominant Matrix;

From the diagonally dominant matrix I can now calculate the following; Temperature at point ;

Temperature at point ;

Temperature at point ;

(b) Sollve your equations iteratively performing 1 cycle of your iteration scheme taking the initial values for the concentrations at as 20, 30, 40 concentration units respectively. (5 marks)

shall use the Gauss-Seidal iteration scheme to solve the set of equations;

63

First cycle

Ta Cycle using given figures 1st cycle Resultant Values 20 23.13 23

Tb 30 33.28 33

Tc 40 40.82 41

(c) Verify that the Fourier series

Is a solution of the wave equation given by (10 marks)

(x is the position and s and c are constants, j =

64

65

66

67

Bibliography

Advanced electromagnetism: foundations, theory and applications By Terence William Barrett, Dale M. Grimes

Essentials of engineering mathematics By Alan Jeffery

Engineering Mathematics 6th Edition By K.A Stroud

68

Vous aimerez peut-être aussi