Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Search: a261195 -id:a261195
     Sort: relevance | references | number | modified | created      Format: long | short | data
a(n) = Sum_{k >= 0} b_k * 2^A061579(k) for any number n with binary expansion Sum_{k >= 0} b_k * 2^k.
+10
3
0, 1, 4, 5, 2, 3, 6, 7, 32, 33, 36, 37, 34, 35, 38, 39, 16, 17, 20, 21, 18, 19, 22, 23, 48, 49, 52, 53, 50, 51, 54, 55, 8, 9, 12, 13, 10, 11, 14, 15, 40, 41, 44, 45, 42, 43, 46, 47, 24, 25, 28, 29, 26, 27, 30, 31, 56, 57, 60, 61, 58, 59, 62, 63, 512, 513, 516
OFFSET
0,3
COMMENTS
This sequence is a self-inverse permutation of the nonnegative integers.
Fixed points correspond to A261195.
FORMULA
a(n) = n iff n belongs to A261195.
A000120(a(n)) = A000120(n).
a(n) < 2^A000217(k) for any n < 2^A000217(k).
EXAMPLE
For n = 42:
- 42 = 2^1 + 2^3 + 2^5,
- A061579(1) = 2,
- A061579(3) = 5,
- A061579(5) = 3,
- so a(42) = 2^2 + 2^5 + 2^3 = 44.
PROG
(PARI) a(n) = { my (v=0, e, t=0, w=1); while (n, n-=2^e=valuation(n, 2); while (e>t+w-1, t+=w; w++); v+=2^(2*t+w-1-e)); v }
CROSSREFS
Cf. A000120, A000217, A061579, A261195 (fixed points).
KEYWORD
nonn,base
AUTHOR
Rémy Sigrist, May 22 2021
STATUS
approved
For any number n with binary expansion Sum_{k = 1..m} 2^e_k (where 0 <= e_1 < ... < e_m), a(n) = Product_{k = 1..m} prime(1+A002262(e_k))^2^A025581(e_k) (where prime(k) denotes the k-th prime number).
+10
3
1, 2, 4, 8, 3, 6, 12, 24, 16, 32, 64, 128, 48, 96, 192, 384, 9, 18, 36, 72, 27, 54, 108, 216, 144, 288, 576, 1152, 432, 864, 1728, 3456, 5, 10, 20, 40, 15, 30, 60, 120, 80, 160, 320, 640, 240, 480, 960, 1920, 45, 90, 180, 360, 135, 270, 540, 1080, 720, 1440
OFFSET
0,2
COMMENTS
The ones in the binary expansion of n encode the Fermi-Dirac factors of a(n).
The following table gives the rank of the bit corresponding to the Fermi-Dirac factor p^2^k:
...
7| 9
5| 5 8
3| 2 4 7
2| 0 1 3 6
---+--------
p/k| 0 1 2 3 ...
This sequence is a bijection from the nonnegative integers to the positive integers with inverse A344536.
This sequence establishes a bijection from A261195 to A225547.
This sequence and A344535 each map between two useful choices for encoding sets of elements drawn from a 2-dimensional array. To give a very specific example, each mapping is an isomorphism between two alternative integer representations of the polynomial ring GF2[x,y]. The relevant set is {x^i*y^j : i, j >= 0}. The mappings between the two representations of the ring's addition operation are from XOR (A003987) to A059897(.,.) and for the multiplication operation, they are from A329331(.,.) to A329329(.,.). - Peter Munn, May 31 2021
FORMULA
a(n) = A344535(A344531(n)).
a(n) = A344535(n) iff n belongs to A261195.
A064547(a(n)) = A000120(n).
a(A036442(n)) = prime(n).
a(A006125(n+1)) = 2^2^n for any n >= 0.
a(m + n) = a(m) * a(n) when m AND n = 0 (where AND denotes the bitwise AND operator).
From Peter Munn, Jun 06 2021: (Start)
a(n) = A225546(A344535(n)).
a(n XOR k) = A059897(a(n), a(k)), where XOR denotes bitwise exclusive-or, A003987.
a(A329331(n, k)) = A329329(a(n), a(k)).
(End)
EXAMPLE
For n = 42:
- 42 = 2^5 + 2^3 + 2^1,
- so we have the following Fermi-Dirac factors p^2^k:
5| X
3|
2| X X
---+------
p/k| 0 1 2
- a(42) = 2^2^1 * 2^2^2 * 5^2^0 = 320.
PROG
(PARI) A002262(n)=n-binomial(round(sqrt(2+2*n)), 2)
A025581(n)=binomial(1+floor(1/2+sqrt(2+2*n)), 2)-(n+1)
a(n) = { my (v=1, e); while (n, n-=2^e=valuation(n, 2); v* = prime(1 + A002262(e))^2^A025581(e)); v }
CROSSREFS
Comparable mappings that also use Fermi-Dirac factors: A052330, A059900.
Maps binary operations A003987 to A059897, A329331 to A329329.
KEYWORD
nonn,base
AUTHOR
Rémy Sigrist, May 22 2021
STATUS
approved
For any number n with binary expansion Sum_{k = 1..m} 2^e_k (where 0 <= e_1 < ... < e_m), a(n) = Product_{k = 1..m} prime(1+A025581(e_k))^2^A002262(e_k) (where prime(k) denotes the k-th prime number).
+10
3
1, 2, 3, 6, 4, 8, 12, 24, 5, 10, 15, 30, 20, 40, 60, 120, 9, 18, 27, 54, 36, 72, 108, 216, 45, 90, 135, 270, 180, 360, 540, 1080, 16, 32, 48, 96, 64, 128, 192, 384, 80, 160, 240, 480, 320, 640, 960, 1920, 144, 288, 432, 864, 576, 1152, 1728, 3456, 720, 1440
OFFSET
0,2
COMMENTS
The ones in the binary expansion of n encode the Fermi-Dirac factors of a(n).
The following table gives the rank of the bit corresponding to the Fermi-Dirac factor p^2^k:
...
7| 6
5| 3 7
3| 1 4 8
2| 0 2 5 9
---+--------
p/k| 0 1 2 3 ...
This sequence is a bijection from the nonnegative integers to the positive integers with inverse A344537.
This sequence establishes a bijection from A261195 to A225547.
FORMULA
a(n) = A344534(A344531(n)).
a(n) = A344534(n) iff n belongs to A261195.
A064547(a(n)) = A000120(n).
a(A006125(n)) = prime(n) for any n > 0.
a(A036442(n+1)) = 2^2^n for any n >= 0.
a(m + n) = a(m) * a(n) when m AND n = 0 (where AND denotes the bitwise AND operator).
EXAMPLE
For n = 42:
- 42 = 2^5 + 2^3 + 2^1,
- so we have the following Fermi-Dirac factors p^2^k:
5| X
3| X
2| X
---+------
p/k| 0 1 2
- a(42) = 3^2^0 * 5^2^0 * 2^2^2 = 240.
PROG
(PARI) A002262(n)=n-binomial(round(sqrt(2+2*n)), 2)
A025581(n)=binomial(1+floor(1/2+sqrt(2+2*n)), 2)-(n+1)
a(n) = { my (v=1, e); while (n, n-=2^e=valuation(n, 2); v *= prime(1 + A025581(e))^2^A002262(e)); v }
KEYWORD
nonn,base
AUTHOR
Rémy Sigrist, May 22 2021
STATUS
approved
Encoded square binary matrices representing an idempotent relation.
+10
2
0, 1, 3, 5, 9, 11, 16, 17, 18, 19, 20, 21, 23, 25, 27, 33, 37, 49, 53, 65, 67, 73, 75, 81, 83, 89, 91, 141, 144, 145, 148, 149, 153, 154, 155, 157, 159, 181, 209, 217, 219, 272, 273, 274, 275, 283, 291, 305, 307, 308, 309, 311, 337, 339, 347, 513, 517, 529
OFFSET
0,3
COMMENTS
We encode an n X n binary matrix reading it antidiagonal by antidiagonal, starting from the least significant bit. A given entry in the sequence therefore represents the infinite family of n X n matrices that can be obtained by adding zero antidiagonals. All of these matrices represent idempotent relations. This encoding makes it possible to obtain a sequence rather than a table.
LINKS
EXAMPLE
For example, 148 = 0b10010100 encodes all square matrices with the first four antidiagonals equal to ((0), (0, 1), (0, 1, 0), (0, 1, 0, 0)). For example the 3 X 3 matrix:
0 1 0
0 1 0
0 1 0
and the 4 X 4 matrix:
0 1 0 0
0 1 0 0
0 1 0 0
0 0 0 0
and all larger square matrices constructed in the same way. Since 148 is in the sequence, all these matrices are idempotent.
PROG
(Python)
def getBitIndex(i, j):
..return (i+j)*(i+j+1)/2 + j
def getBit(mat, i, j):
..return (mat >> getBitIndex(i, j)) & 1
def setBit(mat, i, j):
..return mat | (1 << getBitIndex(i, j))
def noBitLeft(mat, i, j):
..return mat >> getBitIndex(i, j) == 0
def squarematrix(mat):
..result = 0;
..i = 0
..while True:
....if noBitLeft(mat, i, 0):
......return result
....j = 0;
....while True:
......if noBitLeft(mat, 0, j):
........break
......k = 0
......while True:
........if noBitLeft(mat, i, k):
..........break
........if getBit(mat, i, k) & getBit(mat, k, j):
..........result = setBit(result, i, j)
..........break
........k += 1
......j += 1
....i += 1
..return result
index = 0
mat = 0
while True:
..if mat == squarematrix(mat):
....print index, mat
....index += 1
..mat += 1
CROSSREFS
KEYWORD
nonn
AUTHOR
Philippe Beaudoin, Aug 11 2015
STATUS
approved
Inverse permutation to A344534.
+10
2
0, 1, 4, 2, 32, 5, 512, 3, 16, 33, 16384, 6, 1048576, 513, 36, 8, 134217728, 17, 34359738368, 34, 516, 16385, 17592186044416, 7, 256, 1048577, 20, 514, 18014398509481984, 37, 36893488147419103232, 9, 16388, 134217729, 544, 18, 151115727451828646838272
OFFSET
1,3
COMMENTS
This sequence is additive.
This sequence establishes a bijection from A225547 to A261195.
FORMULA
a(prime(n)) = A036442(n).
a(2^2^n) = A006125(n+1) for any n >= 0.
A000120(a(n)) = A064547(n).
a(A225546(n)) = A344537(n).
a(n) = A344537(n) iff n belongs to A225547.
EXAMPLE
A344534(42) = 320, so a(320) = 42.
PROG
(PARI) a(n) = { my (f=factor(n), v=0); for (k=1, #f~, my (x=primepi(f[k, 1])-1, yy=f[k, 2], y); while (yy, yy-=2^y=valuation(yy, 2); v+=2^(x + (x+y)*
(x+y+1)/2))); v }
KEYWORD
nonn,base
AUTHOR
Rémy Sigrist, May 23 2021
STATUS
approved
Inverse permutation to A344535.
+10
2
0, 1, 2, 4, 8, 3, 64, 5, 16, 9, 1024, 6, 32768, 65, 10, 32, 2097152, 17, 268435456, 12, 66, 1025, 68719476736, 7, 128, 32769, 18, 68, 35184372088832, 11, 36028797018963968, 33, 1026, 2097153, 72, 20, 73786976294838206464, 268435457, 32770, 13
OFFSET
1,3
COMMENTS
This sequence is additive.
This sequence establishes a bijection from A225547 to A261195.
FORMULA
a(prime(n)) = A006125(n+1) for any n >= 0.
a(2^2^n) = A036442(n).
A000120(a(n)) = A064547(n).
a(A225546(n)) = A344536(n).
a(n) = A344536(n) iff n belongs to A225547.
EXAMPLE
A344535(42) = 240, so a(240) = 42.
PROG
(PARI) a(n) = { my (f=factor(n), v=0); for (k=1, #f~, my (x=primepi(f[k, 1])-1, yy=f[k, 2], y); while (yy, yy-=2^y=valuation(yy, 2); v+=2^(y + (x+
(x+y+1)/2))); v }
KEYWORD
nonn,base
AUTHOR
Rémy Sigrist, May 23 2021
STATUS
approved
Encoded symmetrical antidiagonal square binary matrices with either 1 or 2 ones.
+10
1
1, 6, 16, 40, 384, 576, 4096, 10240, 17408, 393216, 589824, 1081344, 16777216, 41943040, 71303168, 136314880, 6442450944, 9663676416, 17716740096, 34628173824, 1099511627776
OFFSET
0,2
COMMENTS
We encode square matrices that have zeros everywhere except the antidiagonal where the antidiagonal is symmetric with either 1 or 2 ones in it. We do this by reading off digits antidiagonally to get a binary number and then convert the number to a base 10 number.
FORMULA
a(n) = A261195(2^n).
a(n) = 2^(A000217(floor(sqrt(4*n + 1)) - 1)) * (((A262769(floor(n/2)) * 2^((floor(sqrt(4*n + 1)) - 2*A002260(+1))/2)) * (1+(-1)^(floor(sqrt(4*n + 1))))/2) + ((A262777(floor(n/2)) * 2^((floor(sqrt(4*n + 1)) - A158405(+1))/2)) * (1-(-1)^(floor(sqrt(4*n + 1))))/2)).
EXAMPLE
The 3 X 3 matrix
0 0 0
0 1 0
0 0 0
gives 000010000. Writing this as a base 10 number gives a(2)=16.
The 4 X 4 matrix
0 0 0 0
0 0 1 0
0 1 0 0
0 0 0 0
gives 0000000110000000. Writing this as a base 10 number gives a(4)=384.
The 5 X 5 matrix
0 0 0 0 0
0 0 0 1 0
0 0 0 0 0
0 1 0 0 0
0 0 0 0 0
gives 0000000000010100000000000. Writing this as a base 10 number gives a(7)=10240.
KEYWORD
nonn
AUTHOR
Eric Werley, Sep 24 2015
STATUS
approved

Search completed in 0.009 seconds