Académique Documents
Professionnel Documents
Culture Documents
Course: BEng Building Services Engineering Mode: Part Time Level: Two Unit: Engineering Mathematical Methods Coursework Unit Code: SCE-2-203 Date: Semester 1, 2010
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)
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
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);
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
In order to complete the calculation I will create new matrix Y, it is equal to the product of matrices U and X;
= Therefore;
The components of the Y matrix can now be used to calculate the components of X;
And since
then;
10
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.
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;
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
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
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.
(6 Marks)
In order to evaluate the double integral I will first integrate with respect to y,
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)
=a =a +b
+b
Use this result for the eigenvalues and normalised eigenvectors to calculate the coefficients a, b for the initial condition; = (13 Marks)
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
So
19
20
Where:
Table of
Coefficient a(0)
21
Coefficient 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
(b) Use the techniques of Laplace transformation to solve the differential equation
+ 2y =0,
= 3, y(0) =4
(15 Marks)
23
Given;
Therefore;
24
Therefore;
Question 6 (a) By deriving an expression for s verify that the Fourier Series
25
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;
If x=y then;
27
Temperature at point A;
Temperature at point B;
Temperature at point C;
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.
30
Lagrange equations
Therefore;
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
(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
(18 marks)
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
36
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:
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)
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
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
In order to complete the calculation I will create new matrix Y, it is equal to the product of matrices U and X;
= Therefore;
43
The components of the Y matrix can now be used to calculate the components of X;
And since
then;
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;
46
(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
It can be seen that convergence has been achieved and that the resultant values have been proved to be accurate.
(5 marks)
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;
Determinant of matrix m
(d) Use your result for (c) to evaluate the inverse of; (5 marks)
51
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;
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
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)
In order to obtain a general solution for this differential equation I will use the trial solution method;
54
(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
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)
Lagrange equations
56
(10 marks)
Therefore;
Therefore;
This would indicate that the height would need to be twice the length of the radius. To calculate the radius;
57
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)
Direction of vector From (X,Y) Co-ordinate 0,1 1,0 0,-1 -1,0 0,0
Y
[1,2]
[2,1]
(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
(10 marks)
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)
61
If x=y then;
Temperature at point ;
Temperature at point ;
62
Temperature at point ;
Therefore;
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
Tb 30 33.28 33
Tc 40 40.82 41
64
65
66
67
Bibliography
Advanced electromagnetism: foundations, theory and applications By Terence William Barrett, Dale M. Grimes
68