cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A235164 Numbers whose digits, when the number is written in base n+1, are a permutation of 1...n, and such that for all k in {1,...,n} the first k digits (still in base n+1) form a number divisible by k.

This page as a plain text file.
%I A235164 #13 May 22 2025 10:21:36
%S A235164 1,27,57,2285,7465,874615,1391089,1538257,381654729,559922224824157
%N A235164 Numbers whose digits, when the number is written in base n+1, are a permutation of 1...n, and such that for all k in {1,...,n} the first k digits (still in base n+1) form a number divisible by k.
%C A235164 See sequence A163574 (which lists, for each n, the smallest term with n digits) for further discussion, in particular the proof that n must be odd, and that there is no further term with less than 13 digits.  See sequence A235133 for the version where the terms (up to 9 digits) are written down in base 10.
%e A235164 The terms with 5 digits in base 6 are 2285 = 14325[6] and 7465 = 54321[6], since these numbers are divisible by 5, and 14[6] = 10, 143[6] = 63, 1432[6] = 380 are divisible by 2, 3 and 4, respectively, and the same is the case for 54[6] = 34, 543[6] = 207 and 5432[6] = 1244.
%o A235164 (PARI) for(n=1,9,p=vector(n,i,(n+1)^(i-1));for(k=0,n!-1,d=numtoperm(n,k);for(j=2,n,sum(i=1,j,d[i]*p[j-i+1])%j &&next(2)); print1(d*vector(n,i,(n+1)^(n-i))~",")))
%o A235164 (Python)
%o A235164 def vgen(n,b):
%o A235164     if n == 1:
%o A235164         t = list(range(1,b))
%o A235164         for i in range(1,b):
%o A235164             u = list(t)
%o A235164             u.remove(i)
%o A235164             yield i, u
%o A235164     else:
%o A235164         for d, v in vgen(n-1,b):
%o A235164             for g in v:
%o A235164                 k = d*b+g
%o A235164                 if not k % n:
%o A235164                     u = list(v)
%o A235164                     u.remove(g)
%o A235164                     yield k, u
%o A235164 A235164_list = [a for n in range(2,15,2) for a, b in vgen(n-1,n)] # _Chai Wah Wu_, Jun 07 2015
%K A235164 nonn,base,more
%O A235164 1,2
%A A235164 _M. F. Hasler_, Jan 04 2014
%E A235164 a(10) from _Chai Wah Wu_, Jun 07 2015