On Thu, Nov 26, 2020 at 08:20:19AM +0000, Mathew M. Noel via Python-ideas wrote:
Circular indexing will only extend the range of allowable indices to the set of all integers !!!
Is that supposed to be a feature, or a terrible threat? [...]
Deeper mathematical reason behind circular indexing is that it makes the use of negative indices logically consistent
Negative indices are already logically consistent. Python's model for sequences is a *linear* sequence, not a circular sequence, and negative indices counting from the end is no less logical than positive indices counting from the start. Please stop wasting our time by claiming "logical consistency" as a unique benefit of your proposal. We already have logical consistency in a linear model, changing to a circular model doesn't add anything we don't already have.
and simplifies implementation of the widely used convolution operation in signal processing.
For the benefit of the 99.9% of Python programmers who have no idea what this "convolution operation" is, can you give an example? It's okay if it is a simplified example, even pseudo-code, so long as it is realistic. Please remember that the Python ecosystem supports programmers who are not just working in signal processing or machine learning, but system administrators, educators, students, hobbyists, web developers, business programming, natural language processing, graphics processing, and a host of other fields. For most of these fields, a circular model for sequences will be a step backwards, not forward. -- Steve