Opened 6 years ago

Closed 6 years ago

#14537 closed defect (fixed)

Composition of morphisms

Reported by: tfeulner Owned by: nthiery
Priority: major Milestone: sage-5.11
Component: categories Keywords: composition, morphisms, sd48
Cc: SimonKing Merged in: sage-5.11.beta3
Authors: Thomas Feulner Reviewers: Volker Braun
Report Upstream: N/A Work issues:
Branch: Commit:
Dependencies: Stopgaps:

Description (last modified by nthiery)

The following code leads to a TypeError?:

sage: F.<a> = GF(4)
sage: f = F.Hom(F).identity()
sage: g = F.hom([a])
sage: h = (g*f)
sage: f*h
...
TypeError: right (=Composite map:
  From: Finite Field in a of size 2^2
  To:   Finite Field in a of size 2^2
  Defn:   Identity endomorphism of Finite Field in a of size 2^2
        then
          Ring endomorphism of Finite Field in a of size 2^2
          Defn: a |--> a) must be a morphism to multiply it by Identity endomorphism of Finite Field in a of size 2^2

The problem is solved by relaxing the type checking in the multiplication procedure to accept Maps and not only Morphisms

Attachments (1)

trac_14537_identity_morphism.patch (1.2 KB) - added by tfeulner 6 years ago.

Download all attachments as: .zip

Change History (6)

Changed 6 years ago by tfeulner

comment:1 Changed 6 years ago by tfeulner

  • Description modified (diff)
  • Status changed from new to needs_review

comment:2 Changed 6 years ago by vbraun

  • Authors set to Thomas Feulner
  • Keywords sd48 added
  • Reviewers set to Volker Braun
  • Status changed from needs_review to positive_review

Looks good to me

comment:3 Changed 6 years ago by nthiery

  • Description modified (diff)

comment:4 Changed 6 years ago by nthiery

  • Description modified (diff)

comment:5 Changed 6 years ago by jdemeyer

  • Merged in set to sage-5.11.beta3
  • Resolution set to fixed
  • Status changed from positive_review to closed
Note: See TracTickets for help on using tickets.