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-9 of 9 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

A045798 Oddish numbers (prime to 10 and 10's digit is odd).

Original entry on oeis.org

11, 13, 17, 19, 31, 33, 37, 39, 51, 53, 57, 59, 71, 73, 77, 79, 91, 93, 97, 99, 111, 113, 117, 119, 131, 133, 137, 139, 151, 153, 157, 159, 171, 173, 177, 179, 191, 193, 197, 199, 211, 213, 217, 219, 231, 233, 237, 239, 251, 253, 257, 259
Offset: 1

Views

Author

Keywords

Comments

From Jianing Song, Apr 27 2019: (Start)
Numbers congruent to {11, 13, 17, 19} mod 20.
Numbers k such that Kronecker(-20,k) = A289741(k) = -1. (End)

Crossrefs

Complement of A045797 with respect to A045572.

Programs

  • Haskell
    a045798 n = a045798_list !! (n-1)
    a045798_list = filter (odd . (`mod` 10) . (`div` 10)) a045572_list
    -- Reinhard Zumkeller, Dec 10 2011
    
  • Maple
    seq(seq(20*j + k, k = [11, 13, 17, 19]),j=0..100); # Robert Israel, Mar 27 2017
  • Mathematica
    Table[10n+{1,3,7,9},{n,1,31,2}]//Flatten (* Harvey P. Dale, Oct 01 2019 *)
  • PARI
    is(n)=gcd(n,10)==1 && n\10%2 \\ Charles R Greathouse IV, Feb 07 2017

Formula

Conjecture a(n) = a(n-1)+a(n-4)-a(n-5). G.f.: x*(11+2*x+4*x^2+2*x^3+x^4)/((1-x)^2*(1+x)*(1+x^2)). - Colin Barker, Apr 14 2012
a(n) = 5n + O(1). - Charles R Greathouse IV, Feb 07 2017
a(n+4) = a(n) + 20. This confirms Barker's conjecture. - Robert Israel, Mar 27 2017

Extensions

More terms from Erich Friedman.

A045797 Evenish numbers (prime to 10 and 10's digit is even).

Original entry on oeis.org

1, 3, 7, 9, 21, 23, 27, 29, 41, 43, 47, 49, 61, 63, 67, 69, 81, 83, 87, 89, 101, 103, 107, 109, 121, 123, 127, 129, 141, 143, 147, 149, 161, 163, 167, 169, 181, 183, 187, 189, 201, 203, 207, 209, 221, 223, 227, 229, 241, 243, 247, 249, 261, 263, 267, 269, 281
Offset: 1

Views

Author

Keywords

Comments

From Jianing Song, Apr 27 2019: (Start)
Numbers congruent to {1, 3, 7, 9} mod 20.
Numbers k such that Kronecker(-20,k) = A289741(k) = +1. (End)
First 20 terms are congruences of 3^k mod 100. - Dario Vuksan, Jan 09 2023

Crossrefs

Complement of A045798 with respect to A045572.

Programs

  • Haskell
    a045797 n = a045797_list !! (n-1)
    a045797_list = filter (even . (`mod` 10) . (`div` 10)) a045572_list
    -- Reinhard Zumkeller, Dec 10 2011
    
  • Mathematica
    Flatten[Table[10n+{1,3,7,9},{n,0,30,2}]] (* Harvey P. Dale, Dec 05 2012 *)
  • PARI
    is(n)=gcd(n,10)==1 && n\10%2==0 \\ Charles R Greathouse IV, Sep 24 2015

Formula

Conjecture a(n) = a(n-1)+a(n-4)-a(n-5). G.f.: x*(1+2*x+4*x^2+2*x^3+11*x^4) / ((1-x)^2*(1+x)*(1+x^2)). - Colin Barker, Apr 14 2012
The conjecture above is correct. - Jianing Song, Apr 27 2019
a(n) = 5n + O(1). - Charles R Greathouse IV, Jan 09 2023

Extensions

More terms from Erich Friedman
Offset changed by Reinhard Zumkeller, Dec 10 2011

A091727 Norms of prime ideals of Z[sqrt(-5)].

Original entry on oeis.org

2, 3, 5, 7, 23, 29, 41, 43, 47, 61, 67, 83, 89, 101, 103, 107, 109, 121, 127, 149, 163, 167, 169, 181, 223, 227, 229, 241, 263, 269, 281, 283, 289, 307, 347, 349, 361, 367, 383, 389, 401, 409, 421, 443, 449, 461, 463, 467, 487
Offset: 1

Views

Author

Paul Boddington, Feb 02 2004

Keywords

Comments

Consists of primes congruent to 1, 2, 3, 5, 7, 9 (mod 20) together with the squares of all other primes.
From Jianing Song, Feb 20 2021: (Start)
The norm of a nonzero ideal I in a ring R is defined as the size of the quotient ring R/I.
Note that Z[sqrt(-5)] has class number 2.
For primes p == 1, 9 (mod 20), there are two distinct ideals with norm p in Z[sqrt(-5)], namely (x + y*sqrt(-5)) and (x - y*sqrt(-5)), where (x,y) is a solution to x^2 + 5*y^2 = p.
For p == 3, 7 (mod 20), there are also two distinct ideals with norm p, namely (p, x+y*sqrt(-5)) and (p, x-y*sqrt(-5)), where (x,y) is a solution to x^2 + 5*y^2 = p^2 with y != 0; (2, 1+sqrt(-5)) and (sqrt(-5)) are respectively the unique ideal with norm 2 and 5.
For p == 11, 13, 17, 19 (mod 20), (p) is the only ideal with norm p^2. (End)

Examples

			From _Jianing Song_, Feb 20 2021: (Start)
Let |I| be the norm of an ideal I, then:
|(2, 1+sqrt(-5))| = 2;
|(3, 2+sqrt(-5))| = |(3, 2-sqrt(-5))| = 3;
|(sqrt(-5))| = 5;
|(7, 1+3*sqrt(-5))| = |(7, 1-3*sqrt(-5))| = 7;
|(23, 22+3*sqrt(-5))| = |(23, 22-3*sqrt(-5))| = 23;
|(3 + 2*sqrt(-5))| = |(3 - 2*sqrt(-5))| = 29;
|(6 + sqrt(-5))| = |(6 - sqrt(-5))| = 41. (End)
		

References

  • David A. Cox, Primes of the form x^2+ny^2, Wiley, 1989.
  • A. Frohlich and M. J. Taylor, Algebraic number theory, Cambridge university press, 1991.

Crossrefs

Cf. A091728.
The number of distinct ideals with norm n is given by A035170.
Norms of prime ideals in O_K, where K is the quadratic field with discriminant D and O_K be the ring of integers of K: A055673 (D=8), A341783 (D=5), A055664 (D=-3), A055025 (D=-4), A090348 (D=-7), A341784 (D=-8), A341785 (D=-11), A341786 (D=-15*), A341787 (D=-19), this sequence (D=-20*), A341788 (D=-43), A341789 (D=-67), A341790 (D=-163). Here a "*" indicates the cases where O_K is not a unique factorization domain.

Programs

  • PARI
    isA091727(n) = { my(ms = [1, 2, 3, 5, 7, 9], p, e=isprimepower(n,&p)); if(!e || e>2, 0, bitxor(e-1,!!vecsearch(ms,p%20))); }; \\ Antti Karttunen, Feb 24 2020

Extensions

Offset corrected by Jianing Song, Feb 20 2021

A114643 Number of real primitive Dirichlet characters modulo n.

Original entry on oeis.org

1, 0, 1, 1, 1, 0, 1, 2, 0, 0, 1, 1, 1, 0, 1, 0, 1, 0, 1, 1, 1, 0, 1, 2, 0, 0, 0, 1, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 2, 1, 0, 1, 1, 0, 0, 1, 0, 0, 0, 1, 1, 1, 0, 1, 2, 1, 0, 1, 1, 1, 0, 0, 0, 1, 0, 1, 1, 1, 0, 1, 0, 1, 0, 0, 1, 1, 0, 1, 0, 0, 0, 1, 1, 1, 0, 1, 2, 1, 0, 1, 1, 1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 2, 1
Offset: 1

Views

Author

Steven Finch, Feb 16 2006

Keywords

Comments

a(n) = 1 if either n or -n is a fundamental discriminant (not both); a(n) = 2 if n and -n are fundamental discriminants; a(n) = 0 otherwise. Also, Sum_{k=1..n} a(k) is asymptotic to (6/Pi^2)*n.
From Jianing Song, Feb 27 2019: (Start)
If n is an odd squarefree number, then a(n) = 1, where the unique real primitive Dirichlet character modulo n is {Kronecker(n,k)} = {Jacobi(k,n)} if n == 1 (mod 4) and {Kronecker(-n,k)} = {Jacobi(k,n)} if n == 3 (mod 4).
If n = 4*m, m is an odd squarefree number, then a(n) is also 1, where the unique real primitive Dirichlet character modulo n is {Kronecker(-n,k)} if m == 1 (mod 4) and {Kronecker(n,k)} if m == 3 (mod 4).
If n is 8 times an odd squarefree number, then a(n) = 2, where the two real primitive Dirichlet characters modulo n are {Kronecker(n,k)} and {Kronecker(-n,k)}.
a(n) = 0 if n == 2 (mod 4), n is divisible by 16 or the square of an odd prime. (End)
Mobius transform of A060594. - Jianing Song, Mar 02 2019

Examples

			From _Jianing Song_, Feb 27 2019: (Start)
For n = 5, the only real primitive Dirichlet characters modulo n is {Kronecker(5,k)} = [0, 1, -1, -1, 1] = A080891, so a(5) = 1.
For n = 8, the real primitive Dirichlet characters modulo n are {Kronecker(8,k)} = [0, 1, 0, -1, 0, -1, 0, 1] = A091337 and [0, 1, 0, 1, 0, -1, 0, -1] = A188510, so a(8) = 2.
For n = 20, the only real primitive Dirichlet characters modulo n is {Kronecker(-20,k)} = [0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, -1, 0, -1, 0, 0, 0, -1, 0, -1] = A289741, so a(20) = 1. (End)
		

References

  • W. Ellison and F. Ellison, Prime Numbers, Wiley, 1985, pp. 224-226.

Crossrefs

Cf. A160498 (number of cubic primitive Dirichlet characters modulo n), A160499 (number of quartic primitive Dirichlet characters modulo n).
Cf. A060594 (number of solutions to x^2 == 1 (mod n)).

Programs

  • Maple
    A114643 := proc(n)
        local a,pf,p,r;
        a := 1 ;
        for pf in ifactors(n)[2] do
            p := op(1,pf);
            r := op(2,pf);
            if p = 2 then
                if r =  1 then
                    a := 0 ;
                elif r =  2 then
                    ;
                elif r =  3 then
                    a := a*2 ;
                elif r >=  4 then
                    a := 0 ;
                end if;
            else
                if r =1 then
                    ;
                else
                    a := 0 ;
                end if;
            end if;
        end do:
        a ;
    end proc:
    seq(A114643(n),n=1..40) ; # R. J. Mathar, Mar 02 2015
    # Alternative:
    f:= proc(n) local r,v,F;
      v:= padic:-ordp(n,2);
      if v = 1 or v >= 4 then return 0
      elif v = 3 then r:= 2
      else r:= 1
      fi;
      if numtheory:-issqrfree(n/2^v) then r else 0 fi
    end proc:
    map(f, [$1..100]); # Robert Israel, Oct 08 2017
  • Mathematica
    a[n_] := Sum[ MoebiusMu[n/d] * Sum[ If[ Mod[i^2 - 1, d] == 0, 1, 0], {i, 2, d}], {d, Divisors[n]}]; a[1] = 1; Table[a[n], {n, 1, 105}] (* Jean-François Alcover, Jun 20 2013, after Steven Finch *)
    f[2, e_] := Which[e == 1, 0, e == 2, 1, e == 3, 2, e >= 4, 0]; f[p_, e_] := If[e == 1, 1, 0]; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* Amiram Eldar, Sep 16 2020 *)
  • PARI
    a(n)=sum(d=1, n, if(n%d==0, moebius(n/d)*sum(i=1, d, if((i^2-1)%d, 0, 1)), 0)) \\ Steven Finch, Jun 09 2009

Formula

This sequence is multiplicative with a(2) = 0, a(4) = 1, a(8) = 2, a(2^r) = 0 for r > 3, a(p) = 1 for prime p > 2 and a(p^r) = 0 for r > 1. - Steven Finch, Mar 08 2006 (With correction by Jianing Song, Jun 28 2018)
Dirichlet g.f.: zeta(s)*(1 + 2^(-2s) + 2^(1-3s))/(zeta(2s)*(1 + 2^(-s))). - R. J. Mathar, Jul 03 2011

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)

A185276 Kronecker symbol (-100 / 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, 1, 0, -1, 0, 0, 0, -1, 0, 1, 0, -1, 0, 1, 0, 0, 0, 1, 0, -1, 0
Offset: 0

Views

Author

Michael Somos, Feb 19 2011

Keywords

Comments

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 A289741 = {(-20/n)}. - Jianing Song, Nov 14 2024

Examples

			x - x^3 - x^7 + x^9 - x^11 + x^13 + x^17 - x^19 + x^21 - x^23 - x^27 + ...
		

Crossrefs

Programs

  • Mathematica
    f[n_] := KroneckerSymbol[-100, n]; Array[f, 100] (* Robert G. Wilson v *)
  • PARI
    {a(n) = kronecker( -100, n)}
    
  • PARI
    {a(n) = (n%2) * (-1) ^ (n\10) * kronecker( 5, n)}
    
  • PARI
    {a(n) = sign(n) * polcoeff( x * (1 - x^2) * (1 - x^6) / (1 + x^10) + x * O(x^abs(n)), abs(n))}
    
  • PARI
    {a(n) = local( A, p, e); if( n==0, 0, A = factor( abs(n)); sign(n) * prod( k=1, matsize( A)[1], if(p = A[k, 1], e = A[k, 2]; if( p==2 || p==5, 0, if( p%4==1, 1, (-1)^e )))))}

Formula

a(n) is multiplicative with a(2^e) = a(5^e) = 0^e, a(p^e) = 1 if p == 1 (mod 4) and p>5, a(p^e) = (-1)^e if p == 3 (mod 4).
Euler transform of length 20 sequence [ 0, -1, 0, 0, 0, -1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1].
G.f.: x * (1 - x^2) * (1 - x^6) / (1 + x^10) = x / (1 + x^2) - x^5 / (1 + x^10).
a(n + 20) = -a(-n) = a(n). a(2*n) = a(5*n) = 0.
Dirichlet convolution with A000012 is A053694 offset 1.
Sum_{k=1..n} abs(a(k)) ~ 2*n/5. - Amiram Eldar, Jan 29 2024

Extensions

a(0) prepended by Jianing Song, Nov 14 2024
Showing 1-9 of 9 results.