Ticket #8954 (closed enhancement: fixed)

Opened 3 years ago

Last modified 3 years ago

Implementation of the affine nilTemperley Lieb algebra of type A

Reported by: aschilling Owned by: AlexGhitza
Priority: major Milestone: sage-4.4.4
Component: algebra Keywords:
Cc: sage-combinat Work issues:
Report Upstream: N/A Reviewers: Jason Bandlow
Authors: Anne Schilling Merged in: sage-4.4.4.alpha0
Dependencies: Stopgaps:

Description


Attachments

trac_8954-nilTemperley-as.patch Download (9.8 KB) - added by aschilling 3 years ago.

Change History

comment:1 Changed 3 years ago by aschilling

  • Status changed from new to needs_review

comment:2 follow-up: ↓ 3 Changed 3 years ago by jbandlow

  • Status changed from needs_review to needs_work

Hi Anne, here are some comments. I think all of these should be easy to implement, and I'm happy to do them myself, if you like. But I'd like to know what you think first.

  1. It looks like your implementation assumes ZZ as a base ring. Any reason not to allow any ring?
  2. I would prefer the elements print as a[0] a[1] instead of a0 a1 so that copy-paste can work. Do you have a preference one way or the other?
  3. In the documentation for the class, you should mention that the relations should be understood mod n.
  4. In the _element_constructor, I would expect the presence of a braid relation trigger to return 0. Is there a reason that you raise an error instead?

This will be useful to have in sage... thanks!

comment:3 in reply to: ↑ 2 Changed 3 years ago by aschilling

  • Status changed from needs_work to needs_review
  • Reviewers set to Jason Bandlow

Hi Jason,

Thank you for your comments! I have uploaded a revised patch addressing the issues you raised:

  1. It looks like your implementation assumes ZZ as a base ring. Any reason not to allow any ring?

Done.

  1. I would prefer the elements print as a[0] a[1] instead of a0 a1 so that copy-paste can work. Do you have a preference one way or the other?

There is now an option in

def _repr_term(self, t, display = "short"):

which allows to display the output in the long or short notation.

  1. In the documentation for the class, you should mention that the relations should be understood mod n.

Done.

  1. In the _element_constructor, I would expect the presence of a braid relation trigger to return 0. Is there a reason that you raise an error instead?

Done now. As we discussed by e-mail in private, it might make more sense to eventually construct this algebra as a quotient algebra. This would depend on the 'functorial constructions' patch of Nicolas and Florent. I left a note about this in the code.

One slight warning: I now inserted a line

assert(self(w) != self.zero())

in product_on_basis, which might slow down calculations, but is safer.

Cheers,

Anne

Changed 3 years ago by aschilling

comment:4 Changed 3 years ago by jbandlow

  • Status changed from needs_review to positive_review
  • Milestone set to sage-4.4.3

Anne,

Thanks for making the changes I suggested. I'm happy with the code now, and I've run the tests on sage-4.4.2 and they all pass. Positive review!

comment:5 Changed 3 years ago by mhansen

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