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-5 of 5 results.

A054639 Queneau numbers: numbers n such that the Queneau-Daniel permutation {1, 2, 3, ..., n} -> {n, 1, n-1, 2, n-2, 3, ...} is of order n.

Original entry on oeis.org

1, 2, 3, 5, 6, 9, 11, 14, 18, 23, 26, 29, 30, 33, 35, 39, 41, 50, 51, 53, 65, 69, 74, 81, 83, 86, 89, 90, 95, 98, 99, 105, 113, 119, 131, 134, 135, 146, 155, 158, 173, 174, 179, 183, 186, 189, 191, 194, 209, 210, 221, 230, 231, 233, 239
Offset: 1

Views

Author

Gilles Esposito-Farese (gef(AT)cpt.univ-mrs.fr), May 17 2000

Keywords

Comments

The troubadour Arnaut Daniel composed sestinas based on the permutation 123456 -> 615243, which cycles after 6 iterations.
Roubaud quotes the number 141, but the corresponding Queneau-Daniel permutation is only of order 47 = 141/3.
This appears to coincide with the numbers n such that a type-2 optimal normal basis exists for GF(2^n) over GF(2). But are these two sequences really the same? - Joerg Arndt, Feb 11 2008
The answer is Yes - see Theorem 2 of the Dumas reference. [Jean-Guillaume Dumas (Jean-Guillaume.Dumas(AT)imag.fr), Mar 20 2008]
From Peter R. J. Asveld, Aug 17 2009: (Start)
a(n) is the n-th T-prime (Twist prime). For N >= 2, the family of twist permutations is defined by
p(m,N) == +2m (mod 2N+1) if 1 <= m < k = ceiling((N+1)/2),
p(m,N) == -2m (mod 2N+1) if k <= m < N.
N is T-prime if p(m,N) consists of a single cycle of length N.
The twist permutation is the inverse of the Queneau-Daniel permutation.
N is T-prime iff p=2N+1 is a prime number and exactly one of the following three conditions holds;
(1) N == 1 (mod 4) and +2 generates Z_p^* (the multiplicative group of Z_p) but -2 does not,
(2) N == 2 (mod 4) and both +2 and -2 generate Z_p^*,
(3) N == 3 (mod 4) and -2 generate Z_p^* but +2 does not. (End)
The sequence name says the permutation is of order n, but P. R. J. Asveld's comment says it's an n-cycle. Is there a proof that those conditions are equivalent for the Queneau-Daniel permutation? (They are not equivalent for any arbitrary permutation; e.g., (123)(45)(6) has order 6 but isn't a 6-cycle.) More generally, I have found that for all n <= 9450, (order of Queneau-Daniel permutation) = (length of orbit of 1) = A003558(n). Does this hold for all n? - David Wasserman, Aug 30 2011

Examples

			For N=6 and N=7 we obtain the permutations (1 2 4 5 3 6) and (1 2 4 7)(3 6)(5): 6 is T-prime, but 7 is not. - _Peter R. J. Asveld_, Aug 17 2009
		

References

  • Raymond Queneau, Note complémentaire sur la Sextaine, Subsidia Pataphysica 1 (1963), pp. 79-80.
  • Jacques Roubaud, Bibliothèque Oulipienne No 65 (1992) and 66 (1993).

Crossrefs

Not to be confused with Queneau's "s-additive sequences", see A003044.
A005384 is a subsequence.
Union of A163782 (Josephus_2-primes) and A163781 (dual Josephus_2-primes); also the union of A163777 (Archimedes_0-primes) and A163778 (Archimedes_1-primes); also the union of A071642/2 (shuffle primes) and A163776/2 (dual shuffle primes). - Peter R. J. Asveld, Aug 17 2009
Cf. A216371, A003558 (for which a(n) == n).

Programs

  • Maple
    QD:= proc(n) local i;
      if n::even then map(op,[seq([n-i,i+1],i=0..n/2-1)])
      else map(op, [seq([n-i,i+1],i=0..(n-1)/2-1),[(n+1)/2]])
      fi
    end proc:
    select(n -> GroupTheory:-PermOrder(Perm(QD(n)))=n, [$1..1000]); # Robert Israel, May 01 2016
  • Mathematica
    a[p_] := Sum[Cos[2^n Pi/((2 p + 1) )], {n, 1, p}];
    Select[Range[500],Reduce[a[#] == -1/2, Rationals] &] (* Gerry Martens, May 01 2016 *)
  • PARI
    is(n)=
    {
        if (n==1, return(1));
        my( m=n%4 );
        if ( m==4, return(0) );
        my(p=2*n+1, r=znorder(Mod(2,p)));
        if ( !isprime(p), return(0) );
        if ( m==3 && r==n, return(1) );
        if ( r==2*n, return(1) ); \\ r == 1 or 2
        return(0);
    }
    for(n=1,10^3, if(is(n),print1(n,", ")) );
    \\ Joerg Arndt, May 02 2016

Formula

a(n) = (A216371(n)-1)/2. - L. Edson Jeffery, Dec 18 2012
a(n) >> n log n, and on the Bateman-Horn-Stemmler conjecture a(n) << n log^2 n. I imagine a(n) ≍ n log n, and numerics suggest that perhaps a(n) ~ kn log n for some constant k (which seems to be around 1.122). - Charles R Greathouse IV, Aug 02 2023

A163777 Even terms in the sequence of Queneau numbers A054639.

Original entry on oeis.org

2, 6, 14, 18, 26, 30, 50, 74, 86, 90, 98, 134, 146, 158, 174, 186, 194, 210, 230, 254, 270, 278, 306, 326, 330, 338, 350, 354, 378, 386, 398, 410, 414, 426, 438, 470, 530, 554, 558, 606, 614, 618, 638, 650, 686, 690, 726, 746, 774, 810, 818, 834, 846, 866, 870
Offset: 1

Views

Author

Peter R. J. Asveld, Aug 11 2009

Keywords

Comments

Previous name was: a(n) is the n-th A_0-prime (Archimedes_0 prime).
We have: (1) N is A_0-prime if and only if N is even, p = 2N + 1 is a prime number and both +2 and -2 generate Z_p^* (the multiplicative group of Z_p); (2) N is A_0-prime if and only if N = 2 (mod 4), p = 2N + 1 is a prime number and both +2 and -2 generate Z_p^*.

Crossrefs

The A_0-primes are the even T- or Twist-primes, these T-primes are equal to the Queneau-numbers (A054639). For the related A_1-, A^+_1- and A^-_1-primes, see A163778, A163779 and A163780. Considered as sets A163777 is the intersection of the Josephus_2-primes (A163782) and the dual Josephus_2-primes (A163781), it also equals the difference of A054639 and the A_1-primes (A163779).
Cf. A137310.

Programs

  • Mathematica
    okQ[n_] := EvenQ[n] && PrimeQ[2n+1] && MultiplicativeOrder[2, 2n+1] == 2n;
    Select[Range[1000], okQ] (* Jean-François Alcover, Sep 10 2019, from PARI *)
  • PARI
    Follow(s, f)={my(t=f(s), k=1); while(t>s, k++; t=f(t)); if(s==t, k, 0)}
    ok(n)={n>1 && n==Follow(1, j->ceil((n+1)/2) - (-1)^j*ceil((j-1)/2))}
    select(ok, [1..1000]) \\ Andrew Howroyd, Nov 11 2017
    
  • PARI
    ok(n)={n%2==0 && isprime(2*n+1) && znorder(Mod(2, 2*n+1)) == 2*n}
    select(ok, [1..1000]) \\ Andrew Howroyd, Nov 11 2017

Formula

a(n) = 2*A137310(n). - Andrew Howroyd, Nov 11 2017

Extensions

Definition simplified by Michel Marcus, May 27 2013
a(33)-a(55) from Andrew Howroyd, Nov 11 2017
New name from Joerg Arndt, Mar 23 2018, edited by M. F. Hasler, Mar 24 2018

A163780 Terms in A054639 equal to 3 mod 4.

Original entry on oeis.org

3, 11, 23, 35, 39, 51, 83, 95, 99, 119, 131, 135, 155, 179, 183, 191, 231, 239, 243, 251, 299, 303, 323, 359, 371, 375, 411, 419, 431, 443, 483, 491, 495, 515, 519, 531, 543, 575, 611, 615, 639, 651, 659, 683, 719, 723, 743, 755, 771, 779, 783, 791, 803, 831, 879
Offset: 1

Views

Author

Peter R. J. Asveld, Aug 12 2009

Keywords

Comments

Previous name was: a(n) is the n-th A^-_1-prime (Archimedes^-_1 prime).
N is A^-_1-prime iff N=3 (mod 4), p=2N+1 is a prime number and -2 generates Z_p^* (the multiplicative group of Z_p) but +2 does not.

Crossrefs

The A^-_1-primes are the T- or Twist-primes congruent 3 (mod 4), these T-primes are equal to the Queneau-numbers (A054639). For the related A_0-, A_1- and A^+_1-primes, see A163777, A163778 and A163779. Considered as sets the union of A163779 and A163780 equals A163778, the union of A163780 and A163777 is equal to A163781 (dual J_2-primes).

Programs

  • PARI
    ok(n) = n%4==3 && isprime(2*n+1) && znorder(Mod(2, 2*n+1)) == n;
    select(ok, [1..1000]) \\ Andrew Howroyd, Nov 11 2017

Extensions

a(33)-a(55) from Andrew Howroyd, Nov 11 2017
New name from Andrey Zabolotskiy, Mar 23 2018

A163776 a(n) is the n-th dS-prime (dual Shuffle prime).

Original entry on oeis.org

4, 6, 12, 22, 28, 36, 46, 52, 60, 70, 78, 100, 102, 148, 166, 172, 180, 190, 196, 198, 238, 262, 268, 270, 292, 310, 316, 348, 358, 366, 372, 382, 388, 420, 460, 462, 478, 486, 502, 508, 540, 556, 598, 606, 612, 646, 652, 660, 676, 700, 708, 718, 742, 750, 756
Offset: 1

Views

Author

Peter R. J. Asveld, Aug 13 2009

Keywords

Comments

For N>=2, the family of dual shuffle permutations is defined by p(m,N) = -2m (mod N+1) if N is even, p(m,N) = -2m (mod N) if N is odd and 1<=m
No formula is known for a(n): the dS-primes have been found by exhaustive search. But we have: N is dS-prime iff p=N+1 is an odd prime number and -2 generates Z_p^* (the multiplicative group of Z_p).

Examples

			For N=6 and N=10 we obtain the permutations (1 5 4 6 2 3) and (1 9 4 3 5)(2 7 8 6 10): 6 is dS-prime, but 10 is not.
		

Crossrefs

a(n)/2 results in the dual Josephus_2-primes (A163781). Considered as sets a(n)/2 is the union of A163777 and A163780. If b(n) denotes the shuffle primes (A071642), then the union of a(n)/2 and b(n)/2 is equal to the Twist-primes or Queneau numbers (A054639), their intersection is equal to the Archimedes_0-primes (A163777).

Formula

a(n) = 2*A163781(n).

Extensions

a(33)-a(55) from Andrew Howroyd, Nov 11 2017

A373416 Fixed points of A323712: sizes k of card decks that return to original order after k pile shuffles (but not earlier).

Original entry on oeis.org

1, 3, 4, 6, 9, 12, 22, 27, 28, 36, 46, 52, 60, 70, 78, 81, 100, 102, 148, 166, 172, 180, 190, 196, 198, 238, 243, 262, 268, 270, 292, 310, 316, 348, 358, 366, 372, 382, 388, 420, 460, 462, 478, 486, 502, 508, 540, 556, 598, 606, 612, 646, 652, 660, 676, 700, 708, 718, 729, 742
Offset: 1

Author

R. J. Mathar, Aug 02 2024

Keywords

Comments

The pile shuffle of a card stack [1,2,3...,n] puts 1 at the bottom of a first auxiliary stack, 2 at the bottom of a second auxiliary stack, 3 above the 1, 4 above the 2, 5 above the 3, 6 above the 4.. eventually the shuffled stack is the first auxiliary stack on top of the second auxiliary stack.
Sequence A263458 contains sizes 2k of card decks that return to reverse order after k pile shuffles. They return to original order after 2k shuffles (2 reversals), so entries of A263458 are candidates for entries here. The case of 30 cards shows that this is not that simple: 30 cards are in reverse order after 5 shuffles, back to original order after 10 shuffles, in reverse order after 15 shuffles (so 30 is in A263458) etc. Because the return to normal order happens already after 10 shuffles (not only at 30), 30 is not in this sequence here.

Crossrefs

Cf. A323712, A163781 (even terms halved ?), A263458.

Formula

Equals the ordered set {k: A323712(k) = k}.
Showing 1-5 of 5 results.