Hi Martin,

Le lundi 8 juin 2015 10:04:08 UTC+2, Martin R a écrit :
>
> Sorry for being slow.  I just tried to make FindStatMap inherit from 
> Morphism, and create its parent "on the fly" (because the parent doesn't do 
> all that much anyway) with 
>
> Morphism.__init__(self, homset(self.domain(), self.codomain())
>
> However, sage complains that homset wants a parent (and self.domain() is just 
> an instance of FindStatCollection, which inherits from Element).
>
>  

> Is there a workaround?  Or did I make a mistake?
>
>
I don't know at all the topic of FindStatMap, but it seems that you have 
touched 
a limitation of Sage's Parent/Element scheme: an object cannot be both a 
Parent 
and an Element (of another Parent)... This of course contrasts with 
Set/Element in 
mathematics. 
Maybe a workaround could be to create a new Parent class from 
FindStatCollection.

Eric. 

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.

Reply via email to