-
Notifications
You must be signed in to change notification settings - Fork 38
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
TypeError: in fieldtype, expected DataType, got Type{Union{}} #43
Comments
It seems you were entering |
Thank you for your reply, I wanted to test geneigsolve in the most simplest case (with B = I) in order to understand it before really using it. That being said, I think that there are an issue with Tridiagonal matrix. When I define A and M by: julia> diagM = [1.0 for 1 in 1:100]; julia> diagM = [1.0 for i in 1:100]; julia> M = SymTridiagonal(diagM, subdiagM); julia> subdiagA = [-0.5 for i in 1:99]; julia> A = SymTridiagonal(diagM, subdiagA); and when I try geneigsolve((A,M), 3, :SR), I get: ERROR: MethodError: no method matching cholesky(::Hermitian{Float64,SymTridiagonal{Float64,Array{Float64,1}}}; check=false) Thank you in advance. |
I have found out ! With convert(Array, A), the bug is fixed.... |
This seems to be a bug in Julia, namely That being said, if you are confident that the |
I think this is solved; feel free to reopen if not. |
Sir,
I am struggling with the method geneigsolve of KrylovKit. With the Clement matrix C of size 101*101 whose the lowest eigenvalue is -100, when I use eigsolve: it works:
eigsolve(C, 2, :SR, eltype(C))
(Complex{Float64}[-100.00000000000057 + 0.0im, -97.9999999999994 + 0.0im], Array{Complex{Float64},1}[[-5.934823977225039e-17 + 0.0im, 3.320208037214963e-17 + 0.0im, 4.9512960751656277e-17 + 0.0im, -1.0008367950905649e-16 + 0.0im, 1.9294724938278272e-16 + 0.0im, -1.567962742202036e-17 + 0.0im, -3.9153858197655655e-17 + 0.0im, 3.1427591972433225e-18 + 0.0im, -7.05722251471179e-17 + 0.0im, 1.7906628918386472e-16 + 0.0im … 5.564153874360254e-16 + 0.0im, -4.962583320636797e-17 + 0.0im, -2.350694315844001e-16 + 0.0im, 1.7194234008369993e-16 + 0.0im, -1.4898044751323327e-16 + 0.0im, 2.1723558020234293e-16 + 0.0im, -1.6117744893327697e-16 + 0.0im, 1.2940048266310558e-16 + 0.0im, 4.700943375695305e-17 + 0.0im, -9.93535915208007e-17 + 0.0im], [-2.125811387704412e-18 + 0.0im, -2.1103217340835757e-17 + 0.0im, 4.0638801159622474e-17 + 0.0im, 3.0122951033892746e-17 + 0.0im, -7.833453391488912e-17 + 0.0im, 2.2458218145930223e-17 + 0.0im, 1.3680484459243355e-16 + 0.0im, -1.811268606205335e-16 + 0.0im, 3.0930102966243023e-16 + 0.0im, -7.470590659650482e-16 + 0.0im … -8.288981774225782e-16 + 0.0im, 2.856106009589991e-16 + 0.0im, -3.289414921445156e-16 + 0.0im, 3.156433357758001e-16 + 0.0im, 1.5492772606972423e-17 + 0.0im, -1.0742140666038115e-16 + 0.0im, 5.890215683339088e-17 + 0.0im, 5.669760393049083e-17 + 0.0im, -3.249941094882854e-17 + 0.0im, -4.870621770281174e-18 + 0.0im]], ConvergenceInfo: 2 converged values after 13 iterations and 171 applications of the linear map;
norms of residuals are given by (4.9392800197204625e-15, 3.152148007644767e-13).
)
But when I try geneigsolve, I got a error message that I don't understand, see below:
geneigsolve((C,I), 1, :SR, promote_type(eltype(C),eltype(I)))
ERROR: TypeError: in fieldtype, expected DataType, got Type{Union{}}
Stacktrace:
[1] tuple_type_head(::Type{T} where T) at ./essentials.jl:208
[2] geneigsolve(::Tuple{Tridiagonal{Float64,Array{Float64,1}},UniformScaling{Bool}}, ::Array{Float64,1}, ::Int64, ::Symbol; kwargs::Base.Iterators.Pairs{Union{},Union{},Tuple{},NamedTuple{(),Tuple{}}}) at /Users/etiennebernard/.julia/packages/KrylovKit/OLgKs/src/eigsolve/geneigsolve.jl:148
[3] geneigsolve(::Tuple{Tridiagonal{Float64,Array{Float64,1}},UniformScaling{Bool}}, ::Array{Float64,1}, ::Int64, ::Symbol) at /Users/etiennebernard/.julia/packages/KrylovKit/OLgKs/src/eigsolve/geneigsolve.jl:146
[4] geneigsolve(::Tuple{Tridiagonal{Float64,Array{Float64,1}},UniformScaling{Bool}}, ::Int64, ::Symbol, ::Type{T} where T; kwargs::Base.Iterators.Pairs{Union{},Union{},Tuple{},NamedTuple{(),Tuple{}}}) at /Users/etiennebernard/.julia/packages/KrylovKit/OLgKs/src/eigsolve/geneigsolve.jl:139
[5] geneigsolve(::Tuple{Tridiagonal{Float64,Array{Float64,1}},UniformScaling{Bool}}, ::Int64, ::Symbol, ::Type{T} where T) at /Users/etiennebernard/.julia/packages/KrylovKit/OLgKs/src/eigsolve/geneigsolve.jl:139
[6] top-level scope at REPL[32]:1
Sincerely,
Etienne
The text was updated successfully, but these errors were encountered: