Jacobian: Row Swapping & Factor Extracting

  • Thread starter terryfields
  • Start date
  • Tags
    Jacobian
In summary, the cofactor expansion of a determinant results in the addition or subtraction of terms times a submatrix that is obtained by eliminating rows and columns.
  • #1
terryfields
44
0
how do we get from this line

||d(x,y,z)/d(p,q,r)||= ||sin(q)cos(r), pcos(q)cos(r), -psin(q)sin(r) end of line 1
line 2 sin(q)sin(r), pcos(q)sin(r), psin(q)cos(r) end of line 2
line 3 cos(q), -psin(q), 0||

to the next line where we take out cos(q) to get cos(q)||pcos(q)cos(r), -sin(q)sin(r) end of line 1
line 2 pcos(q)sin(r), psin(q)cos(r)||

i thought to take out a factor like taht you needed a line or a row of zeros where as here we don't have that?

Edit:read it wrong it has -(-psin(q)) of a different matrix after this so I'm guessing all they have done is swaped row 1 and 3 to make things easier, are there any restrictions to row swaping? and I'm guessing you can't column swap at all
 
Last edited:
Physics news on Phys.org
  • #2
additional how to you get the determinant of pcos(a)cos(b) -sin(a)sin(b) line 1
line 2 pcos(a)sinb psin(a)cosb

to come out as p2sin(a)cos(a)??
 
  • #3
Swapping two rows changes the sign of the determinant. Nothing else changes. The same with swapping columns.
 
  • #4
terryfields said:
additional how to you get the determinant of pcos(a)cos(b) -sin(a)sin(b) line 1
line 2 pcos(a)sinb psin(a)cosb

to come out as p2sin(a)cos(a)??

I think you missed a 'p'. Just use cos(b)^2+sin(b)^2=1.
 
  • #5
terryfields said:
how do we get from this line

||d(x,y,z)/d(p,q,r)||= ||sin(q)cos(r), pcos(q)cos(r), -psin(q)sin(r) end of line 1
line 2 sin(q)sin(r), pcos(q)sin(r), psin(q)cos(r) end of line 2
line 3 cos(q), -psin(q), 0||
Just so it's readable (and to practice my typesetting)...
[tex]\left|\frac{\partial(x,y,z)}{\partial(p,q,r)}\right|=
\left|\begin{array}{ccc}{\sin(q)\cos(r) & p\cos(q)\cos(r) & -p\sin(q)\sin(r) &
2\sin(q)\sin(r) & p\cos(q)\sin(r) & p \sin(q)\cos(r) &
3\cos(q) & -p\sin(q) & 0&
} \end{array}
\right| =
[/tex]

[tex] =
3\cos(q)\left|\begin{array}{cc}{
p\cos(q)\cos(r) & -p\sin(q)\sin(r) &
p\cos(q)\sin(r) & p\cos(q)\sin(r) }
\end{array}\right|
-(-p\sin(q))\left| \begin{array}{cc}{
\sin(q)\cos(r) & -p\sin(q)\sin(r) &
2\sin(q)\sin(r) & p\sin(q)\cos(r)
}\end{array}
\right| + 0
[/tex]

to the next line where we take out cos(q) to get cos(q)||pcos(q)cos(r), -sin(q)sin(r) end of line 1
line 2 pcos(q)sin(r), psin(q)cos(r)||

i thought to take out a factor like taht you needed a line or a row of zeros where as here we don't have that?

Edit:read it wrong it has -(-psin(q)) of a different matrix after this so I'm guessing all they have done is swaped row 1 and 3 to make things easier, are there any restrictions to row swaping? and I'm guessing you can't column swap at all

Swapping two rows or two columns will change the sign of the determinant. Multiplying a row or column by a value multiplies the determinant by that value.

What is happening here is cofactor expansion of a determinant. Pick any row or column (best the one with the most zeros) and for each non-zero term you either add or subtract that term times the submatrix you get when you eliminate both the row and column in which that term occurs. The add vs. subtract rule follows the pattern of checkerboard +/- starting with a + for the top left entry. The pattern is:

[tex] \left(\begin{array}{cccc}
+ & - & + \cdots \\
- & + & - \cdots \\
+ & - & + \cdots\\
\vdots & \vdots & \vdots \ddots
\end{array}\right) [/tex]

In this case we expand via the third row with its two non-zero entries. The first entry 3cos(q) ) is in a + position so we add it times the determinant of the matrix we get by eliminating column 1 and row 3.
To this we subtract (- position) the second term(-p sin(q) ) time the submatrix we get by eliminating column 2 and row 3. The zero term needn't be expanded but it would be zero times the submatrix we get by eliminating row 3 and column 3.
 
  • #6
thanks guys, off out now but will read through that later, from first glance i think all my problems are answered =)
 

1. What is the Jacobian matrix?

The Jacobian matrix, also known as the Jacobian, is a matrix of partial derivatives that represents the linear transformation between two vector spaces. It is used in multivariate calculus and differential geometry to calculate the change of variables for a given function.

2. What is row swapping in the Jacobian matrix?

Row swapping in the Jacobian matrix is the process of interchanging the rows of the matrix. This is often done to simplify the matrix or to put it in a specific form that is easier to work with. It does not change the values of the matrix, but it can make it easier to extract factors from the matrix.

3. Why is row swapping useful in the Jacobian matrix?

Row swapping is useful in the Jacobian matrix because it allows for the extraction of factors from the matrix. This makes it easier to perform operations on the matrix, such as calculating determinants or inverting the matrix. It can also help to simplify the matrix and make it easier to understand.

4. What is factor extracting in the Jacobian matrix?

Factor extracting in the Jacobian matrix is the process of finding common factors within the matrix and grouping them together. This is often done after row swapping to simplify the matrix and make it easier to work with. It can also help to reveal patterns and relationships within the matrix.

5. How is the Jacobian matrix used in machine learning?

The Jacobian matrix is used in machine learning to calculate the gradients of a function, which is essential for training machine learning models. It is also used in optimization algorithms, such as gradient descent, to update the parameters of the model. Additionally, the Jacobian matrix is used in neural networks to calculate the backpropagation algorithm, which is used to update the weights of the network during training.

Similar threads

  • Calculus and Beyond Homework Help
Replies
3
Views
557
  • Calculus and Beyond Homework Help
Replies
3
Views
876
  • Calculus and Beyond Homework Help
Replies
10
Views
847
  • Calculus and Beyond Homework Help
Replies
1
Views
825
  • Calculus and Beyond Homework Help
Replies
6
Views
908
  • Calculus and Beyond Homework Help
Replies
8
Views
874
  • Advanced Physics Homework Help
Replies
19
Views
822
Replies
2
Views
777
  • Calculus and Beyond Homework Help
Replies
2
Views
1K
  • Introductory Physics Homework Help
Replies
1
Views
888
Back
Top