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.

A065579 Inverse permutation to A065562.

Original entry on oeis.org

1, 2, 4, 3, 7, 5, 11, 6, 8, 16, 9, 12, 10, 22, 13, 17, 14, 29, 15, 18, 23, 19, 37, 20, 24, 21, 30, 25, 46, 26, 31, 27, 38, 28, 32, 56, 33, 39, 34, 47, 35, 40, 36, 67, 41, 48, 42, 57, 43, 49, 44, 79, 45, 50, 58, 51, 68, 52, 59, 53, 92, 54, 60, 55, 69, 61, 80, 62, 70, 63, 106, 64
Offset: 1

Views

Author

N. J. A. Sloane, Nov 29 2001

Keywords

Comments

Every positive integer occurs once and only once somewhere in this sequence.

Crossrefs

Cf. A065562.

Programs

  • PARI
    See Links section.

Extensions

More terms from John W. Layman, Jan 17 2002
More terms from David Wasserman, Aug 30 2002

A065561 a(1) = 1; for n >= 2, a(n) = (d(n)-1)-th highest positive integer that equals no a(k), 1 <= k < n, where d(n) is the number of positive divisors of n, A000005(n).

Original entry on oeis.org

1, 2, 3, 5, 4, 8, 6, 10, 9, 12, 7, 16, 11, 15, 17, 19, 13, 22, 14, 24, 21, 23, 18, 30, 25, 27, 28, 32, 20, 36, 26, 35, 33, 34, 37, 43, 29, 39, 40, 46, 31, 48, 38, 47, 49, 44, 41, 56, 45, 53, 51, 55, 42, 60, 54, 62, 57, 58, 50, 70, 52, 63, 66, 68, 64, 72, 59, 71, 67, 76, 61, 82
Offset: 1

Views

Author

Leroy Quet, Nov 29 2001

Keywords

Comments

Every positive integer occurs once and only once somewhere in this sequence.

Examples

			d(6)-1 = 3 and the 3rd-highest positive integer not equal to 1, 2, 3, 5, or 4 (the values of a(k) for 1 <= k < 6) is 8.
		

Crossrefs

Programs

  • Mathematica
    With[{nn = 72}, Fold[Append[#1, Complement[Range[#2 + Ceiling[nn/6]], #1][[DivisorSigma[0, #2] - 1]]] &, {1}, Range[2, nn]]] (* Michael De Vlieger, Dec 11 2017 *)

A101387 Quet transform of A002260.

Original entry on oeis.org

1, 1, 2, 1, 3, 1, 5, 1, 1, 7, 1, 2, 1, 9, 1, 3, 1, 12, 1, 1, 4, 1, 15, 1, 2, 1, 5, 1, 18, 1, 3, 1, 7, 1, 1, 21, 1, 4, 1, 9, 1, 2, 1, 24, 1, 5, 1, 11, 1, 3, 1, 28, 1, 1, 6, 1, 13, 1, 4, 1, 32, 1, 2, 1, 7, 1, 15, 1, 5, 1, 36, 1, 3, 1, 9, 1, 1, 17, 1, 6, 1, 40, 1, 4, 1, 11, 1, 2, 1, 19, 1, 7, 1, 44, 1, 5, 1
Offset: 1

Views

Author

David Wasserman, Jan 14 2005

Keywords

Comments

The Quet transform converts any sequence of positive integers containing an infinite number of 1's into another sequence of positive integers containing an infinite number of 1's.
Start with a sequence, {a(k)}, of only positive integers and an infinite number of 1's. Example: 1,1,2,1,2,3,1,2,3,4,1,... (A002260).
Form the sequence {b(k)} (which is a permutation of the positive integers), given by b(k) = the a(k)th smallest positive integer not yet in the sequence b, with b(1)=a(1).
In the example b is 1,2,4,3,6,8,5,9,11,13,7,12,15,... (A065562).
Let {c(k)} be the inverse of {b(k)}. In the example c = 1,2,4,3,7,5,11,6,8,16,9,12... (A065579).
Form the final sequence {d(k)}, where each d(k) is such that c(k) = the d(k)th smallest positive integer not yet in the sequence c, with d(1)=c(1).
In the example d is 1,1,2,1,3,1,5,1,1,7,1,2,1,9,1,3,1,12,1,1,4,1,15,... (the current sequence).
A more formal description of the Quet transform is as follows.
Let N denote the positive integers. For any permutation p: N -> N, let T(p): N -> N be given by T(p)(n) = # of elements in {m in N | m >= n AND p(m) <= p(n)}. Observe that T is a bijection from the set of permutations N -> N onto the set of sequences N -> N that contain infinitely many 1's.
Now suppose f: N -> N contains infinitely many 1's; then its Quet transform Q(f): N -> N is T^(-1)[(T(f))^(-1)], which also contains infinitely many 1's. Q is self-inverse; f and Q(f) correspond via T to a permutation and its inverse.

Crossrefs

Programs

  • PARI
    \\ PARI code to compute the Quet transform.  Put the first n terms of the sequence
    \\ into a vector v; then Q(v) returns the transformed sequence.  The output is a
    \\ vector, containing as many terms as can be computed from the given data.
    TInverse(v) = local(l, w, used, start, x); l = length(v); w = vector(l); used = vector(l); start = 1; for (i = 1, l, while (start <= l && used[start], start++); x = start; for (j = 2, v[i], x++; while (x <= l && used[x], x++)); if (x > l, return (vector(i - 1, k, w[k])), w[i] = x; used[x] = 1)); w;
    PInverse(v) = local(l, w); l = length(v); w = vector(l); for (i = 1, l, if (v[i] <= l, w[v[i]] = i)); w;
    T(v) = local(l, w, c); l = length(v); w = vector(l); for (n = 1, l, if (v[n], c = 0; for (m = 1, n - 1, if (v[m] < v[n], c++)); w[n] = v[n] - c, return (vector(n - 1, i, w[i])))); w;
    Q(v) = T(PInverse(TInverse(v)));
    \\ David Wasserman, Jan 14 2005
Showing 1-3 of 3 results.