Hi Jeroen, On 2019-02-27, Jeroen Demeyer <j.deme...@ugent.be> wrote: > By the way, why is it an issue in the first place? Is there any reason > why you don't want to inherit from ModuleElement?
I don't know what Kwankyu has in mind, but conceivably it is possible to have a parent that, depending on input parameters, either is a module or just (say) a set. Similar situation: Depending on parameters, a matrix space is a module or an algebra. In that situation, it would be nice to be able to work with a single Element class (I am not talking about element_class, which is derived from the fixed Element class and the categorial element_class that of course depends on the category). If I understand correctly, I had two or three tickets addressed to allow for more flexibility regarding actions. Such as being able to define an action on the level of a category, which would be ideal in Kwankyu's situation. If I recall correctly, it did work, but then there were merge conflicts and eventually I lost impetus. However, if I recall correctly, there are methods of a parent, P, that determine and action for arithmetic with another parent, Q. The action is a cythonised object that will call appropriate methods of the elements. In particular, Jeroen, concerning the strange rule that _lmul_ not being implemented means that it returns None: I seem to recall (but I am not 100% sure) that P._get_action_(Q) (or some other method name, I don't recall) could test what happens if P.zero()._lmul_(Q.zero()) or similar things are doing, and depending on the result would conclude that an action does not exist or does exist, for general elements of P and Q. Best regards, Simon -- 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 sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at https://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.