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.

Showing 1-3 of 3 results.

A191819 (A178477(n)-1)/9.

Original entry on oeis.org

137174, 137175, 137184, 137186, 137195, 137196, 137274, 137275, 137294, 137297, 137305, 137307, 137384, 137386, 137394, 137397, 137416, 137417, 137495, 137496, 137505, 137507, 137516, 137517, 138174, 138175, 138184, 138186, 138195, 138196, 138374, 138375, 138404
Offset: 1

Views

Author

Nathaniel Johnston, Jun 24 2011

Keywords

Comments

The sequence is motivated by the fact that numbers whose decimal expansion is a permutation of 1234567 are all of the form 9k+1.

Crossrefs

A209280 First difference of A050289 = numbers whose digits are a permutation of (1,...,9).

Original entry on oeis.org

9, 81, 18, 81, 9, 702, 9, 171, 27, 72, 18, 693, 18, 72, 27, 171, 9, 702, 9, 81, 18, 81, 9, 5913, 9, 81, 18, 81, 9, 1602, 9, 261, 36, 63, 27, 594, 18, 162, 36, 162, 18, 603, 9, 171, 27, 72, 18, 5814, 9, 171, 27, 72, 18, 603, 9, 261, 36, 63, 27, 1584, 27, 63, 36, 261, 9
Offset: 1

Views

Author

M. F. Hasler, Jan 12 2013

Keywords

Comments

This sequence is the natural extension of A107346 (and others, see below) from 5!-1 to 9!-1 terms, which is the natural (since maximal) length, given that OEIS sequence data are stored as decimal numbers. On the other hand, it is quite different from A219664 in many aspects, not only for the reason that the other sequence is infinite and therefore differs from this one in all terms beyond n = 9!-1.
The sequence is finite, with 9!-1 terms, and symmetric: a(n)=a(9!-n).
All terms are multiples of 9, cf. formula.
The subsequence of the first n!-1 terms (n=2,...,9) yields the first differences of the sequence of numbers whose digits are a permutation of (1,...,n):
The first 8!-1 terms yield the first differences of A178478: numbers whose digits are a permutation of 12345678.
The first 7!-1 terms yield the first differences of A178477: numbers whose digits are a permutation of 1234567.
The first 6!-1 terms yield the first differences of A178476: numbers whose digits are a permutation of 123456.
The first 5!-1 terms yield A107346, the first differences of A178475: numbers whose digits are a permutation of 12345.

Examples

			The same initial terms are obtained for the permutations of any set of the form {1,...,m}, e.g., {1,2,3} or {1,...,9}: In the first case we have P = (123,132,213,231,312,321) and P(4)-P(3) = 231 - 213 = 18 = a(3), and in the latter case P(4)-P(3) = 123456897 - 123456879 = 18, again. - _M. F. Hasler_, Jan 12 2013
		

Crossrefs

Programs

  • Mathematica
    Take[Differences[Sort[FromDigits/@Permutations[Range[9]]]],70] (* Harvey P. Dale, Mar 31 2018 *)
  • PARI
    A209280_list(N=5)={my(v=vector(N,i,10^(N-i))~); v=vecsort(vector(N!,k,numtoperm(N,k)*v)); vecextract(v,"^1")-vecextract(v,"^-1")} \\ return the N!-1 first terms as a vector
    
  • PARI
    A209280(n)={if(a209280=='a209280 || #a209280A209280_list(A090529(n+1)));a209280[n]}

Formula

a(n) = A219664(n) = 9*A217626(n) (for n < 9!). - M. F. Hasler, Jan 12 2013
a(n) = a(m!-n) for any m < 10 such that n < m!.

A178478 Permutations of 12345678: Numbers having each of the decimal digits 1..8 exactly once, and no other digit.

Original entry on oeis.org

12345678, 12345687, 12345768, 12345786, 12345867, 12345876, 12346578, 12346587, 12346758, 12346785, 12346857, 12346875, 12347568, 12347586, 12347658, 12347685, 12347856, 12347865, 12348567, 12348576, 12348657, 12348675, 12348756, 12348765
Offset: 1

Views

Author

M. F. Hasler, Oct 09 2010

Keywords

Comments

It would be nice to have a simple explicit formula for the n-th term.
An efficient procedure for generating the n-th term of this sequence can be found at A178475. - Nathaniel Johnston, May 19 2011

Crossrefs

Programs

  • Mathematica
    Take[FromDigits/@Permutations[Range[8]],40] (* Harvey P. Dale, Oct 29 2014 *)
  • PARI
    is_A178478(x)= { vecsort(Vec(Str(x)))==Vec("12345678") }
    
  • PARI
    A178478(n)={my(b=vector(7,k,1+(n-1)%(k+1)!\k!),t=b[7], d=vector(7,i,i+(i>=t)));for(i=1,6,t=10*t+d[b[7-i]]; d=vecextract(d,Str("^"b[7-i]))); t*10+d[1]} \\ - M. F. Hasler (following N. Johnston's comment), Jan 10 2012
Showing 1-3 of 3 results.