login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A340730 a(0) = 0, a(1) = 1; for n > 1, a(n) = a(n-1) - min(a(n-1),n) if nonnegative and not already in the sequence, otherwise a(n) = a(n-1) + min(a(n-1),n). 1

%I #9 Jan 19 2021 22:03:12

%S 0,1,2,4,8,3,6,12,20,11,21,10,20,7,14,28,44,27,9,18,36,15,30,53,29,54,

%T 80,107,79,50,80,49,17,34,68,33,66,103,65,26,52,93,51,94,138,183,137,

%U 90,42,84,134,83,31,62,116,61,5,10,20,40,80,19,38,76,140,75,141,74,142,73,143,72,144

%N a(0) = 0, a(1) = 1; for n > 1, a(n) = a(n-1) - min(a(n-1),n) if nonnegative and not already in the sequence, otherwise a(n) = a(n-1) + min(a(n-1),n).

%C This sequence uses the same rules as Recamán's sequence A005132 except that the step size for each term n is set to the minimum of n and a(n-1).

%C The terms are slightly concentrated along the linear relationships a(n) = k*n, where k is an integer >= 1. Other values are distributed between these lines. See the linked image.

%C The smallest value not to have appeared after 5 million terms is 8697. It is unknown if all terms eventually appear.

%H Scott R. Shannon, <a href="/A340730/a340730.png">Image of the first 5 million terms</a>.

%e a(3) = 4 as min(3,a(2)) = min(3,2) = 2, and as 0 has already appeared a(3) = a(2) + 2 = 2 + 2 = 4.

%e a(5) = 3 as min(5,a(4)) = min(5,8) = 5, and as 3 has not already appeared a(5) = a(4) - 5 = 8 - 5 = 3.

%Y Cf. A005132, A336760, A336761.

%K nonn

%O 0,3

%A _Scott R. Shannon_, Jan 17 2021

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 19 19:02 EDT 2024. Contains 371798 sequences. (Running on oeis4.)