cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A378876 a(1)=1; thereafter a(n) is the smallest k for which the subsequence a(n-k..n-1) has a distinct multiset from that of any other subsequence of the sequence thus far.

Original entry on oeis.org

1, 1, 2, 1, 4, 1, 3, 1, 3, 3, 2, 2, 2, 3, 6, 1, 2, 3, 3, 6, 3, 4, 2, 2, 3, 5, 1, 2, 3, 5, 5, 2, 2, 3, 6, 5, 2, 3, 5, 5, 5, 3, 5, 5, 6, 3, 5, 9, 1, 2, 3, 4, 4, 2, 3, 5, 4, 2, 3, 5, 5, 6, 6, 2, 2, 3, 5, 8, 1, 2, 3, 4, 5, 5, 3, 5, 5, 6, 7, 1, 2, 3, 4, 5, 6, 3, 5, 5
Offset: 1

Views

Author

Neal Gersh Tolunsky, Jan 17 2025

Keywords

Comments

In other words, a(n) is the length of the shortest subsequence ending at a(n-1) which has a unique multiset among all multisets of subsequences of the sequence thus far. Alternatively, this is (the length of the longest subsequence ending at a(n-1) whose multiset has occurred before as that of another subsequence) plus 1.

Examples

			a(15) = 6 because the length-6 subsequence a(9..14) =  3,3,2,2,2,3 has the shortest unique multiset, which does not occur elsewhere as the multiset of any other subsequence in the sequence thus far. No shorter subsequence ending in a(14) with a unique ordinal transform exists in the sequence thus far. For example, a(15) cannot be 5 because the length-5 subsequence a(10..14) = 3,2,2,2,3 has the same multiset as that of the subsequence a(9..13) = 3,3,2,2,2.
		

Crossrefs