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

A230079 Table a(n,m) of coefficients of inverses of rho(A230078(n)), n>=2, with rho(k):= 2*cos(Pi/k), in the power basis of Q(rho(A230078(n))).

Original entry on oeis.org

1, -1, 1, 2, 1, -1, -3, 0, 1, 3, 3, -4, -1, 1, 0, 4, 0, -1, -3, 6, 4, -5, -1, 1, 4, 4, -1, -1, -4, 10, 10, -15, -6, 7, 1, -1, 5, 10, -20, -15, 21, 7, -8, -1, 1, 0, 12, 0, -19, 0, 8, 0, -1, -8, -8, 6, 6, -1, -1, 6, 15, -35, -35, 56, 28, -36, -9, 10, 1, -1
Offset: 2

Views

Author

Wolfdieter Lang, Nov 02 2013

Keywords

Comments

The length of row n is delta(A230078(n)), n>=2, with delta(k) = A055034(k).
The power base of the algebraic number field Q(rho(k)), with rho(k):= 2*cos(Pi/k), k >= 2, is <1, rho(k), rho(k)^2, ..., rho(k)^(delta(k)-1)>. Q(rho(k))-integers have integer coefficients in this basis. A230078(n), n >= 2, gives precisely the numbers k for which the inverse 1/rho(k) is a Q(rho(k))-integer. The present table a(n,m) lists these integer coefficients for 1/rho(A230078(n)), n >= 2, m = 0, 1, ..., delta(A230078(n))-1. delta(k) is the degree of the minimal polynomial C(k, x) of rho(k) (see A187360).
In general, 1/rho(k) = -(sum(c(k, m+1)*rho(k)^m, m=0..delta(k)-1))/c(k, 0), k >= 2, with the coefficients c(k ,m) of the minimal polynomial C(k, x) given in A187360(k, m). c(k ,0) = C(k, x=0) is +1 or -1 if and only if k is from {A230078(n), n>=2}, leading to a Q(rho(k))-integer.

Examples

			The table a(n,m) begins, with b(n):=A230078(n):
n, b(n)\m 0  1     2    3   4   5    6   7   8  9  10 ...
2,   3:   1
3,   5:  -1   1
4,   7:   2   1   -1
5,   9:  -3   0    1
6,  11:   3   3   -4   -1   1
7,  12:   0   4    0   -1
8,  13:  -3   6    4   -5  -1   1
9,  15:   4   4   -1   -1
10, 17:  -4  10   10  -15  -6   7    1  -1
11, 19:   5  10  -20  -15  21   7   -8  -1   1
12, 20:   0  12    0  -19   0   8    0  -1
13, 21:  -8  -8    6    6  -1  -1
14, 23:   6  15  -35  -35  56  28  -36  -9  10  1  -1
15, 24:   0  16    0  -20   0   8    0  -1
...
n=2: C(3, x) = x - 1, delta(3) =1, 1/rho(3) = 1, a rational integer.
n=3: C(5, x) =x^2 - x -1, delta(5) = 2,  a(3,0) = - c(5, 1)/c(5, 0) = -(-1)/(-1) = -1, a(3,1) = - c(5, 2)/c(5, 0) = -1/(-1) = +1.
n =3: rho(5) = tau := (1 + sqrt(5))/2 (golden section); 1/rho(5) = -1*1 + 1*rho(5).
n= 4: rho(7) = 2*cos(Pi/7), (approximately 1.801937736); 1/rho(7) = 2*1 + 1*rho(7)  - 1*rho(7)^2, (approximately 0.5549581320).
n=10: rho(17) = 2*cos(Pi/17), (approximately 1.965946199); 1/rho(17) = -4*1 + 10*rho(17)  + 10*rho(17)^2  - 15*rho(17)^3  - 6*rho(17)^4 + 7*rho(17)^5 + 1*rho(17)^6  -1*rho(17)^7, (approximately 0.5086609190).
		

Crossrefs

Formula

a(n,m) = -c(b(n), m+1)/c(b(n), 0), with b(n) := A230078(n), for n>=2 and m= 0, 1, ... , delta(b(n)) -1, with delta(k) = A055034(k), and c(k, m) = A187360(k, m) (see a comment above on the minimal C polynomials).

A187360 Coefficient array for minimal polynomials of 2*cos(Pi/n) (rising powers of x).

Original entry on oeis.org

2, 1, 0, 1, -1, 1, -2, 0, 1, -1, -1, 1, -3, 0, 1, 1, -2, -1, 1, 2, 0, -4, 0, 1, -1, -3, 0, 1, 5, 0, -5, 0, 1, -1, 3, 3, -4, -1, 1, 1, 0, -4, 0, 1, -1, -3, 6, 4, -5, -1, 1, -7, 0, 14, 0, -7, 0, 1, 1, -4, -4, 1, 1, 2, 0, -16, 0, 20, 0, -8, 0, 1, 1, 4, -10, -10, 15, 6, -7, -1, 1
Offset: 1

Views

Author

Wolfdieter Lang, Jul 14 2011

Keywords

Comments

The degree delta(n) of the monic integer row polynomial, call it C(n,x), is A055034(n).
This minimal polynomial of the algebraic number 2*cos(Pi/n), n>=1, is given by
C(n,x) = sum(a(n,m)*x^m,m=0..A055034(n)) = (2^delta(n))*Psi(2n,x/2), with Psi(n,x) the minimal polynomial of cos(2Pi/n), with rational coefficient array A181875/A181876. There also references and links are found. See especially Watkins and Zeitlin for Psi(n,x).
The zeros of C(n,x), n>=2, are 2*cos(Pi k/n), with k=1,...,n-1 and gcd(k,2n)=1. For n=1 the zero is -2. Alternatively, these zeros are 2*cos(Pi(2l+1)/n), with l=0,...,floor((n-2)/2) and gcd(2l+1,n)=1. For n=1 take l=0.
The first column looks like the differently signed A020513(n),n>=1.
The polynomial for row n=2^m, m>=1, coincides with the row polynomial R(2^(m-1),x) of A127672. See the factorization of these R-polynomials (also known as Chebyshev C-polynomials) given there. - Wolfdieter Lang, Sep 15 2011
From Wolfdieter Lang, Nov 04 2013: (Start)
The norm N(rho(n)) of rho(n) = 2*cos(Pi/n), n >= 1, in the algebraic number field Q(rho(n)) is given by (-1)^delta(n)* C(n, 0), with C(n, x) of degree delta(n) = A055034(n). If N(rho(n)) equals +1 or -1 then 1/rho(n), which is an element of Q(rho(n)), is in fact an integer in this number field. For the 1/rho(n) formula in terms of the C coefficients see A230079. Thus 1/rho(n) is a Q(rho(n))-integer if and only if C(n, 0) is +1 or -1 , and this happens if and only if n is from the set {A230078(k), k >= 2}.
The negation says that, for n a positive integer, 1/rho(n) is not a Q(rho(n))-integer if and only if n is 1 or of the form 2*p^m, m >= 0 and p a prime, which are the numbers of A138929 including 1.
The proof uses for case (i): n = 2*m+1, m >= 1, the fact that C(2*m+1, 0)^2 = (product( 2*cos(Pi*(2*l+1)/(2*m+1)), l=0 .. m-1 and gcd(2*l+1, 2*m+1) = 1))^2 = (product(2*cos(Pi*k/(2*m+1)), k=1..L and gcd(k, 2*m+1) = 1))^2 = cyclotomic(2*m +1, -1). See the linked Q(rho(n)) paper, eq. (31), for a product formula for cyclotomic(n, -1). With the prime factorization of 2*m+1, and the fact that only the squarefree kernel of 2*m+1 enters (see an Oct 29 2013 comment on A013595), one finds, form the formula for cyclotomic(p1*p2*...*pk, x) involving the Moebius function, cyclotomic(2*m +1, -1) = +1, m >= 1. C(1, 0) = +2. For case (ii): n even, one has C(2^m, 0) = 0, -2, +2, for m = 1 , 2, >=3, respectively (see eq. (39) of the linked Q(rho(n)) paper). For odd prime p: (-1)^((p-1)/2)*C(2*p^m, 0) = cyclotomic(2*p^m, -1) = cyclotomic(2*p, -1) = cyclotomic(p, +1) = p, for m >= 1. For more than one odd prime in the squarefree kernel of n = 2*m, m >= 1, one finds C(2*m, 0) = +1 from cyclotomic(2*p1*...*pk, -1) = +1, for k >= 2. (End)
For the conversion of the C-polynomials into sums of Chebyshev's S-polynomials (A049310) see A255237. - Wolfdieter Lang, Mar 16 2015

Examples

			n=1:  2, 1;
n=2:  0, 1;
n=3: -1, 1;
n=4: -2, 0, 1;
n=5: -1,-1, 1;
n=6: -3, 0, 1;
n=7:  1,-2,-1, 1;
n=8:  2, 0,-4, 0, 1;
n=9: -1,-3, 0, 1;
n=10: 5, 0,-5, 0, 1;
...
C(2,x) = R(1,x), C(4,x) = R(2,x), C(8,x) = R(4,x),... with R(n,x) from A127672. - _Wolfdieter Lang_, Sep 15 2011
		

Crossrefs

Cf. A192003 (row sums). A192004 (alternating row sums).

Programs

  • Maple
    f:= proc(n) local P,z,j;
       P:= factor(evala(Norm(z-convert(2*cos(Pi/n),RootOf))));
       if type(P,`^`) then P:= op(1,P) fi;
       seq(coeff(P,z,j),j=0..degree(P));
    end proc:
    seq(f(n),n=1..20); # Robert Israel, Aug 04 2015
  • Mathematica
    Flatten[ CoefficientList[ Table[ MinimalPolynomial[2*Cos[Pi/n], x], {n, 1, 17}], x]] (* Jean-François Alcover, Sep 26 2011 *)
  • PARI
    halftot(n)=if(n<=2, 1, eulerphi(n)/2); \\ A023022
    default(realprecision, 110);
    row(n) = Vecrev(algdep(2*cos(2*Pi/n), halftot(n))); \\ Michel Marcus, Sep 19 2023

Formula

a(n,m) = [x^m] C(n,x), n>=1, m=0..A055034(n), with the minimal (monic and integer) polynomial C(n,x) of 2*cos(Pi/n). See the comment above.

A138929 Twice the prime powers A000961.

Original entry on oeis.org

2, 4, 6, 8, 10, 14, 16, 18, 22, 26, 32, 34, 38, 46, 50, 54, 58, 62, 64, 74, 82, 86, 94, 98, 106, 118, 122, 128, 134, 142, 146, 158, 162, 166, 178, 194, 202, 206, 214, 218, 226, 242, 250, 254, 256, 262, 274, 278, 298, 302, 314, 326, 334, 338, 346, 358, 362, 382
Offset: 1

Views

Author

M. F. Hasler, Apr 04 2008

Keywords

Comments

Except for the initial term a(1)=2, indices k such that A020513(k)=Phi[k](-1) is prime, where Phi is a cyclotomic polynomial.
This is illustrated by the PARI code, although it is probably more efficient to calculate a(n) as 2*A000961(n).
{ a(n)/2 ; n>1 } are also the indices for which A020500(k)=Phi[k](1) is prime.
A188666(k) = A000961(k+1) for k: a(k) <= k < a(k+1), k > 0;
A188666(a(n)) = A000961(n+1). [Reinhard Zumkeller, Apr 25 2011]

Crossrefs

Cf. A000961, A020513, A138920-A138940, A230078 (complement).

Programs

  • Maple
    a := n -> `if`(1>=nops(numtheory[factorset](n)),2*n,NULL):
    seq(a(i),i=1..192); # Peter Luschny, Aug 12 2009
  • Mathematica
    Join[{2}, Select[ Range[3, 1000], PrimeQ[ Cyclotomic[#, -1]] &]] (* Robert G. Wilson v, Mar 25 2012 - modified by Paolo Xausa, Aug 30 2024 to include a(1) *)
    2*Join[{1}, Select[Range[500], PrimePowerQ]] (* Paolo Xausa, Aug 30 2024 *)
  • PARI
    print1(2);for( i=1,999, isprime( polcyclo(i,-1)) & print1(",",i)) /* use ...subst(polcyclo(i),x,-2)... in PARI < 2.4.2. It should be more efficient to calculate a(n) as 2*A000961(n) ! */
    
  • Python
    from sympy import primepi, integer_nthroot
    def A138929(n):
        def f(x): return int(n-1+x-sum(primepi(integer_nthroot(x,k)[0]) for k in range(1,x.bit_length())))
        kmin, kmax = 0,1
        while f(kmax) > kmax:
            kmax <<= 1
        while kmax-kmin > 1:
            kmid = kmax+kmin>>1
            if f(kmid) <= kmid:
                kmax = kmid
            else:
                kmin = kmid
        return kmax<<1 # Chai Wah Wu, Aug 29 2024

Formula

a(n) = 2*A000961(n).
Equals {2} union { k | Phi[k](-1)=A020513(k) is prime } = {2} union { 2k | Phi[k](1)=A020500(k) is prime }.

A346608 Indices k such that A047994(k) != A344005(k).

Original entry on oeis.org

12, 15, 20, 21, 24, 28, 30, 33, 35, 36, 39, 40, 42, 44, 45, 48, 51, 52, 55, 56, 57, 60, 63, 65, 66, 68, 69, 70, 72, 75, 76, 77, 78, 80, 84, 85, 87, 88, 90, 91, 92, 93, 95, 96, 99, 100, 102, 104, 105, 108, 110, 111, 112, 114, 115, 116, 117, 119, 120, 123, 124, 126, 129, 130, 132, 133, 135, 136, 138, 140
Offset: 1

Views

Author

N. J. A. Sloane, Aug 09 2021

Keywords

Comments

Conjectures: (i) For all k in this sequence, A047994(k) >= A344005(k).
(ii) Equals composite numbers with {18, 2*p (p prime), p^i (p prime, i >= 2)} deleted.
The second conjecture asserts that this is equal to A265128 with {0, 1, 18} deleted.
I believe I have a proof of both conjectures, although I have not yet written out all the details.
Numbers k that are in A265128, but do not appear here are: 1, 18, 50, 54, 98, 162, 242, 250, 338, 486, 578, 686, ... probably given by {1} UNION A354929. Hence conjecture: the sequence consists of numbers that are neither a power of prime, or 2 * power of prime. - Antti Karttunen, Jun 14 2022
Is this the set of all k such that Phi_k(-1) = Phi_k(0) = Phi_k(1) where Phi_k denotes the k-th cyclotomic polynomial? - Jeppe Stig Nielsen, Jun 26 2023

Crossrefs

Cf. A047994, A265128, A344005, A345992, A354928 (complement).
Positions of nonzeros in A346607. Positions of zeros in A354924.
Setwise difference A265128 \ ({0,1} U A138929). (conjectured).
Intersection of A024619 and A230078 (conjectured).

Programs

Showing 1-4 of 4 results.