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

A101455 a(n) = 0 for even n, a(n) = (-1)^((n-1)/2) for odd n. Periodic sequence 1,0,-1,0,...

Original entry on oeis.org

0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0, -1, 0, 1, 0
Offset: 0

Views

Author

Gerald McGarvey, Jan 20 2005

Keywords

Comments

Called X(n) (i.e., Chi(n)) in Hardy and Wright (p. 241), who show that X(n*m) = X(n)*X(m) for all n and m (i.e., X(n) is completely multiplicative) since (n*m - 1)/2 - (n - 1)/2 - (m - 1)/2 = (n - 1)*(m - 1)/2 == 0 (mod 2) when n and m are odd.
Same as A056594 but with offset 1.
From R. J. Mathar, Jul 15 2010: (Start)
The sequence is the non-principal Dirichlet character mod 4. (The principal character is A000035.)
Associated Dirichlet L-functions are for example L(1,chi) = Sum_{n>=1} a(n)/n = A003881, or L(2,chi) = Sum_{n>=1} a(n)/n^2 = A006752, or L(3,chi) = Sum_{n>=1} a(n)/n^3 = A153071. (End)
a(n) is a strong elliptic divisibility sequence t_n as given in [Kimberling, p. 16] where x = 0, y = -1, z is arbitrary. - Michael Somos, Nov 27 2019

Examples

			G.f. = x - x^3 + x^5 - x^7 + x^9 - x^11 + x^13 - x^15 + x^17 - x^19 + x^21 + ...
		

References

  • T. M. Apostol, Introduction to Analytic Number Theory, Springer-Verlag, 1986, page 139, k=4, Chi_2(n).
  • G. H. Hardy and E. M. Wright, An Introduction to the Theory of Numbers. 5th ed., Oxford Univ. Press, 1979, p. 241.

Crossrefs

Kronecker symbols {(d/n)} where d is a fundamental discriminant with |d| <= 24: A109017 (d=-24), A011586 (d=-23), A289741 (d=-20), A011585 (d=-19), A316569 (d=-15), A011582 (d=-11), A188510 (d=-8), A175629 (d=-7), this sequence (d=-4), A102283 (d=-3), A080891 (d=5), A091337 (d=8), A110161 (d=12), A011583 (d=13), A011584 (d=17), A322829 (d=21), A322796 (d=24).

Programs

  • GAP
    a := [1, 0];; for n in [3..10^2] do a[n] := a[n-2]; od; a; # Muniru A Asiru, Feb 02 2018
    
  • Magma
    m:=75; R:=PowerSeriesRing(Integers(), m); Coefficients(R!(x/(1+x^2))); // G. C. Greubel, Aug 23 2018
    
  • Maple
    a := n -> `if`(n mod 2=0, 0, (-1)^((n-1)/2)):
    seq(a(n), n=1..10^3); # Muniru A Asiru, Feb 02 2018
  • Mathematica
    a[ n_] := {1, 0, -1, 0}[[ Mod[ n, 4, 1]]]; (* Michael Somos, Jan 13 2014 *)
    LinearRecurrence[{0, -1}, {1, 0}, 75] (* G. C. Greubel, Aug 23 2018 *)
  • PARI
    {a(n) = if( n%2, (-1)^(n\2))}; /* Michael Somos, Sep 02 2005 */
    
  • PARI
    {a(n) = kronecker( -4, n)}; /* Michael Somos, Mar 30 2012 */
    
  • Python
    def A101455(n): return (0,1,0,-1)[n&3] # Chai Wah Wu, Jun 21 2024

Formula

Multiplicative with a(2^e) = 0, a(p^e) = (-1)^((p^e-1)/2) otherwise. - Mitch Harris May 17 2005
Euler transform of length 4 sequence [0, -1, 0, 1]. - Michael Somos, Sep 02 2005
G.f.: (x - x^3)/(1 - x^4) = x/(1 + x^2). - Michael Somos, Sep 02 2005
G.f. A(x) satisfies: 0 = f(A(x), A(x^2)) where f(u, v) = v - u^2 * (1 + 2*v). - Michael Somos, Aug 04 2011
a(n + 4) = a(n), a(n + 2) = a(-n) = -a(n), a(2*n) = 0, a(2*n + 1) = (-1)^n for all n in Z. - Michael Somos, Aug 04 2011
a(n + 1) = A056594(n). - Michael Somos, Jan 13 2014
REVERT transform is A126120. STIRLING transform of A009454. BINOMIAL transform is A146559. BINOMIAL transform of A009116. BIN1 transform is A108520. MOBIUS transform of A002654. EULER transform is A111335. - Michael Somos, Mar 30 2012
Completely multiplicative with a(p) = 2 - (p mod 4). - Werner Schulte, Feb 01 2018
a(n) = (-(n mod 2))^binomial(n, 2). - Peter Luschny, Sep 08 2018
a(n) = sin(n*Pi/2) = Im(i^n) where i is the imaginary unit. - Jianing Song, Sep 09 2018
From Jianing Song, Nov 14 2018: (Start)
a(n) = ((-4)/n) (or more generally, ((-4^i)/n) for i > 0), where (k/n) is the Kronecker symbol.
E.g.f.: sin(x).
Dirichlet g.f. is the Dirichlet beta function.
a(n) = A091337(n)*A188510(n). (End)

Extensions

a(0) prepended by Jianing Song, Nov 14 2024

A091337 a(n) = (2/n), where (k/n) is the Kronecker symbol.

Original entry on oeis.org

0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1
Offset: 0

Views

Author

Eric W. Weisstein, Dec 30 2003

Keywords

Comments

Sinh(1) in 'reflected factorial' base is 1.01010101010101010101010101010101010101010101... see A073097 for cosh(1). - Robert G. Wilson v, May 04 2005
A non-principal character for the Dirichlet L-series modulo 8, see arXiv:1008.2547 and L-values Sum_{n >= 1} a(n)/n^s in eq (318) by Jolley. - R. J. Mathar, Oct 06 2011 [The other two non-principal characters are A101455 = {(-4/n)} and A188510 = {(-2/n)}. - Jianing Song, Nov 14 2024]
Period 8: repeat [0, 1, 0, -1, 0, -1, 0, 1]. - Wesley Ivan Hurt, Sep 07 2015 [Adapted by Jianing Song, Nov 14 2024 to include a(0) = 0.]
a(n) = (2^(2i+1)/n), where (k/n) is the Kronecker symbol and i >= 0. - A.H.M. Smeets, Jan 23 2018

Examples

			G.f. = x - x^3 - x^5 + x^7 + x^9 - x^11 - x^13 + x^15 + x^17 - x^19 - x^21 + ...
		

References

  • L. B. W. Jolley, Summation of series, Dover (1961).

Crossrefs

Kronecker symbols {(d/n)} where d is a fundamental discriminant with |d| <= 24: A109017 (d=-24), A011586 (d=-23), A289741 (d=-20), A011585 (d=-19), A316569 (d=-15), A011582 (d=-11), A188510 (d=-8), A175629 (d=-7), A101455 (d=-4), A102283 (d=-3), A080891 (d=5), this sequence (d=8), A110161 (d=12), A011583 (d=13), A011584 (d=17), A322829 (d=21), A322796 (d=24).

Programs

  • Magma
    [(n mod 2) * (-1)^((n+1) div 4)  : n in [1..100]]; // Vincenzo Librandi, Oct 31 2014
  • Maple
    A091337:= n -> [0, 1, 0, -1, 0, -1, 0, 1][(n mod 8)+1]: seq(A091337(n), n=1..100); # Wesley Ivan Hurt, Sep 07 2015
  • Mathematica
    KroneckerSymbol[Range[100], 2] (* Alonso del Arte, Oct 30 2014 *)
  • PARI
    {a(n) = (n%2) * (-1)^((n+1)\4)}; /* Michael Somos, Sep 10 2005 */
    
  • PARI
    {a(n) = kronecker( 2, n)}; /* Michael Somos, Sep 10 2005 */
    
  • PARI
    {a(n) = [0, 1, 0, -1, 0, -1, 0, 1][n%8 + 1]}; /* Michael Somos, Jul 17 2009 */
    

Formula

Euler transform of length 8 sequence [0, -1, 0, -1, 0, 0, 0, 1]. - Michael Somos, Jul 17 2009
a(n) is multiplicative with a(2^e) = 0^e, a(p^e) = 1 if p == 1, 7 (mod 8), a(p^e) = (-1)^e if p == 3, 5 (mod 8). - Michael Somos, Jul 17 2009
G.f.: x*(1 - x^2)/(1 + x^4). a(n) = -a(n + 4) = a(-n) for all n in Z. a(2*n) = 0. a(2*n + 1) = A087960(n). - Michael Somos, Apr 10 2011
Transform of Pell numbers A000129 by the Riordan array A102587. - Paul Barry, Jul 14 2005
a(n) = (2/n) = (n/2), Charles R Greathouse IV explained. - Alonso del Arte, Oct 31 2014
a(n) = (1 - (-1)^n)*(-1)^(n/4 - 1/8 - (-1)^n/8 + (-1)^((2*n + 1 - (-1)^n)/4)/4)/2. - Wesley Ivan Hurt, Sep 07 2015
From Jianing Song, Nov 14 2018: (Start)
a(n) = sqrt(2)*sin(Pi*n/2)*sin(Pi*n/4).
E.g.f.: sqrt(2)*cos(x/sqrt(2))*sinh(x/sqrt(2)).
Moebius transform of A035185.
a(n) = A101455(n)*A188510(n). (End)
a(n) = Sum_{i=1..n} (-1)^(i + floor((i-3)/4)). - Wesley Ivan Hurt, Apr 27 2020
Sum_{n>=1} a(n)/n = A196525. Sum_{n>=1} a(n)/n^2 = A328895. Sum_{n>=1} a(n)/n^3 = A329715. Sum_{n>=1} a(n)/n^4 = A346728. - R. J. Mathar, Dec 17 2024

Extensions

a(0) prepended by Jianing Song, Nov 14 2024

A289741 a(n) = Kronecker symbol (-20/n).

Original entry on oeis.org

0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, -1, 0, -1, 0, 0, 0, -1, 0, -1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, -1, 0, -1, 0, 0, 0, -1, 0, -1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, -1, 0, -1, 0, 0, 0, -1, 0, -1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, -1, 0, -1, 0, 0, 0, -1, 0, -1, 0
Offset: 0

Views

Author

Jianing Song, Dec 27 2018

Keywords

Comments

Period 20: repeat [0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, -1, 0, -1, 0, 0, 0, -1, 0, -1].
This sequence is one of the three non-principal real Dirichlet characters modulo 20. The other two are Jacobi or Kronecker symbols {(20/n)} (or {(n/20)}) and {((-100)/n)} (A185276).
Note that (Sum_{i=0..19} i*a(i))/(-20) = 2 gives the class number of the imaginary quadratic field Q(sqrt(-5)). The fact Q(sqrt(-5)) has class number 2 implies that Q(sqrt(-5)) is not a unique factorization domain.

Crossrefs

Cf. A035170 (inverse Moebius transform).
Kronecker symbols {(d/n)} where d is a fundamental discriminant with |d| <= 24: A109017 (d=-24), A011586 (d=-23), this sequence (d=-20), A011585 (d=-19), A316569 (d=-15), A011582 (d=-11), A188510 (d=-8), A175629 (d=-7), A101455 (d=-4), A102283 (d=-3), A080891 (d=5), A091337 (d=8), A110161 (d=12), A011583 (d=13), A011584 (d=17), A322829 (d=21), A322796 (d=24).

Programs

  • Mathematica
    Array[KroneckerSymbol[-20, #]&, 100, 0] (* Amiram Eldar, Jan 10 2019 *)
  • PARI
    a(n) = kronecker(-20, n)

Formula

a(n) = 1 for n in A045797; -1 for n in A045798; 0 for n that are not coprime with 20.
Completely multiplicative with a(p) = a(p mod 20) for primes p.
a(n) = A080891(n)*A101455(n).
a(n) = -a(n+10) = -a(-n) for all n in Z.
Multiplicative with a(2) = a(5) = 0, a(p) = (-1)^floor(p/10) otherwise; equivalently: a(n) = (-1)^floor(n/10) if n is coprime to 2*5, 0 otherwise. - M. F. Hasler, Feb 28 2022

A322796 a(n) = Kronecker symbol (6/n).

Original entry on oeis.org

0, 1, 0, 0, 0, 1, 0, -1, 0, 0, 0, -1, 0, -1, 0, 0, 0, -1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, -1, 0, 0, 0, -1, 0, -1, 0, 0, 0, -1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, -1, 0, 0, 0, -1, 0, -1, 0, 0, 0, -1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, -1, 0, 0, 0, -1, 0
Offset: 0

Views

Author

Jianing Song, Dec 26 2018

Keywords

Comments

Period 24: repeat [0, 1, 0, 0, 0, 1, 0, -1, 0, 0, 0, -1, 0, -1, 0, 0, 0, -1, 0, 1, 0, 0, 0, 1].
Also a(n) = Kronecker symbol (24/n).
This sequence is one of the seven non-principal real Dirichlet characters modulo 24. The other six are Jacobi or Kronecker symbols {(-6/n)} (or {(n/6)}, {(-24/n)}, {(n/24)}, A109017), {(-12/n)} (or {(n/12)}, A134667), {(12/n)} (A110161), {(-18/n)} (or {(-72/n)}), {(18/n)} (or {(72/n)}, {(n/72)}) and {(-36/n)}. These sequences all become the same after taking absolute values.

Crossrefs

Cf. A035188 (inverse Moebius transform).
Kronecker symbols {(d/n)} where d is a fundamental discriminant with |d| <= 24: A109017 (d=-24), A011586 (d=-23), A289741 (d=-20), A011585 (d=-19), A316569 (d=-15), A011582 (d=-11), A188510 (d=-8), A175629 (d=-7), A101455 (d=-4), A102283 (d=-3), A080891 (d=5), A091337 (d=8), A110161 (d=12), A011583 (d=13), A011584 (d=17), A322829 (d=21), this sequence (d=24).

Programs

  • Magma
    [KroneckerSymbol(6, n): n in [0..100]]; // Vincenzo Librandi, Jan 01 2019
  • Mathematica
    Array[KroneckerSymbol[6, #] &, 105, 0] (* Michael De Vlieger, Dec 31 2018 *)
    Table[KroneckerSymbol[6, n], {n, 0, 100}] (* Vincenzo Librandi, Jan 01 2019 *)
  • PARI
    a(n) = kronecker(6, n); \\ --- Argument order corrected by Antti Karttunen, Sep 27 2019
    

Formula

a(n) = 1 for n == 1, 5, 19, 23 (mod 24); -1 for n == 7, 11, 13, 17 (mod 24); 0 for n that are not coprime with 21.
Completely multiplicative with a(p) = a(p mod 24) for primes p.
a(n) = A091337(n)*A102283(n).
a(n) = A109017(n+12) = A109017(n-12).
a(n) = a(-n) = a(n+24) for all n in Z.

Extensions

Definition corrected by Antti Karttunen, Sep 28 2019

A322829 a(n) = Jacobi (or Kronecker) symbol (n/21).

Original entry on oeis.org

0, 1, -1, 0, 1, 1, 0, 0, -1, 0, -1, -1, 0, -1, 0, 0, 1, 1, 0, -1, 1, 0, 1, -1, 0, 1, 1, 0, 0, -1, 0, -1, -1, 0, -1, 0, 0, 1, 1, 0, -1, 1, 0, 1, -1, 0, 1, 1, 0, 0, -1, 0, -1, -1, 0, -1, 0, 0, 1, 1, 0, -1, 1, 0, 1, -1, 0, 1, 1, 0, 0, -1, 0, -1, -1, 0, -1, 0, 0, 1, 1, 0, -1, 1, 0
Offset: 0

Views

Author

Jianing Song, Dec 27 2018

Keywords

Comments

Period 21: repeat [0, 1, -1, 0, 1, 1, 0, 0, -1, 0, -1, -1, 0, -1, 0, 0, 1, 1, 0, -1, 1].
Also a(n) = Kronecker symbol (21/n).
This sequence is one of the three non-principal real Dirichlet characters modulo 21. The other two are Jacobi or Kronecker symbols {(n/63)} (or {(-63/n)}) and {(n/147)} (or {(-147/n)}).

Crossrefs

Cf. A035203 (inverse Moebius transform).
Kronecker symbols {(d/n)} where d is a fundamental discriminant with |d| <= 24: A109017(d=-24), A011586 (d=-23), A289741 (d=-20), A011585 (d=-19), A316569 (d=-15), A011582 (d=-11), A188510 (d=-8), A175629 (d=-7), A101455 (d=-4), A102283 (d=-3), A080891 (d=5), A091337 (d=8), A110161 (d=12), A011583 (d=13), A011584 (d=17), this sequence (d=21), A322796 (d=24).

Programs

  • Mathematica
    JacobiSymbol[Range[0, 100], 21] (* Paolo Xausa, Mar 19 2025 *)
  • PARI
    a(n) = kronecker(n, 21)

Formula

a(n) = 1 for n == 1, 4, 5, 16, 17, 20 (mod 21); -1 for n == 2, 8, 10, 11, 13, 19 (mod 21); 0 for n that are not coprime with 21.
Completely multiplicative with a(p) = a(p mod 21) for primes p.
a(n) = A102283(n)*A175629(n).
a(n) = a(n+21) = -a(n) for all n in Z.
From Chai Wah Wu, Feb 18 2021: (Start)
a(n) = a(n-1) - a(n-3) + a(n-4) - a(n-6) + a(n-8) - a(n-9) + a(n-11) - a(n-12) for n > 11.
G.f.: -x*(x - 1)*(x + 1)*(x^8 - 2*x^7 + 2*x^6 + 2*x^2 - 2*x + 1)/(x^12 - x^11 + x^9 - x^8 + x^6 - x^4 + x^3 - x + 1). (End)

A296938 Rational primes that decompose in the field Q(sqrt(17)).

Original entry on oeis.org

2, 13, 19, 43, 47, 53, 59, 67, 83, 89, 101, 103, 127, 137, 149, 151, 157, 179, 191, 223, 229, 239, 251, 257, 263, 271, 281, 293, 307, 331, 349, 353, 359, 373, 383, 389, 409, 421, 433, 443, 457, 461, 463, 467, 491, 509, 523, 557, 563, 569, 577, 587, 593, 599
Offset: 1

Views

Author

N. J. A. Sloane, Dec 26 2017

Keywords

Comments

From Jianing Song, Apr 21 2022: (Start)
Primes p such that kronecker(17, p) = kronecker(p, 17) = 1, where kronecker() is the kronecker symbol. That is to say, primes p that are quadratic residues modulo 17.
Primes p such that p^8 == 1 (mod 17).
Primes p == 1, 2, 4, 8, 9, 13, 15, 16 (mod 17). (End)

Crossrefs

Cf. A011584 (kronecker symbol modulo 17).
Rational primes that decompose in the quadratic field with discriminant D: A139513 (D=-20), A191019 (D=-19), A191018 (D=-15), A296920 (D=-11), A033200 (D=-8), A045386 (D=-7), A002144 (D=-4), A002476 (D=-3), A045468 (D=5), A001132 (D=8), A097933 (D=12), A296937 (D=13), this sequence (D=17).
Cf. A038890 (inert rational primes in the field Q(sqrt(17))).

Programs

Showing 1-6 of 6 results.