Opened 11 years ago

Last modified 8 years ago

#12228 new enhancement

Eventually Periodic word class

Reported by: Štěpán Starosta Owned by: Štěpán Starosta
Priority: minor Milestone: sage-6.4
Component: combinatorics Keywords:
Cc: Vincent Delecroix Merged in:
Authors: Reviewers:
Report Upstream: N/A Work issues:
Branch: Commit:
Dependencies: Stopgaps:

Status badges

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 (6)

comment:1 Changed 11 years ago by Štěpán Starosta

Owner: changed from Sage Combinat CC user to Štěpán Starosta

comment:2 Changed 11 years ago by Štěpán Starosta

Type: PLEASE CHANGEenhancement

comment:3 Changed 9 years ago by Jeroen Demeyer

Milestone: sage-5.11sage-5.12

comment:4 Changed 9 years ago by For batch modifications

Milestone: sage-6.1sage-6.2

comment:5 Changed 8 years ago by For batch modifications

Milestone: sage-6.2sage-6.3

comment:6 Changed 8 years ago by For batch modifications

Milestone: sage-6.3sage-6.4
Note: See TracTickets for help on using tickets.