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-10 of 14 results. Next

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

A163778 Odd terms in A054639.

Original entry on oeis.org

3, 5, 9, 11, 23, 29, 33, 35, 39, 41, 51, 53, 65, 69, 81, 83, 89, 95, 99, 105, 113, 119, 131, 135, 155, 173, 179, 183, 189, 191, 209, 221, 231, 233, 239, 243, 245, 251, 261, 273, 281, 293, 299, 303, 309, 323, 329, 359, 371, 375, 393, 411, 413, 419, 429
Offset: 1

Views

Author

Peter R. J. Asveld, Aug 11 2009

Keywords

Comments

Previous name was: The A_1-primes (Archimedes_1 primes).
We have: (1) N is an A_1-prime iff N is odd, p=2N+1 is a prime number and only one of +2 and -2 generates Z_p^* (the multiplicative group of Z_p); (2) N is an A_1-prime iff p=2N+1 is a prime number and exactly one of the following holds: (a) N == 1 (mod 4) and +2 generates Z_p^* but -2 does not, (b) N == 3 (mod 4) and -2 generates Z_p^* but +2 does not.
The A_1-primes are the odd T- or Twist-primes (the T-primes are the same as the Queneau-numbers, A054639). For the related A_0-, A^+_1- and A^-_1-primes, see A163777, A163779 and A163780. Considered as a set, the present sequence is the union of the A^+_1-primes (A163779) and the A^-_1-primes (A163780). It is also equal to the difference of A054639 and the A_0-primes (A163777).

Crossrefs

Programs

  • Mathematica
    follow[s_, f_] := Module[{t, k}, t = f[s]; k = 1; While[t>s, k++; t = f[t]]; If[s == t, k, 0]];
    okQ[n_] := n>1 && n == follow[1, Function[j, Ceiling[n/2] + (-1)^j*Ceiling[ (j-1)/2]]];
    A163778 = Select[Range[1000], okQ] (* Jean-François Alcover, Jun 07 2018, after Andrew Howroyd *)
  • 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/2) + (-1)^j*ceil((j-1)/2))}
    select(ok, [1..1000]) \\ Andrew Howroyd, Nov 11 2017
    
  • PARI
    ok(n)={n>1 && n%2==1 && isprime(2*n+1) && znorder(Mod(2, 2*n+1)) == if(n%4==3, n, 2*n)}
    select(ok, [1..1000]) \\ Andrew Howroyd, Nov 11 2017

Extensions

a(33)-a(55) from Andrew Howroyd, Nov 11 2017
New name from Joerg Arndt, Mar 23 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

A163782 a(n) is the n-th J_2-prime (Josephus_2 prime).

Original entry on oeis.org

2, 5, 6, 9, 14, 18, 26, 29, 30, 33, 41, 50, 53, 65, 69, 74, 81, 86, 89, 90, 98, 105, 113, 134, 146, 158, 173, 174, 186, 189, 194, 209, 210, 221, 230, 233, 245, 254, 261, 270, 273, 278, 281, 293, 306, 309, 326, 329
Offset: 1

Views

Author

Peter R. J. Asveld, Aug 05 2009

Keywords

Comments

Place the numbers 1..N (N>=2) on a circle and cyclically mark the 2nd unmarked number until all N numbers are marked. The order in which the N numbers are marked defines a permutation; N is a J_2-prime if this permutation consists of a single cycle of length N.
The resulting permutation can be written as p(m,N) = (2N+1-||2N+1-m||)/2 (1 <= m <= N), where ||x|| is the odd number such that x/||x|| is a power of 2. E.g., ||16||=1 and ||120||=15.
No formula is known for a(n): the J_2-primes have been found by exhaustive search (however, see the CROSS-REFERENCES). But we have: (1) N is J_2-prime iff p=2N+1 is a prime number and +2 generates Z_p^* (the multiplicative group of Z_p). (2) N is J_2-prime iff p=2N+1 is a prime number and exactly one of the following holds: (a) N == 1 (mod 4) and +2 generates Z_p^* but -2 does not, (b) N == 2 (mod 4) and both +2 and -2 generate Z_p^*.

Examples

			p(1,5)=3, p(2,5)=1, p(3,5)=5, p(4,5)=2 and p(5,5)=4.
So p=(1 3 5 4 2) and 5 is J_2-prime.
		

References

  • R. L. Graham, D. E. Knuth & O. Patashnik, Concrete Mathematics (1989), Addison-Wesley, Reading, MA. Sections 1.3 & 3.3.

Crossrefs

A163783 through A163800 for J_3- through J_20-primes.
Considered as sets, A163782 is the union of A163777 and A163779, it equals the difference of A054639 and A163780, and 2*a(n) results in A071642.

Programs

  • Java
    isJ2Prime(int n) { // for n > 1
      int count = 0, leader = 0;
      if (n % 4 == 1 || n % 4 == 2) { // small optimization
        do {
          leader = A025480(leader + n);
          count++;
        } while (leader != 0);
      }
      return count == n;
    } // Joe Nellis, Jan 27 2023
  • Mathematica
    lst = {};
    Do[If[IntegerQ[(2^n + 1)/(2 n + 1)] && PrimitiveRoot[2 n + 1] == 2,
    AppendTo[lst, n]], {n, 2, 10^5}]; lst (* Hilko Koning, Sep 21 2021 *)
  • PARI
    Follow(s,f)={my(t=f(s),k=1); while(t>s, k++; t=f(t)); if(s==t, k, 0)}
    ok(n)={my(d=2*n+1); n>1&&n==Follow(1,i->(d-((d-i)>>valuation(d-i, 2)))/2)}
    select(n->ok(n),[1..1000]) \\ Andrew Howroyd, Nov 11 2017
    
  • PARI
    forprime(p=5, 2000, if(znorder(Mod(2, p))==p-1, print1((p-1)/2, ", "))); \\ Andrew Howroyd, Nov 11 2017
    

Formula

a(n) = A071642(n+3)/2.

A071642 Numbers n such that x^n + x^(n-1) + x^(n-2) + ... + x + 1 is irreducible over GF(2).

Original entry on oeis.org

0, 1, 2, 4, 10, 12, 18, 28, 36, 52, 58, 60, 66, 82, 100, 106, 130, 138, 148, 162, 172, 178, 180, 196, 210, 226, 268, 292, 316, 346, 348, 372, 378, 388, 418, 420, 442, 460, 466, 490, 508, 522, 540, 546, 556, 562, 586, 612, 618, 652, 658, 660, 676, 700, 708, 756, 772
Offset: 1

Views

Author

N. J. A. Sloane, Jun 22 2002

Keywords

Comments

All such polynomials of odd degree > 1 are reducible over GF(2).
For n >= 2, a(n) = A001122(n-2) - 1 due to the relationship between cycles and irreducibility. - T. D. Noe, Sep 09 2003
n such that a type-1 optimal normal basis of GF(2^n) (over GF(2)) exists. The corresponding field polynomial is the all-ones polynomial x^n+x^(n-1)+...+1. - Joerg Arndt, Feb 25 2008
From Peter R. J. Asveld, Aug 13 2009: (Start)
a(n) is also the n-th S-prime (Shuffle prime)
For N>=2, the family of 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
p(N,N) = N if N is odd.
N is S-prime if p(m,N) consists of a single cycle of length N.
So all S-primes are even.
N is S-prime iff p=N+1 is an odd prime number and +2 generates Z_p^* (the multiplicative group of Z_p).
a(n)/2 results in the Josephus_2-primes (A163782). Considered as sets a(n)/2 is the union of A163777 and A163779. If b(n) denotes the dual shuffle primes (A163776), 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). (End)
Conjecture: Terms >= 2 are numbers n such that P^n + P^(n-1) + P^(n-2) + ... + P + 1 is irreducible over GF(2), where P=x^2+x+1. - Luis H. Gallardo, Dec 23 2019

Examples

			For n=4 and n=6 we obtain the permutations (1 2 4 3) and (1 2 4)(3 6 5): 4 is S-prime, but 6 is not. [_Peter R. J. Asveld_, Aug 13 2009]
		

Crossrefs

Cf. A001122 (primes with primitive root 2).

Programs

  • Mathematica
    Join[{0, 1}, Reap[For[p = 2, p < 10^3, p = NextPrime[p], If[ MultiplicativeOrder[2, p] == p-1, Sow[p-1]]]][[2, 1]]] (* Jean-François Alcover, Dec 10 2015, adapted from PARI *)
  • PARI
    forprime(p=3,1000,if(znorder(Mod(2,p))==p-1,print1(p-1,", "))) /* Joerg Arndt, Jul 05 2011 */

Extensions

Extended by Robert G. Wilson v, Jun 24 2002
Initial terms of b-file corrected by N. J. A. Sloane, Aug 31 2009

A216371 Odd primes with one coach: primes p such that A135303((p-1)/2) = 1.

Original entry on oeis.org

3, 5, 7, 11, 13, 19, 23, 29, 37, 47, 53, 59, 61, 67, 71, 79, 83, 101, 103, 107, 131, 139, 149, 163, 167, 173, 179, 181, 191, 197, 199, 211, 227, 239, 263, 269, 271, 293, 311, 317, 347, 349, 359, 367, 373, 379, 383, 389, 419, 421, 443, 461, 463, 467, 479, 487
Offset: 1

Author

Gary W. Adamson, Sep 05 2012

Keywords

Comments

Given that prime p has only one coach, the corresponding value of k in A003558 must be (p-1)/2, and vice versa. Using the Coach theorem of Jean Pedersen et al., phi(b) = 2 * c * k, with b odd. Let b = p, prime. Then phi(p) = (p-1), and k must be (p-1)/2 iff c = 1. Or, phi(p) = (p-1) = 2 * 1 * (p-1)/2.
Conjecture relating to odd integers: iff an integer is in the set A216371 and is either of the form 4q - 1 or 4q + 1, (q>0); then the top row of its coach (cf. A003558) is composed of a permutation of the first q odd integers. Examples: 11 is of the form 4q - 1, q = 3; with the top row of its coach [1, 5, 3]. 13 is of the form 4q + 1, q = 3; so has a coach of [1, 3, 5]. 37 is of the form 4q + 1, q = 9; so has a coach with the top row composed of a permutation of the first 9 odd integers: [1, 9, 7, 15, 11, 13, 3, 17, 5]. - Gary W. Adamson, Sep 08 2012
Odd primes p such that 2^m is not congruent to 1 or -1 (mod p) for 0 < m < (p-1)/2. - Charles R Greathouse IV, Sep 15 2012
These are also the odd primes a(n) for which there is only one periodic Schick sequence (see the reference, and also the Brändli and Beyne link, eq. (2) for the recurrence but using various inputs. See also a comment in A332439). This sequence has primitive period length (named pes in Schick's book) A003558((a(n)-1)/2) = A005034(a(n)) = A000010(a(n))/2 = (a(n) - 1)/2, for n >= 1. - Wolfdieter Lang, Apr 09 2020
From Jianing Song, Dec 24 2022: (Start)
Primes p such that the multiplicative order of 4 modulo p is (p-1)/2. Proof of equivalence: let ord(a,k) be the multiplicative of a modulo k.
If 2^m is not 1 or -1 (mod p) for 0 < m < (p-1)/2, then ord(2,p) is either p-1 or (p-1)/2. If ord(2,p) = p-1, then ord(4,p) = (p-1)/2. If ord(2,p) = (p-1)/2, then p == 3 (mod 4), otherwise 2^((p-1)/4) == -1 (mod p), so ord(4,p) = (p-1)/2.
Conversely, if ord(4,p) = (p-1)/2, then ord(2,p) = p-1, or ord(2,p) = (p-1)/2 and p == 3 (mod 4) (otherwise ord(4,p) = (p-1)/4). In the first case, (p-1)/2 is the smallest m > 0 such that 2^m == +-1 (mod p); in the second case, since (p-1)/2 is odd, 2^m == -1 (mod p) has no solution. In either case, so 2^m is not 1 or -1 (mod p) for 0 < m < (p-1)/2.
{(a(n)-1)/2} is the sequence of indices of fixed points of A053447.
A prime p is a term if and only if one of the two following conditions holds: (a) 2 is a primitive root modulo p; (b) p == 3 (mod 4), and the multiplicative order of 2 modulo p is (p-1)/2 (in this case, we have p == 7 (mod 8) since 2 is a quadratic residue modulo p). (End)
From Jianing Song, Aug 11 2023: (Start)
Primes p such that 2 or -2 (or both) is a primitive root modulo p. Proof of equivalence: if ord(2,p) = p-1, then clearly ord(4,p) = (p-1)/2. If ord(-2,p) = p-1, then we also have ord(4,p) = (p-1)/2. Conversely, suppose that ord(4,p) = (p-1)/2, then ord(2,p) = p-1 or (p-1)/2, and ord(-2,p) = p-1 or (p-1)/2. If ord(2,p) = ord(-2,p) = (p-1)/2, then we have that (p-1)/2 is odd and (-1)^((p-1)/2) == 1 (mod p), a contradiction.
A prime p is a term if and only if one of the two following conditions holds: (a) -2 is a primitive root modulo p; (b) p == 3 (mod 4), and the multiplicative order of -2 modulo p is (p-1)/2 (in this case, we have p == 3 (mod 8) since -2 is a quadratic residue modulo p). (End)
No terms are congruent to 1 modulo 8, since otherwise we would have 4^((p-1)/4) = (+-2)^((p-1)/2) == 1 (mod p). - Jianing Song, May 14 2024
The n-th prime A000040(n) is a term iff A376010(n) = 2. - Max Alekseyev, Sep 05 2024

Examples

			Prime 23 has a k value of 11 = (23 - 1)/2 (Cf. A003558(11)). It follows that 23 has only one coach (A135303(11) = 1). 23 is thus in the set. On the other hand 31 is not in the set since A135303(15) shows 3 coaches, with A003558(15) = 5.
13 is in the set since A135303(6) = 1; but 17 isn't since A135303(8) = 2.
		

References

  • P. Hilton and J. Pedersen, A Mathematical Tapestry, Demonstrating the Beautiful Unity of Mathematics, 2010, Cambridge University Press, pages 260-264.
  • Carl Schick, Trigonometrie und unterhaltsame Zahlentheorie, Bokos Druck, Zürich, 2003 (ISBN 3-9522917-0-6). Tables 3.1 to 3.10, for odd p = 3..113 (with gaps), pp. 158-166.

Crossrefs

Union of A001122 and A105874.
A105876 is the subsequence of terms congruent to 3 modulo 4.
Complement of A268923 in the set of odd primes.
Cf. A082654 (order of 4 mod n-th prime), A000010, A000040, A003558, A005034, A053447, A054639, A135303, A364867, A376010.

Programs

  • Maple
    isA216371 := proc(n)
        if isprime(n) then
            if A135303((n-1)/2) = 1 then
                true;
            else
                false;
            end if;
        else
            false;
        end if;
    end proc:
    A216371 := proc(n)
        local p;
        if n = 1 then
            3;
        else
            p := nextprime(procname(n-1)) ;
            while true do
                if isA216371(p) then
                    return p;
                end if;
                p := nextprime(p) ;
            end do:
        end if;
    end proc:
    seq(A216371(n),n=1..40) ; # R. J. Mathar, Dec 01 2014
  • Mathematica
    Suborder[a_, n_] := If[n > 1 && GCD[a, n] == 1, Min[MultiplicativeOrder[a, n, {-1, 1}]], 0]; nn = 150; Select[Prime[Range[2, nn]], EulerPhi[#]/(2*Suborder[2, #]) == 1 &] (* T. D. Noe, Sep 18 2012 *)
    f[p_] := Sum[Cos[2^n Pi/((2 p + 1))], {n, p}]; 1 + 2 * Select[Range[500], Reduce[f[#] == -1/2, Rationals] &]; (* Gerry Martens, May 01 2016 *)
  • PARI
    is(p)=for(m=1,p\2-1, if(abs(centerlift(Mod(2,p)^m))==1, return(0))); p>2 && isprime(p) \\ Charles R Greathouse IV, Sep 18 2012
    
  • PARI
    is(p) = isprime(p) && (p>2) && znorder(Mod(4,p)) == (p-1)/2 \\ Jianing Song, Dec 24 2022

Formula

a(n) = 2*A054639(n) + 1. - L. Edson Jeffery, Dec 18 2012

A136415 Numbers n such that a type-3 Gaussian normal basis over GF(2^n) exists.

Original entry on oeis.org

4, 6, 12, 14, 20, 22, 46, 52, 54, 60, 70, 76, 92, 94, 116, 124, 126, 140, 166, 174, 180, 182, 204, 206, 214, 220, 230, 236, 244, 252, 262, 276, 284, 286, 292, 294, 302, 332, 340, 350, 356, 364, 372, 374, 390, 404, 412, 430, 460, 484, 494, 510, 516, 526, 532
Offset: 1

Author

Joerg Arndt, Mar 31 2008

Keywords

Comments

A type-t Gaussian normal basis exists for GF(2^n) if p=n*t+1 is prime and gcd(n,(p-1)/ord(2 mod p))==1.
Type-1 basis correspond to sequence A071642, type-2 basis to A054639.

Examples

			12 is in the list because 3*12+1=37 is prime and the index of 2 mod 37 (==36/ord(2 mod 37)==1, 2 is a generator mod 37) is coprime to 12.
		

Crossrefs

Programs

  • PARI
    gauss_test(n, t)=
    { /* test whether a type-t Gaussian normal basis exists for GF(2^n) */
      local( p, r2, g, d );
      p = t*n + 1;
      if ( !isprime(p), return( 0 ) );
      if ( p<=2, return( 0 ) );
      r2 = znorder( Mod(2, p) );
      d = (p-1)/r2;
      g = gcd(d, n);
      return ( if ( 1==g, 1, 0) );
    }
    /* generate this sequence: */
    t=3;ct=1;for(n=1,10^7,if(gauss_test(n,t), print1(n,", ");ct+=1;if(ct>200,break())))

A163779 Numbers k of the form 4*j + 1 such that 2*k + 1 is a prime with primitive root 2.

Original entry on oeis.org

1, 5, 9, 29, 33, 41, 53, 65, 69, 81, 89, 105, 113, 173, 189, 209, 221, 233, 245, 261, 273, 281, 293, 309, 329, 393, 413, 429, 441, 453, 473, 509, 545, 561, 585, 593, 629, 641, 645, 653, 713, 725, 741, 749, 761, 765, 785, 809, 833, 873, 893, 933, 953, 965, 989, 993
Offset: 1

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=1 (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 1 (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 A163780. Considered as sets the union of A163779 and A163780 equals A163778, the union of A163779 and A163777 is equal to A163782 (J_2-primes).

Programs

  • Mathematica
    okQ[n_] := Mod[n, 4] == 1 && PrimeQ[2n+1] && MultiplicativeOrder[2, 2n+1] == 2n;
    Select[Range[1000], okQ] (* Jean-François Alcover, Jun 30 2018, after Andrew Howroyd *)
  • PARI
    ok(n) = n%4==1 && isprime(2*n+1) && znorder(Mod(2, 2*n+1))==2*n;
    select(ok, [1..1000]) \\ Andrew Howroyd, Nov 11 2017

Formula

2 * a(n) + 1 = A213051(n+1). - Joerg Arndt, Mar 23 2018

Extensions

a(32)-a(55) from Andrew Howroyd, Nov 11 2017
Term 1 prepended and new name from Joerg Arndt, Mar 23 2018

A163781 a(n) is the n-th dJ_2 prime (dual Josephus_2 prime).

Original entry on oeis.org

2, 3, 6, 11, 14, 18, 23, 26, 30, 35, 39, 50, 51, 74, 83, 86, 90, 95, 98, 99, 119, 131, 134, 135, 146, 155, 158, 174, 179, 183, 186, 191, 194, 210, 230, 231, 239, 243, 251, 254, 270, 278, 299, 303, 306, 323, 326, 330, 338, 350, 354, 359, 371, 375, 378
Offset: 1

Author

Peter R. J. Asveld, Aug 17 2009

Keywords

Comments

The family of dual Josephus_2 (or dJ_2) permutations is defined by p(m,N)=(2N + 1 - F(m,2N + 1))/2 if 1<=m<=N, N>=2, where F(x,y) is the odd number such that 1<=F(x,y)=0. Note that F(2k + 1,y)=2k + 1 for 2k + 1
dJ_2 permutations can also be defined using a numbering/elimination procedure similar to the definition of the Josephus_2 permutations in [R.L. Graham et al.], or in A163782; see [P. R. J. Asveld].
No formula is known for a(n): the dJ_2 primes have been found by exhaustive search. But we have: (1) N is dJ_2 prime iff p=2N+1 is a prime number and -2 generates Z_p^* (the multiplicative group of Z_p); (2) N is dJ_2 prime iff p=2N+1 is a prime number and exactly one of the following holds:
(a) N=2 (mod 4) and both +2 and -2 generate Z_p^*,
(b) N=3 (mod 4) and -2 generates Z_p^* but +2 does not.

Examples

			For N=6 we have
  m       | 1   2   3   4   5   6
  --------+----------------------
  F(m,13) | 1   7   3  11   5   9
  t       | 0   2   0   1   0   3
  p(m,6)  | 6   3   5   1   4   2
So the permutation is (1 6 2 3 5 4) and 6 is dJ_2 prime.
		

References

  • R. L. Graham, D. E. Knuth & O. Patashnik, Concrete Mathematics (1989), Addison-Wesley, Reading, MA. Sections 1.3 & 3.3.

Crossrefs

Considered as sets the union of A163781 and A163782 (J_2 primes) equals A054639 (T-primes or Queneau numbers), their intersection is equal to A163777 (Archimedes_0 primes). A163781 equals the union of A163777 and A163780 (Archimedes^-_1 primes).

Programs

  • Mathematica
    okQ[n_] := Mod[n, 4] >= 2 && PrimeQ[2n+1] && MultiplicativeOrder[2, 2n+1] == If[OddQ[n], n, 2n];
    Select[Range[1000], okQ] (* Jean-François Alcover, Sep 23 2019, from PARI *)
  • PARI
    ok(n)={n%4>=2 && isprime(2*n+1) && znorder(Mod(2, 2*n+1)) == if(n%2,n,2*n)};
    select(ok, [1..1000]) \\ Andrew Howroyd, Nov 11 2017

Extensions

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

A220555 T(n,k) = maximal order N of cyclic group {D,D^2,...,D^N} generated by an n X n Danzer matrix D over Z/kZ, where D is from the m-th Danzer basis and m=2*n+1.

Original entry on oeis.org

1, 1, 1, 1, 3, 1, 1, 7, 8, 1, 1, 7, 26, 6, 1, 1, 31, 18, 14, 20, 1, 1, 63, 121, 14, 62, 24, 1, 1, 15, 26, 62, 62, 182, 16, 1, 1, 15, 24, 126, 781, 126, 42, 12, 1, 1, 511, 1640, 30, 24, 3751, 114, 28, 24, 1, 1, 63, 9841, 30, 20, 1638, 2801, 28, 78, 60, 1
Offset: 1

Author

L. Edson Jeffery, Dec 15 2012

Keywords

Comments

For definition of Danzer matrix see [Jeffery] (notation differs there!).
Conjecture 1. Let F_n(x)=sum_{j=0..n} A187660(n,j)*x^{(n-1)*j}. Let f_n in Z[x] be any polynomial in x of degree d such that 0<=d<=(n-1)*(n-2). Then the sequence of coefficients of the series expansion of f_n(x)/F_n(x), when taken over Z/kZ, is periodic with period p <= (n-1)*A220555(n,k), for all n,k > 1. (Cf. [Coleman, et al.] for the case for n=2 (generalized Fibonacci).)
Conjecture 2. If G a cyclic multiplicative group generated by an n X n integer matrix over Z/kZ, then |G|<=T(r,k), for some r<=n.
Definition. If T(n,k)>=(k^n-1)/(k-1), for some k>1, then T(n,k) is said to be "optimal."
Conjecture 3. If T(n,k) is optimal, then n is a Queneau number (A054639).
Sequence is read from antidiagonals of array T which begins as
.1...1....1....1......1.......1......1....1.....1.........1
.1...3....8....6.....20......24.....16...12....24........60
.1...7...26...14.....62.....182.....42...28....78.......434
.1...7...18...14.....62.....126....114...28....54.......434
.1..31..121...62....781....3751...2801..124...363.....24211
.1..63...26..126.....24....1638..13072..252....78.......504
.1..15...24...30.....20.....120....400...60....72........60
.1..15.1640...30..32552....4920.240200...60..4920....488280
.1.511.9841.1022.488281.5028751....342.2044.29523.249511591
.1..63...78..126....124....1638.....42..252...234......7812
Rows might be related to Jordan totient functions J_n(k), however, some entries T(n,k) are products of factors of the form (j^n-1)/(j-1).

Crossrefs

Cf. A001175 (possibly = row 2), A086839 (possibly = column 2), A160893, A160895, A160897, A160960, A160972, A161010, A161025, A161139, A161167, A161213.
Cf. A187772 (gives maximal periods p of Conjecture 1).
Showing 1-10 of 14 results. Next