<pre> Formatting for Examples (#24814)

Adding formatting for examples to make them easier to read.
This commit is contained in:
Logan
2019-02-10 12:20:50 -06:00
committed by Randell Dawson
parent 7adf47c4b5
commit 141951f7a6

View File

@ -31,7 +31,7 @@ Consider the following matrix, which we will call A:
Then the determinant of this matrix, denoted <em>det(A)</em>, is given by: Then the determinant of this matrix, denoted <em>det(A)</em>, is given by:
<em>det(A) = a * (e * i - h * f) - b * (d * i - f * g) + c * (d * h - e * g)</em> <pre><em>det(A) = a * (e * i - h * f) - b * (d * i - f * g) + c * (d * h - e * g)</em></pre>
Please keep in mind the order of operations in the expression above. Please keep in mind the order of operations in the expression above.
@ -57,11 +57,15 @@ For example, consider the following matrix, which we will call B:
<em>det(B)</em> is given by the formula above. We apply the formula below: <em>det(B)</em> is given by the formula above. We apply the formula below:
<em>det(B) = 1 * ( (-3) * 7 - 5 * 4) - 2 * ( 0 * 7 - 5 * (-10)) + 3 * (0 * 4 - (-3) * (-10))</em>, which we simplify to: <pre><em>det(B) = 1 * ( (-3) * 7 - 5 * 4) - 2 * ( 0 * 7 - 5 * (-10)) + 3 * (0 * 4 - (-3) * (-10))</em></pre>
<em>det(B) = 1 * ((-21) - 20) - 2 * (0 - (-50)) + 3 * (0 - (30))</em>, which we simplify to: , which we simplify to:
<em>det(B) = (-41) - 100 - 90 = -231</em> <pre><em>det(B) = 1 * ((-21) - 20) - 2 * (0 - (-50)) + 3 * (0 - (30))</em></pre>
, which we simplify to:
<pre><em>det(B) = (-41) - 100 - 90 = -231</em></pre>
### Method 2 ### Method 2
This method it similar to 2 by 2 determinants, and based on opertations with diagonals This method it similar to 2 by 2 determinants, and based on opertations with diagonals
@ -87,7 +91,7 @@ Again, consider the following matrix, which we will call A:
Then the determinant of this matrix, denoted <em>det(A)</em>, is given by: Then the determinant of this matrix, denoted <em>det(A)</em>, is given by:
<em>det(A) = a * e * i + b * f * g + c * d * h - c * e * g - f * h * a - i * b * d</em> <pre><em>det(A) = a * e * i + b * f * g + c * d * h - c * e * g - f * h * a - i * b * d</em></pre>
Note how three top-right to bottom-left diagonals are positive Note how three top-right to bottom-left diagonals are positive
@ -223,9 +227,12 @@ Consider the same example as in method 2: matrix, which we will call B:
<em>det(B)</em> is given by the formula above. We apply the formula below: <em>det(B)</em> is given by the formula above. We apply the formula below:
<em>det(B) = 1 * (-3) * 7 + 2 * 5 * (-10) + 3 * 0 * 4 - 3 * (-3) * (-10) - 5 * 4 * 1 - 7 * 2 * 0</em>, which we simplify to: <pre><em>det(B) = 1 * (-3) * 7 + 2 * 5 * (-10) + 3 * 0 * 4 - 3 * (-3) * (-10) - 5 * 4 * 1 - 7 * 2 * 0</em></pre>
<em>det(B) = -21 - 100 + 0 - 90 - 20 - 0 = -231</em>, same, as in method 1 , which we simplify to:
<pre><em>det(B) = -21 - 100 + 0 - 90 - 20 - 0 = -231</em></pre>
Which is the same as in method 1
#### More information: #### More information: