Ticket #12228 (new enhancement)
Eventually Periodic word class
| Reported by: | sstarosta | Owned by: | sstarosta |
|---|---|---|---|
| Priority: | minor | Milestone: | sage-5.10 |
| Component: | combinatorics | Keywords: | |
| Cc: | vdelecroix | Work issues: | |
| Report Upstream: | N/A | Reviewers: | |
| Authors: | Merged in: | ||
| Dependencies: | Stopgaps: |
Description
Implement a class for eventually periodic words.
The motivation is the following behavior.
sage: W = Words([0,1]) sage: w1 = W(lambda x: 1 if x%2 else 0) sage: w1[0] == w1[2] True sage: w1[0] is w1[2] False
While using periodic word class we can have
sage: w2 = W.periodic_word(period=[0,1]) sage: w2[0] == w2[2] True sage: w2[0] is w2[2] True
It will be used in substitutive language #12227
Change History
Note: See
TracTickets for help on using
tickets.
