A355080 Start with the positive integers. Term by term from left to right insert a copy of the current term x m steps further, where m is the number of times x has appeared.
1, 1, 2, 2, 1, 2, 3, 3, 1, 3, 2, 4, 4, 3, 4, 1, 2, 4, 3, 5, 5, 1, 5, 4, 2, 5, 3, 6, 6, 4, 6, 5, 1, 6, 2, 3, 5, 6, 4, 7, 7, 1, 7, 2, 6, 7, 5, 3, 4, 7, 8, 8, 6, 8, 1, 5, 8, 7, 2, 3, 8, 6, 4, 7, 9, 9, 8, 9, 5, 1, 9, 2, 6, 8, 9, 7, 3, 4, 5, 9, 10, 10, 8, 10, 1, 7, 10, 6
Offset: 1
Examples
Step-by-step development of the sequence is as follows; the asterisk marks the actual term that will be processed: * 1 was previously seen 0 times -> insert directly after. 1,2,3,4,5,6,7,8,9,10 1,1,2,3,4,5,6,7,8,9,10 * 1 was previously seen once -> insert one later. 1,1,2,3,4,5,6,7,8,9,10 1,1,2,1,3,4,5,6,7,8,9,10 * 2 was previously seen 0 times -> insert directly after. 1,1,2,1,3,4,5,6,7,8,9,10 1,1,2,2,1,3,4,5,6,7,8,9,10 * 2 was previously seen once -> insert one later. 1,1,2,2,1,3,4,5,6,7,8,9,10 1,1,2,2,1,2,3,4,5,6,7,8,9,10 * 1 was previously seen twice -> insert two later. 1,1,2,2,1,2,3,4,5,6,7,8,9,10 1,1,2,2,1,2,3,1,4,5,6,7,8,9,10 . This sequence written as an irregular triangle: * * 1, 1 * 2, 2, 1, 2 3, 3, 1, 3, 2 * 4, 4, 3, 4, 1, 2, 4, 3 5, 5, 1, 5, 4, 2, 5, 3 * 6, 6, 4, 6, 5, 1, 6, 2, 3, 5, 6, 4 Each column below an asterisk shows a linear progression.
Links
- Thomas Scheuerle, Table of n, a(n) for n = 1..10000
- Thomas Scheuerle, Scatter plot of the first 10000 values
- Thomas Scheuerle, y = k - (1/C)*(x-0.283)^2, where k is the least k such that a(k) = x. For C we chose sqrt(2/u) with u = 1.45... (A070769).
- Thomas Scheuerle, y = k - (1/C)*(x-1.275)^2, where k is such that a(k) = 1 for the x-th appearance. For C we chose sqrt(2/u) with u = 1.45... (A070769).
Programs
-
MATLAB
function a = A355080( max_n ) a = 1:max_n; for n = 1:max_n j = length(find(a(1:n) == a(n))); a = [a(1:n+j-1) a(n) a(n+j:end)]; end a = a(1:max_n); end
Comments