Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't compute eigenvalues of Hermitian Diagonal matrix for generic types #54412

Open
araujoms opened this issue May 8, 2024 · 0 comments
Open

Comments

@araujoms
Copy link
Contributor

araujoms commented May 8, 2024

As the title says, the following code fails:

using LinearAlgebra
using GenericLinearAlgebra
m = Hermitian(Diagonal(randn(BigFloat,2)))
eigvals(m)

This is not related to BigFloat, it also fails for Double64 and Float128. I think the underlying issue is the same as #53564, the lack of a universal fallback.

To make life even stranger, after GenericLinearAlgebra is loaded this code starts failing even for Float64. That is,

using LinearAlgebra
m = Hermitian(Diagonal(randn(Float64,2)))
eigvals(m)

works fine, but

using LinearAlgebra
using GenericLinearAlgebra
m = Hermitian(Diagonal(randn(Float64,2)))
eigvals(m)

fails.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant