Skip to content

inv errors for invertible homomorphisms between non-free modules #2439

Description

@matthias314

MWE:

julia> M = FreeModule(ZZ, 1);

julia> N, _ = sub(M, [M([3])]);

julia> Q, _ = quo(M, N)
(Quotient module over integers with 1 generator and relations:
[3], Hom: M -> Q)

julia> f = ModuleHomomorphism(Q, Q, matrix(ZZ[2;;]));

julia> inv(f)
ERROR: DomainError with [2]:
Matrix is not invertible.
Stacktrace:
 [1] inv(M::AbstractAlgebra.Generic.MatSpaceElem{BigInt})
   @ AbstractAlgebra /usr/local/julia-depot/packages/AbstractAlgebra/Y7um3/src/Matrix.jl:3962
 [2] inv(a::AbstractAlgebra.Generic.MatSpaceElem{BigInt})
   @ AbstractAlgebra /usr/local/julia-depot/packages/AbstractAlgebra/Y7um3/src/AbstractAlgebra.jl:77
 [3] inv(f::AbstractAlgebra.Generic.ModuleHomomorphism{BigInt})
   @ AbstractAlgebra.Generic /usr/local/julia-depot/packages/AbstractAlgebra/Y7um3/src/generic/ModuleHomomorphism.jl:150
 [4] top-level scope

In contrast, ModuleIsomorphism works:

julia> g = ModuleIsomorphism(Q, Q, matrix(ZZ[2;;]));

julia> inv(g)
Module isomorphism
  from quotient module over integers with 1 generator and relations:
  [3]
  to quotient module over integers with 1 generator and relations:
  [3]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions