You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
julia> x = NamedDimsArray{(:a,)}([1,2,3])
3-element NamedDimsArray{(:a,),Int64,1,Array{Int64,1}}:
1
2
3
julia> x'*x
ERROR: MethodError: no method matching NamedDimsArray{(:_,),T,N,A} where A<:AbstractArray{T,N} where N where T(::Int64)
Correct answer is: 14
Not a Array at all, just a scalar.
The text was updated successfully, but these errors were encountered:
I presume we want to require names match? so (once fixed) this should error?
a =NamedDimsArray{(:a,)}([1,2,3])
b =NamedDimsArray{(:b,)}([1,2,3])
a'* b
What about for dot? Would we want dot(a, b) to error?
Note that dot ignores dimensionality (and check only length), so dot(a, a) == dot(a', a) == dot(a, a') == dot(a', a') (which is probably the correct behaviour, but may not be JuliaLang/LinearAlgebra.jl#641 ...and is anyway maybe surprising at first)
Correct answer is:
14
Not a
Array
at all, just a scalar.The text was updated successfully, but these errors were encountered: