Docsity
Docsity

Prepare for your exams
Prepare for your exams

Study with the several resources on Docsity


Earn points to download
Earn points to download

Earn points by helping other students or get them with a premium plan


Guidelines and tips
Guidelines and tips

Solving Linear Programs with the Simplex Algorithm: An Example, Exams of Linear Algebra

An example of how to solve a linear program using the simplex algorithm. The example includes setting up the initial simplex table, determining the pivot point, performing pivots, and continuing the algorithm until the maximum value of the objective function is found. The document also includes a linear program related to a furniture factory and its production constraints.

Typology: Exams

Pre 2010

Uploaded on 03/16/2009

koofers-user-k8x-1
koofers-user-k8x-1 🇺🇸

10 documents

1 / 20

Toggle sidebar

Related documents


Partial preview of the text

Download Solving Linear Programs with the Simplex Algorithm: An Example and more Exams Linear Algebra in PDF only on Docsity! Math 125 – Exam 2 – Version 1 March 28, 2007 60 points possible 1. (5pts) By multiplying out and combining like terms, simplify the matrix expression [(A−B)(A + B)]A−1. Solution: Using the distributive from the left, [(A−B)A + (A−B)B]A−1. By the distributive property from the right, [AA + AB −BA−BB]A−1. Again, using the distributive property from the right, AAA−1 + ABA−1 −BAA−1 −BBA−1. Using the properties of inverses, A + ABA−1 −B −BBA−1. By definition of matrix powers, A + ABA−1 −B −B2A−1. (Note: You were not required to state which arithmetic property you were using for full credit.) 2. The Finest Furniture Factory makes beds, chairs, and couches from the raw materials time (man-hours), lumber (board feet), and cloth (yards). Let there be a profit of $18 per bed, $20 per chair, and $32 per couch, and let the supplies be 88 man-hours, 240 feet of lumber, and 28 yards of cloth. Further, assume that it takes 4 man-hours, 18 feet of lumber, and 6 yards of cloth to make a bed; 8 man-hours, 12 feet of lumber, and 2 yards of cloth to make a chair; and 8 man-hours, 24 feet of lumber, and 4 yards of cloth to make a couch. (a) (7pts) Set up but do not solve a linear program that enables the Factory to maximize profit. Assume that the Factory will sell everything it produces. Solution: The above information can be organized in the following table: bed chair couch supplies time (in man-hours) 4 8 8 88 lumber (in board feet) 18 12 24 240 cloth (in yards) 6 2 4 28 profit in dollars 18 20 32 (Note: You did not have to table the information for credit.) Let x = the number of beds manufactured, y = the number of chairs manufactured, and z = the number of couches manufactured. The objective here is to maximize profit. The profit function is P = 18x + 20y + 32z. Since there is only 88 man-hours available, we get the inequality 4x + 8y + 8z ≤ 88. Similarly, due to the 240 board feet of lumber available, we get a lumber inequality of 18x + 12y + 24z ≤ 240. Lastly, there is only 28 yards of cloth. This results in the inequality 6x + 2y + 4z ≤ 28. Lastly, we know that our variables need to be non-negative. (It doesn’t make sense to manufacture a negative number of items.) That is, x ≥ 0. y ≥ 0, and z ≥ 0. The above discussion accurately describes the linear program. One could choose to represent this in its mathematical form: maximize P = 18x + 20y + 32z subject to 4x + 8y + 8z ≤ 88 18x + 12y + 24z ≤ 240 6x + 2y + 4z ≤ 28 x ≥ 0, y ≥ 0, z ≥ 0 (Note: You did not have to order the linear program like this for credit.) (d) (3pts) Continue to use the simplex algorithm to attempt to solve the given linear program. If a solution exist, clearly state the conclusion. If a solution does not exist, explain how the algorithm demonstrated this and what the geometrical reason for no solution must be. Solution: The algorithm is stuck. The third column still starts with a negative entry, but there are no positive pivot candidates in that column to pivot on. We know that this means that this linear program does not have a maximum. The only possible explanation is that the feasibility region must be unbounded and the value of the objective function can continue to grow unboundedly. 4. (a) (3pts) Calculate the product [ α 2 1 β ] [ 3 2 −2 1 ] . Solution: [ α(3) + 2(−2) α(2) + 2(1) 1(3) + β(−2) 1(2) + β(1) ] = [ 3α− 4 2α + 2 3− 2β 2 + β ] . (b) (2pts) Are there values for α and β such that the following equation is satisfied? Clearly justify your answer. [ α 2 1 β ] [ 3 2 −2 1 ] = −2 [ 5 1 3/2 0 ] . Solution: Using our answer from part (a), [ 3α− 4 2α + 2 3− 2β 2 + β ] = −2 [ 5 1 3/2 0 ] . Using the definition of scalar multiplication of a matrix, [ 3α− 4 2α + 2 3− 2β 2 + β ] = [−10 −2 −3 0 ] . For this matrix equation to be satisfied, we require that the system of equations 3α− 4 = −10 2α + 2 = −2 3− 2β = −3 2 + β = 0 must have a single solution of α and β. Although α = −2 satisfies the first two equations, the third and the fourth equation require that β = 3 and β = −2, respectively. Hence, there are no values of α and β that will satisfy this matrix equation. 5. (5pts) Compute ∣∣∣∣∣∣ x y 0 0 3 1 2 0 1 ∣∣∣∣∣∣ . Solution: We can chose to expand the determinant on across any row or down any column. For simplicity, I choose to expand across the first row. ∣∣∣∣∣∣ x y 0 0 3 1 2 0 1 ∣∣∣∣∣∣ = a11A11 + a12A12 + a13A13 = a11(−1)1+1M11 + a12(−1)1+2M12 + a13(−1)1+3M13 = a11M11 − a12M12 + a13M13 = x ∣∣∣∣ 3 1 0 1 ∣∣∣∣− y ∣∣∣∣ 0 1 2 1 ∣∣∣∣ + 0 ∣∣∣∣ 0 3 2 0 ∣∣∣∣ = x[3(1)− (1)0]− y[0(1)− (1)2] + 0 = 3x + 2y 7. Let a small economy contain agriculture, manufacturing, and labor industries. Let $1 of agricultural production require $0.50 in agriculture, $0.20 in manufacturing, and $1 in labor. Let $1 of manufacturing production use $0.80 in manufacturing and $0.40 labor, while a $1 in labor takes $0.25 in agriculture and $0.10 in manufacturing. (a) (3pts) Construct the consumption matrix for this model. Clearly label the matrix. Solution: agriculture manufacturing labor C =   .5 .2 .1 0 .8 .4 .25 .10 0   agriculture used manufacturing used labor used (b) (2pts) Define what it means for an economy to be productive. Solution: An economy is productive if given any external demand ( ~D), there is a pro- duction schedule ( ~X) that can meet the demand. Mathematically, there is an ~X such that ~X = [I−C]−1 ~D has all positive entries for any demand vector ~D. Either answer is acceptable. (c) (2pts) Clearly explain why this economy is a productive economy. Solution: The only way to show this economy is productive is to show that [I − C]−1 is a positive matrix. [I − C]−1 =   16 10 5 30 25 10 28 20 10   (d) (3pts) Find the production schedule if demand is for $10,000,000 in agriculture, $50,000,000 in manufacturing, and $70,000,000 in labor. Solution: We use this information to form the demand vector ~D =   10 50 70   where the units on this vector are millions of dollars. We need to solve for the production vector ~X. ~X = [I − C]−1 ~D =   1010 2250 1980   The production schedule that meets this demand is for the economy to produce $1.01 billions dollars in agriculture, $2.25 billion dollars in manufacturing, $1.98 billion dollars in services. 8. (5pts) Determine if the following statement is true or false. For each part, you will receive 1 point for a correct answer, −1 point for an incorrect answer, and 0 points for no answer. The lowest possible score on this problem is zero. (a) For any matrix A, both AAt and AtA are defined. Solution: FALSE. This is only true if A is a square matrix. (b) If A and B are such that AB = 0 and A 6= 0, then B = 0. Solution: FALSE. This is only true if A is an invertible matrix. (c) Matrix multiplication is associative. Solution: TRUE. This is one of the properties of matrix multiplication. (d) Every matrix A has an additive inverse. Solution: TRUE. For any matrix A, the matrix (−1)A = −A is the additive inverse. (A + (−A) = 0 and (−A) + A = 0.) (e) The product of a 2× 3 matrix and a 3× 5 matrix is a matrix that is 5× 2. Solution: FALSE. The product of a 2 × 3 matrix and a 3 × 5 matrix is a matrix that is 2× 5. (f) If A and B are invertible, then A + B is invertible. Solution: FALSE. This was a homework question. (g) The determinant of a matrix can be evaluated using expansion by cofactors in any row or column. Solution: TRUE. This is part of the cofactor expansion of the determinant definition. Math 125 – Exam 2 – Version 2 March 28, 2007 60 points possible 1. Consider the linear system x− 3y + 2z = −1 −4x + 12y − 7z = 8. (a) (3pts) Write the above system as a matrix equation. Solution: [ 1 −3 2 −4 12 −7 ]   x y z   = [−1 8 ] . (b) (2pts) Explain why the use of a matrix inverse is not an acceptable way to solve this system. Solution: To solve for the variable vector, we would need to multiply (on the left) by the inverse of the coefficient matrix. But, this is not possible since the coefficient matrix is not square. Inverses only exist for square matrices. (c) (3pts) Perform the first pivot dictated by the simplex algorithm and determine the basic feasible solution for the resulting table. Solution: The next simplex table:   1 4 0 −21 0 3 0 300 0 0 0 12 1 −3 0 120 0 1/3 1 −2 0 1/3 0 100/3 0 −1/3 0 5 0 −1/3 1 950/3   . The basic feasible solution for this table is x1 = 0, x2 = 100/3, x3 = 0, x4 = 120, x5 = 0 and x6 = 950/3 or (0, 100/3, 0, 120, 0, 950/3). (d) (3pts) Continue to use the simplex algorithm to attempt to solve the given linear pro- gram. If a solution exists, clearly state the conclusion. If a solution does not exist, explain how the algorithm demonstrated this and what the geometrical reason for no solution must be. Solution: The next pivot point is the 12 located in the column leading with the −21. This yields the next simplex table.   1 4 0 0 7/4 −9/4 0 510 0 0 0 1 1/12 −1/4 0 10 0 1/3 1 0 1/6 −1/6 0 160/3 0 −1/3 0 0 −5/12 11/12 1 800/3   . Now the pivot column has moved to the x5 slack variable column. There is only one positive entry in that column to pivot on. This yields the next, and final, simplex table.   1 35/11 0 0 8/11 0 27/11 12810/11 0 −1/11 0 1 −1/33 0 3/11 910/11 0 3/11 1 0 1/11 0 2/11 1120/11 0 −4/11 0 0 −5/11 1 12/11 3200/11   . Now that there are no columns that begin with a negative number, we know that the simplex algorithm is complete. Using the table, we see that the maximum z value is 12810 11 and occurs at the point ( 0, 1120 11 , 910 11 ) . 4. Suppose P is 3 × 2, Q is 2 × 1, R is 1 × 3 and S is 3 × 3. Clearly explain whether the following expressions exist. If they do exist, determine the size of the resultant matrix. (a) (3pts) 2PQR. Solution: Note that the scalar multiple 2 has no bearing on whether the product is sensible or not. Recall that to multiply two matrices, we need the number of columns of the first matrix to equal the number of rows of the second. Look at the product PQR. PQR = [3× 2][2× 1][1× 3] = [3× 1][1× 3] = 3× 3 Therefore, the product makes sense and the resultant matrix is a 3× 3 matrix. (b) (2pts) QR− SPQ Solution: In this problem, the products make sense. QR becomes a 2× 3 matrix and SPQ becomes a 3 × 1 matrix. What we can not do is add these matrices together. Recall that subtraction is just the combination of addition and multiplication by the scalar (−1). In order to add matrices, they must be the same dimension. Since QR and SPQ are of different dimensions, this expression does not make sense. 5. (5pts) Calculate the first iteration of the determinant of A =   4 6 2 3 1 5 0 −1 2 4 −3 0 0 3 1 5   by ex- panding down the second column. Solution: Expanding down the second column, det A = a12A12 + a22A22 + a32A32 + a42A42 = a12(−1)1+2M12 + a22(−1)2+2M22 + a32(−1)3+2M32 + a32(−1)4+2M42 = −a12M12 + a22M22 − a32M32 + a42M42 = −6M12 + 5M22 − 4M32 + 3M42 = −6 ∣∣∣∣∣∣ 1 0 −1 2 −3 0 0 1 5 ∣∣∣∣∣∣ + 5 ∣∣∣∣∣∣ 4 2 3 2 −3 0 0 1 5 ∣∣∣∣∣∣ − 4 ∣∣∣∣∣∣ 4 2 3 1 0 −1 0 1 5 ∣∣∣∣∣∣ + 3 ∣∣∣∣∣∣ 4 2 3 1 0 −1 2 −3 0 ∣∣∣∣∣∣
Docsity logo



Copyright © 2024 Ladybird Srl - Via Leonardo da Vinci 16, 10126, Torino, Italy - VAT 10816460017 - All rights reserved