A151976
Minimal recursive sequence beginning with 5 similar to N with respect to property of integer to be or not to be in A079523.
Original entry on oeis.org
5, 6, 8, 10, 13, 14, 17, 18, 21, 22, 24, 26, 29, 30, 32, 34, 37, 38, 40, 42, 45, 46, 49, 50, 53, 54, 56, 58, 61
Offset: 1
a(2)=6 since 6>5 is the minimal integer such that 2 and 6 simultaneously are not in A079523.
A294991
Let S be the sequence of integer sets defined by the following rules: S(0) = {0}, S(1) = {1} and for any k > 0, S(2*k) = {2*k} U S(k) and S(2*k+1) = {2*k+1} U S(k) U S(k+1) (where X U Y denotes the union of the sets X and Y); a(n) = the number of elements of S(n).
Original entry on oeis.org
1, 1, 2, 3, 3, 4, 4, 5, 4, 6, 5, 6, 5, 7, 6, 7, 5, 8, 7, 8, 6, 8, 7, 8, 6, 9, 8, 9, 7, 9, 8, 9, 6, 10, 9, 10, 8, 10, 9, 10, 7, 10, 9, 10, 8, 10, 9, 10, 7, 11, 10, 11, 9, 11, 10, 11, 8, 11, 10, 11, 9, 11, 10, 11, 7, 12, 11, 12, 10, 12, 11, 12, 9, 12, 11, 12, 10
Offset: 0
The first terms, alongside the corresponding set S(n), are:
n a(n) S(n)
-- ---- -----
0 1 { 0 }
1 1 { 1 }
2 2 { 1, 2 }
3 3 { 1, 2, 3 }
4 3 { 1, 2, 4 }
5 4 { 1, 2, 3, 5 }
6 4 { 1, 2, 3, 6 }
7 5 { 1, 2, 3, 4, 7 }
8 4 { 1, 2, 4, 8 }
9 6 { 1, 2, 3, 4, 5, 9 }
10 5 { 1, 2, 3, 5, 10 }
11 6 { 1, 2, 3, 5, 6, 11 }
12 5 { 1, 2, 3, 6, 12 }
13 7 { 1, 2, 3, 4, 6, 7, 13 }
14 6 { 1, 2, 3, 4, 7, 14 }
15 7 { 1, 2, 3, 4, 7, 8, 15 }
16 5 { 1, 2, 4, 8, 16 }
17 8 { 1, 2, 3, 4, 5, 8, 9, 17 }
18 7 { 1, 2, 3, 4, 5, 9, 18 }
19 8 { 1, 2, 3, 4, 5, 9, 10, 19 }
20 6 { 1, 2, 3, 5, 10, 20 }
See also illustration of the first terms in Links section.
-
a(n) = my (S = Set(n), u = 1); while (u <= #S, my (v = S[#S-u+1]); if (v>1, if (v%2==0, S = setunion(S, Set(v/2)), S = setunion(S, Set([(v-1)/2, (v+1)/2])))); u++;); return (#S)
A295897
Numbers in whose binary expansion there are no 1-runs of odd length followed by a 0 to their right.
Original entry on oeis.org
0, 1, 3, 6, 7, 12, 13, 15, 24, 25, 27, 30, 31, 48, 49, 51, 54, 55, 60, 61, 63, 96, 97, 99, 102, 103, 108, 109, 111, 120, 121, 123, 126, 127, 192, 193, 195, 198, 199, 204, 205, 207, 216, 217, 219, 222, 223, 240, 241, 243, 246, 247, 252, 253, 255, 384, 385, 387, 390, 391, 396, 397, 399, 408, 409, 411, 414, 415, 432
Offset: 1
Cf.
A295896 (characteristic function).
-
[x ^ (x>>1) for x in range(0,2048) if (x & (x<<1) == 0)]
# Frédéric Nouvier, Aug 14 2020
-
def A295897(n):
tlist, s = [1,2], 0
while tlist[-1]+tlist[-2] <= n: tlist.append(tlist[-1]+tlist[-2])
for d in tlist[::-1]:
s <<= 1
if d <= n:
s += 1
n -= d
return s>>1^s # Chai Wah Wu, Apr 25 2025
-
fn main() {
for i in (0..2048)
// Filter to get A003714
.filter(|n| n & (n << 1) == 0)
// Map to produce A295897
.map(|n| n ^ (n >> 1))
{
println!("{}", i);
}
} // Frédéric Nouvier, Aug 14 2020
A380558
G.f. A(x) satisfies A(x - A(x)) = x^2/(1 - x^2).
Original entry on oeis.org
1, 2, 10, 62, 469, 4028, 37984, 385202, 4144798, 46882400, 553733875, 6795347708, 86314711993, 1131422763410, 15268625617174, 211726229534738, 3012057754693912, 43903115899714844, 654923002676505376, 9989373316478767304, 155663132037403882606, 2476418549848925209424, 40195761790035415573939
Offset: 2
G.f.: A(x) = x^2 + 2*x^3 + 10*x^4 + 62*x^5 + 469*x^6 + 4028*x^7 + 37984*x^8 + 385202*x^9 + 4144798*x^10 + 46882400*x^11 + 553733875*x^12 + ...
where A(x - A(x)) = x^2/(1 - x^2).
Let B(x) = Series_Reversion(x - A(x)), where
B(x) = x + x^2 + 4*x^3 + 25*x^4 + 190*x^5 + 1645*x^6 + 15652*x^7 + 160186*x^8 + 1739032*x^9 + 19838179*x^10 + ... + A380678(n)*x^n + ...
then B(x) = x + A(B(x)).
A051464
Number of divisors of 4*(2^n-1) + 1.
Original entry on oeis.org
2, 2, 2, 2, 4, 4, 2, 2, 4, 2, 4, 2, 4, 6, 4, 4, 16, 2, 4, 2, 4, 2, 4, 8, 12, 8, 2, 4, 8, 4, 4, 4, 4, 4, 4, 8, 8, 4, 8, 16, 8, 4, 8, 8, 6, 16, 8, 8, 8, 16, 8, 4, 32, 32, 8, 4, 8, 4, 4, 8, 16, 8, 8, 16, 48, 16, 16, 8, 4, 16, 4, 16, 16, 8, 8, 8, 16, 16, 8, 16, 32
Offset: 1
Edwin D. Evans, eevans2(AT)pacbell.net
A294523
Lexicographically earliest sequence of positive terms, such that, for any n > 0, the binary expansion of n, say of size k+1, is (1, a(n) mod 2, a^2(n) mod 2, ..., a^k(n) mod 2) (where a^i denotes the i-th iterate of the sequence).
Original entry on oeis.org
1, 2, 1, 2, 6, 5, 1, 2, 10, 6, 14, 9, 5, 13, 1, 2, 18, 10, 22, 12, 6, 14, 30, 17, 9, 5, 11, 25, 13, 29, 1, 2, 34, 18, 38, 20, 10, 22, 46, 24, 12, 6, 54, 28, 14, 30, 62, 33, 17, 9, 19, 41, 5, 11, 23, 49, 25, 13, 27, 57, 29, 61, 1, 2, 66, 34, 70, 36, 18, 38, 78
Offset: 1
For n=11:
- the binary representation of 11 is (1,0,1,1),
- a(11) = 14 has parity 0,
- a(14) = 13 has parity 1,
- a(13) = 5 has parity 1,
- we find the binary digits of 11 beyond the initial 1, in order: 0, 1, 1.
See also representations of first terms in Links section.
Cf.
A000079,
A000225,
A000975,
A004754,
A004760,
A052997,
A054429,
A080541,
A081253,
A081254,
A266248,
A266613,
A266721,
A267045.
A375378
Value of the power tower formed by the numbers in the n-th composition (in standard order).
Original entry on oeis.org
1, 1, 2, 1, 3, 2, 1, 1, 4, 3, 4, 2, 1, 1, 1, 1, 5, 4, 9, 3, 8, 4, 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, 6, 5, 16, 4, 27, 9, 3, 3, 16, 8, 16, 4, 2, 2, 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 7, 6, 25, 5, 64, 16, 4, 4, 81, 27, 81, 9, 3, 3, 3, 3, 32, 16
Offset: 0
For n = 38, the 38th composition is (3,1,2), so a(38) = 3^1^2 = 3^1 = 3.
A383593
In the binary expansion of n, change the most significant 0 bit to 1, if there is any 0 bit.
Original entry on oeis.org
1, 1, 3, 3, 6, 7, 7, 7, 12, 13, 14, 15, 14, 15, 15, 15, 24, 25, 26, 27, 28, 29, 30, 31, 28, 29, 30, 31, 30, 31, 31, 31, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 56, 57, 58, 59, 60, 61, 62, 63, 60, 61, 62, 63, 62, 63, 63, 63, 96, 97, 98, 99, 100
Offset: 0
a(25) = 29 since 25 = 11001_2 becomes 11101_2 = 29.
-
def a(n): return int(bin(n)[2:].replace('0', '1', 1), 2)
print([a(n) for n in range(70)]) # Michael S. Branicky, Jun 11 2025
-
def A383593(n): return (n if (t:=bin(n)[2:].find('0'))==-1 else n+(1<Chai Wah Wu, Jun 17 2025
A151994
For k=A079523(n),n>=2, let {S_k} be the minimal recursive sequence beginning with k similar to N with respect to property of integer to be or not to be in A079523. Then a(n) is the point of confluence of {S_k} with {S_5}.
Original entry on oeis.org
5, 13, 13, 29, 29, 61, 61, 61, 61
Offset: 2
Note that, {S_5} is {5,6,8,10,13,...}(see A162736) and {S_7} is {7,8,10,11,13,...}, then a(3)=13.
Comments