MareoRaft / k_combinat_for_sage

k-Schur combinatorics for SageMath
4 stars 1 forks source link

Base ring does not carry through correctly on Catalan evaluation #9

Closed ghseeli closed 6 years ago

ghseeli commented 6 years ago

Consider the following code

sage: K = FractionField(QQ['t'])
sage: CF = CatalanFunctions()
sage: elm = CF.init_from_indexed_root_ideal([],[3,3,2,1],base_ring=K)
sage: elm.eval()

This returns a TypeError that says TypeError: unsupported operand parent(s) for *: 'Symmetric Functions over Univariate Polynomial Ring in t over Rational Field in the Schur basis' and 'Symmetric Functions over Fraction Field of Univariate Polynomial Ring in t over Rational Field in the Hall-Littlewood Qp basis'

The problem seems to be that, elsewhere in the code, there is an implicit assumption that the user's base ring is QQ[t] and Sage is highly inflexible at casting the ring symmetric functions over QQ[t] into the ring of symmetric functions over the field QQ(t).

MareoRaft commented 6 years ago

passing in base_ring when creating the Hall littlewood vertex operator fixed this (return H(gamma, base_ring=base_ring)(HLQp.one()) in compositional_hall_littlewood_Qp function)

MareoRaft commented 6 years ago

George says we need to pass in t in the Hall littlewood vertex operator call function (https://github.com/MareoRaft/k_combinat_for_sage/commit/f4e8712941e1645bd364a67861024ddf3e0efb4c). I'm assuming you want an optional parameter input t in the call, and then if they input nothing, default to...

  1. base_ring.gen()

or maybe

  1. not passing in anything at all

?

MareoRaft commented 6 years ago

And I guess that means wherever we actually use that call function in the code, we should be passing in the appropriate t.

ghseeli commented 6 years ago

I am somewhat confused by this. I added a commit that fixes the issue after I made my comment, I believe.

MareoRaft commented 6 years ago

Okay, I have confirmed that you fixed this already. :)