login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A326307
a(n) is the index of n in the ordered list of the numbers with the same digits as n.
2
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2
OFFSET
0,22
COMMENTS
Ordinal transform of A328447.
LINKS
David A. Corneth, PARI program
FORMULA
a(A179239(n)) = 1.
a(10+n) = A007953(9*n)/9 (A007953 = sum of digits) for 0 < n < 91, but a(101) = 1 while A007953(9*91)/9 = 2. - M. F. Hasler, May 19 2021
EXAMPLE
a(321) = 6 as 321 is the sixth number made of the digits [1, 2, 3]. The five smaller numbers having these digits are 123, 132, 213, 231, 312.
PROG
(PARI) see Corneth link
(PARI) { o = vector(100); for (n=0, 87, print1 (o[1+fromdigits(vecsort(digits(n, base=10), , 4), base)]++ ", ")) } \\ Rémy Sigrist, Oct 17 2019
(PARI) A326307(n, D=Vecsmall(digits(n)), c=1)={forperm(vecsort(D), d, d==D&&break; d[1]&&c++); c} \\ M. F. Hasler, May 19 2021
CROSSREFS
KEYWORD
nonn,base,easy,look
AUTHOR
David A. Corneth, Oct 17 2019
EXTENSIONS
Edited by N. J. A. Sloane, Oct 24 2019
STATUS
approved