Svoboda | Graniru | BBC Russia | Golosameriki | Facebook
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!)
A337909 Distinct terms of A080079 in the order in which they appear. 1
1, 2, 4, 3, 8, 7, 6, 5, 16, 15, 14, 13, 12, 11, 10, 9, 32, 31, 30, 29, 28, 27, 26, 25, 24, 23, 22, 21, 20, 19, 18, 17, 64, 63, 62, 61, 60, 59, 58, 57, 56, 55, 54, 53, 52, 51, 50, 49, 48, 47, 46, 45, 44, 43, 42, 41, 40, 39, 38, 37, 36, 35, 34, 33, 128 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
This sequence is a permutation of the positive integers.
The cardinality of {2^k, ..., (2^k - 0^k)/2 + 1} is A011782(k).
LINKS
FORMULA
a(1) = 1 and a(n) = A080079(n - 1 + 2^floor(log_2(n - 1))) if n > 1.
a(n) = A080079(A004761(n+1)).
From Kevin Ryde, Sep 29 2020: (Start)
a(n) = 3*A053644(n-1) - (n-1), if n > 1.
a(n) = A054429(n-1) + 1, if n > 1.
a(n) = A280510(n) - n + 1, if n > 1. (End)
EXAMPLE
(2^0, ..., (2^0 - 0^0)/2 + 1) = (1),
(2^1, ..., (2^1 - 0^1)/2 + 1) = (2),
(2^2, ..., (2^2 - 0^2)/2 + 1) = (4, 3),
(2^3, ..., (2^3 - 0^3)/2 + 1) = (8, 7, 6, 5)...
MATHEMATICA
{1}~Join~Array[3*2^(IntegerLength[# - 1, 2] - 1) - # + 1 &, 64, 2] (* Michael De Vlieger, Oct 05 2020 *)
PROG
(PARI) a(n) = if(n--, 3<<logint(n, 2) - n, 1); \\ Kevin Ryde, Sep 29 2020
CROSSREFS
Sequence in context: A255833 A166133 A237739 * A358523 A365930 A111699
KEYWORD
nonn
AUTHOR
STATUS
approved

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 August 6 02:16 EDT 2024. Contains 374957 sequences. (Running on oeis4.)