How does the identity Ln(detA)=Tr(lnJ) hold true?

  • Context: Graduate 
  • Thread starter Thread starter LAHLH
  • Start date Start date
  • Tags Tags
    Identity
Click For Summary
SUMMARY

The identity log(det(A)) = Tr(log(A)) holds true under specific conditions, particularly when A is a square matrix with non-zero eigenvalues. The proof relies on the properties of matrix exponentials and the relationships between eigenvalues, determinants, and traces. Specifically, if λ is an eigenvalue of A, then e^λ is an eigenvalue of e^A, and log(λ) is an eigenvalue of log(A). The manipulation of these identities confirms the validity of the equation, provided that the matrix A can be diagonalized and its eigenvalues are positive or appropriately handled using complex logarithms.

PREREQUISITES
  • Understanding of matrix exponentials and logarithms
  • Familiarity with eigenvalues and eigenvectors
  • Knowledge of the properties of determinants and traces
  • Basic concepts of diagonalization of matrices
NEXT STEPS
  • Study the properties of matrix exponentials in detail
  • Learn about the diagonalization process of matrices
  • Explore the implications of complex logarithms in linear algebra
  • Investigate the conditions under which eigenvalues can be negative
USEFUL FOR

Mathematicians, physicists, and engineers who work with linear algebra, particularly those involved in fields requiring matrix analysis and transformations.

LAHLH
Messages
405
Reaction score
2
Hi,

I've come across the identity det(expA)=exp(Tr(A)) many times now, but recently came across log(detA)=Tr(log(A)), can anyone explain to me why this is true? or if it can be derived from the more familiar first identity?

I'm not sure if there are any particular constraints the matrix must satisfy for the identity, it was a field theory book in which I saw it, so I guess the author could be assuming a couple of things about the matrices (maybe unitary for example)

cheers
 
  • Like
Likes   Reactions: zuu
Physics news on Phys.org
LAHLH said:
Hi,

I've come across the identity det(expA)=exp(Tr(A)) many times now, but recently came across log(detA)=Tr(log(A)), can anyone explain to me why this is true? or if it can be derived from the more familiar first identity?

I know very little about matrix exponentials, but if you make the substitution A = log(B), and substitute into your identity and take the log of both sides, you get the result you desire:
<br /> \det B = \det(\exp(\log(B))) = \det(\exp(A)) =\exp(\text{Tr}(A)) = \exp(\text{Tr}(\log(B)))<br />
<br /> \log(\det B) = \log(\exp(\text{Tr}(\log B))) = \text{Tr}(\log B)<br />

I don't know under what conditions these manipulations are justified, though...
 
Last edited:
  • Like
Likes   Reactions: zuu
Hi LAHLH! :smile:

It so happens that all steps of spamiam are justified in this case.
This can be verified by checking the steps with the definitions of the http://en.wikipedia.org/wiki/Matrix_exponential" .

Note that the key concept to the regular proof is the observation that if λ is an eigenvalue of A, that eλ is an eigenvalue of eA, and that log(λ) is an eigenvalue of log(A).

Furthermore det(A) is the product of eigenvalues, and Tr(A) is the sum of eigenvalues.
Since log and exp convert sums and products into each other, the respective formulas follow.
 
Last edited by a moderator:
If A is a square matrix, then we can diagonalize it:
<br /> \mathbf{A} \cdot \mathbf{U} = \mathbf{U} \cdot \mathbf{\Lambda}<br />
where \mathbf{\Lambda} is a diagonal matrix with the eigenvalues of [itex[\mathbf{A}[/itex] along its diagonal and the columns of the matrix \mathbf{U} are the corresponding eigenvectors.

Then, we can wrie:
<br /> \mathbf{A} = \mathbf{U} \cdot \mathbf{\Lambda} \cdot \mathbf{U}^{-1}<br />
provided that \mathbf{U}^{-1} exists (which means that the eigenvectors of A form a complete basis). Let us assume this to be the case.

Then, any function of the matrix A, f(\mathbf{A}), is defined as:
<br /> f(\mathbf{A}) = \mathbf{U} \cdot f(\mathbf{\Lambda}) \cdot \mathbf{U}^{-1}<br />
where f(\mathbf{\Lambda}) is the diagonal matrix f( \mathbf{\Lambda}) = \mathrm{diag} \left( \lbrace f(\lambda_{\alpha}) \rbrace \right).

If you find the determinant:
<br /> \det{ \left[ f(\mathbf{A}) \right]} = \det{ \left[ \mathbf{U} \cdot f( \mathbf{\Lambda} ) \cdot \mathbf{U}^{-1} \right] } = \det{\left[ \mathbf{U} \right]} \, \det{\left[ f(\mathbf{\Lambda}) \right]} \, \frac{1}{\det{\left[ \mathbf{U} \right]}}<br />
<br /> \det{ \left[ f(\mathbf{A} ) \right] } = \det{ \left[ f( \mathbf{\Lambda} ) \right] } = \prod_{\alpha}{f(\lambda_{\alpha})}<br />
The last step follows from the fact that the determinant of a diagonal matrix is the product of the diagonal elements.

A similar rule holds for the trace:
<br /> \mathrm{Tr} \left[ f(\mathbf{A}) \right] = \mathrm{Tr} \left[ \mathbf{U} \cdot f(\mathbf{\Lambda}) \cdot \mathbf{U}^{-1} \right] = \mathrm{Tr} \left[ \mathbf{U}^{-1} \cdot \mathbf{U} \cdot f(\mathbf{\Lambda}) \right] = \mathrm{Tr} \left[ f(\mathbf{\Lambda}) \right] = \sum_{\alpha}{f(\lambda_{\alpha})}<br />
where we used the "cyclic property of the trace" and its definition as a sum of the diagonal elements in the last step.

Now, if you use some properties of the exponential function, it is not hard to prove:
<br /> \det{ \left[ \exp{ \left( \mathbf{A} \right) } \right] } = \exp{ \left( \mathrm{Tr} \left[ \mathbf{A} \right] \right)}<br />

Now, assuming \mathbf{A} has only positive eigenvalues, you can define \ln{\mathbf{A}}. If you write down the above identity for that matrix and take the logarithm of both sides, you will get your required identity.
 
Last edited:
Dickfore said:
If A is a square matrix, then we can diagonalize it:
<br /> \mathbf{A} \cdot \mathbf{U} = \mathbf{U} \cdot \mathbf{\Lambda}<br />
where \mathbf{\Lambda} is a diagonal matrix with the eigenvalues of [itex[\mathbf{A}[/itex] along its diagonal and the columns of the matrix \mathbf{U} are the corresponding eigenvectors.

Then, we can wrie:
<br /> \mathbf{A} = \mathbf{U} \cdot \mathbf{\Lambda} \cdot \mathbf{U}^{-1}<br />
provided that \mathbf{U}^{-1} exists (which means that the eigenvectors of A form a complete basis). Let us assume this to be the case.

Uhh :rolleyes: that is quite an assumption.


Dickfore said:
Then, any function of the matrix A, f(\mathbf{A}), is defined as:
<br /> f(\mathbf{A}) = \mathbf{U} \cdot f(\mathbf{\Lambda}) \cdot \mathbf{U}^{-1}<br />
where f(\mathbf{\Lambda}) is the diagonal matrix f( \mathbf{\Lambda}) = \mathrm{diag} \left( \lbrace f(\lambda_{\alpha}) \rbrace \right).

If you find the determinant:
<br /> \det{ \left[ f(\mathbf{A}) \right]} = \det{ \left[ \mathbf{U} \cdot f( \mathbf{\Lambda} ) \cdot \mathbf{U}^{-1} \right] } = \det{\left[ \mathbf{U} \right]} \, \det{\left[ f(\mathbf{\Lambda}) \right]} \, \frac{1}{\det{\left[ \mathbf{U} \right]}}<br />
<br /> \det{ \left[ f(\mathbf{A} ) \right] } = \det{ \left[ f( \mathbf{\Lambda} ) \right] } = \prod_{\alpha}{f(\lambda_{\alpha})}<br />
The last step follows from the fact that the determinant of a diagonal matrix is the product of the diagonal elements.

A similar rule holds for the trace:
<br /> \mathrm{Tr} \left[ f(\mathbf{A}) \right] = \mathrm{Tr} \left[ \mathbf{U} \cdot f(\mathbf{\Lambda}) \cdot \mathbf{U}^{-1} \right] = \mathrm{Tr} \left[ \mathbf{U}^{-1} \cdot \mathbf{U} \cdot f(\mathbf{\Lambda}) \right] = \mathrm{Tr} \left[ f(\mathbf{\Lambda}) \right] = \sum_{\alpha}{f(\lambda_{\alpha})}<br />
where we used the "cyclic property of the trace" and its definition as a sum of the diagonal elements in the last step.

How did you get \mathrm{Tr} \left[ \mathbf{U} \cdot f(\mathbf{\Lambda}) \cdot \mathbf{U}^{-1} \right] = \mathrm{Tr} \left[ \mathbf{U}^{-1} \cdot \mathbf{U} \cdot f(\mathbf{\Lambda}) \right]?


Dickfore said:
Now, if you use some properties of the exponential function, it is not hard to prove:
<br /> \det{ \left[ \exp{ \left( \mathbf{A} \right) } \right] } = \exp{ \left( \mathrm{Tr} \left[ \mathbf{A} \right] \right)}<br />

Now, assuming \mathbf{A} has only positive eigenvalues, you can define \ln{\mathbf{A}}. If you write down the above identity for that matrix and take the logarithm of both sides, you will get your required identity.

Shouldn't negative eigenvalues also work in combination with the complex logarithm?
 
I like Serena said:
Uhh :rolleyes: that is quite an assumption.
Yes, and I stated when this is the case.

I like Serena said:
How did you get \mathrm{Tr} \left[ \mathbf{U} \cdot f(\mathbf{\Lambda}) \cdot \mathbf{U}^{-1} \right] = \mathrm{Tr} \left[ \mathbf{U}^{-1} \cdot \mathbf{U} \cdot f(\mathbf{\Lambda}) \right]?

By the "cyclic property of the trace":
<br /> \mathrm{Tr} \left[ \mathbf{A} \cdot \mathbf{B} \cdot \mathbf{C} \right] = \mathrm{Tr} \left[ \mathbf{B} \cdot \mathbf{C} \cdot \mathbf{A} \right] = \mathrm{Tr} \left[ \mathbf{C} \cdot \mathbf{A} \cdot \mathbf{B} \right]<br />
I like Serena said:
Shouldn't negative eigenvalues also work in combination with the complex logarithm?
Actually, if we perform the analytic continuation for the logarithm, it can hold for any complex eigenvalues. However, for the principal branch of the logarithm:
<br /> \mathrm{Log}{(z_1 z_2)} \neq \mathrm{Log}{(z_1)} + \mathrm{Log}{(z_2)}<br />
For example:
<br /> z_1 = \frac{-1 + i \sqrt{3}}{2} = e^{i \frac{2 \pi}{3}} \Rightarrow \mathrm{Log}{(z_1)} = i \frac{2 \pi}{3}<br />
and
<br /> z_2 = i = e^{i \frac{\pi}{2}} \Rightarrow \mathrm{Log}{(z_2)} = i \frac{\pi}{2}<br />
<br /> z_1 z_2 = \frac{-\sqrt{3} - i}{2} = e^{i \frac{7 \pi}{6}} \Rightarrow \mathrm{Log}{(z_1 z_2)} = -i \frac{5 \pi}{6}<br />
This is not equal to:
<br /> \mathrm{Log}{(z_1)} + \mathrm{Log}{(z_2)} = i \frac{7 \pi}{6}<br />

So, in general, one cannot use:
<br /> \mathrm{Log}{\left( \prod_{\alpha}{\lambda_\alpha} \right)} \neq \sum_{\alpha}{\mathrm{Log}{( \lambda _\alpha )}}<br />
 
Dickfore said:
Yes, and I stated when this is the case.

Couldn't it be generalized by specifying that \mathbf \Lambda is a Jordan normal form?
Then \mathbf U would hold the generalized eigenvectors.



Dickfore said:
By the "cyclic property of the trace":
<br /> \mathrm{Tr} \left[ \mathbf{A} \cdot \mathbf{B} \cdot \mathbf{C} \right] = \mathrm{Tr} \left[ \mathbf{B} \cdot \mathbf{C} \cdot \mathbf{A} \right] = \mathrm{Tr} \left[ \mathbf{C} \cdot \mathbf{A} \cdot \mathbf{B} \right]<br />

Ah, okay! :)


Dickfore said:
Actually, if we perform the analytic continuation for the logarithm, it can hold for any complex eigenvalues. However, for the principal branch of the logarithm:
<br /> \mathrm{Log}{(z_1 z_2)} \neq \mathrm{Log}{(z_1)} + \mathrm{Log}{(z_2)}<br />

Yes, but don't the steps in the proof hold if we calculate with all branches?

So
<br /> \mathrm{Log}(e^{i \frac \pi 3})=\{i(\frac \pi 3 + 2k\pi) : k \in \mathbb Z\}<br />
 
I like Serena said:
Couldn't it be generalized by specifying that \mathbf \Lambda is a Jordan normal form?
Then \mathbf U would hold the generalized eigenvectors.
Maybe, I am not that familiar with Jordan normal forms. The procedure depends sensitively on the existence of \mathbf{U}^{-1}. If you notice the above proof of the equality \det{\left[ \exp{\left( \mathbf{A} \right)} \right]} = \exp{\left( \mathrm{Tr}\left[ \mathbf{A} \right]\right)} depended twice on the existince of the inverse matrix of eigenvector columns.
I like Serena said:
Yes, but don't the steps in the proof hold if we calculate with all branches?

So
<br /> \mathrm{Log}(e^{i \frac \pi 3})=\{i(\frac \pi 3 + 2k\pi) : k \in \mathbb Z\}<br />
If you use the multiple valued function \log, then:
<br /> \exp{\left( \log{(z)} \right)} = z<br />
BUT
<br /> \log{\left( \exp{(z)} \right)} = z + 2 k \pi i \neq z<br />

If you start from the identity \det{\left[ \exp{\left( \mathbf{A} \right)} \right]} = \exp{\left( \mathrm{Tr}\left[ \mathbf{A} \right]\right)} in order to prove \log{ \left( \det{\left[ \mathbf{A} \right]} \right)} = \mathrm{Tr} \left[ \log{(\mathbf{A})} \right] in the last step you do take the logarithm on both sides. So, you must be careful to show that this equality holds as a set equality. In either case, \det{\left[\mathbf{A}\right]} \neq 0 must hold, that is 0 must not be an eigenvalue of the matrix \mathbf{A}.
 
Dickfore said:
If you use the multiple valued function \log, then:
<br /> \exp{\left( \log{(z)} \right)} = z<br />
BUT
<br /> \log{\left( \exp{(z)} \right)} = z + 2 k \pi i \neq z<br />

If you start from the identity \det{\left[ \exp{\left( \mathbf{A} \right)} \right]} = \exp{\left( \mathrm{Tr}\left[ \mathbf{A} \right]\right)} in order to prove \log{ \left( \det{\left[ \mathbf{A} \right]} \right)} = \mathrm{Tr} \left[ \log{(\mathbf{A})} \right] in the last step you do take the logarithm on both sides. So, you must be careful to show that this equality holds as a set equality. In either case, \det{\left[\mathbf{A}\right]} \neq 0 must hold, that is 0 must not be an eigenvalue of the matrix \mathbf{A}.

Ah, I see.
I guess the complex logarithm is a bit more troublesome than I thought!

But then I think the equation log(det A)=Tr(log A) is not quite proper.
Shouldn't it be: log(det A)=Tr(log A) mod i2pi?
The reference to log(det A) implies that all eigenvalues must be ≠ 0.
 
  • #10
I like Serena said:
But then I think the equation log(det A)=Tr(log A) is not quite proper.
Shouldn't it be: log(det A)=Tr(log A) mod i2pi?
The reference to log(det A) implies that all eigenvalues must be ≠ 0.

Yes, and this is what I call a "set equality". Both sides of that equation contain an infinite set of values. You need to show that those sets are equal.

You are right about the determinant not being equal to zero should be implied. I just made a remark in the end of my previous post.
 

Similar threads

  • · Replies 62 ·
3
Replies
62
Views
11K
  • · Replies 1 ·
Replies
1
Views
3K
Replies
9
Views
6K
  • · Replies 2 ·
Replies
2
Views
3K
  • · Replies 14 ·
Replies
14
Views
7K
  • · Replies 39 ·
2
Replies
39
Views
27K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 110 ·
4
Replies
110
Views
24K
  • · Replies 5 ·
Replies
5
Views
5K
  • · Replies 1 ·
Replies
1
Views
3K