This site is supported by donations to The OEIS Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A046094 Agoh's congruence; a(n) is conjectured to be 1 iff n is prime. 4
 0, 1, 1, 0, 1, 0, 1, 0, 3, 0, 1, 0, 1, 0, 5, 0, 1, 0, 1, 0, 7, 0, 1, 0, 5, 0, 9, 0, 1, 0, 1, 0, 11, 0, 0, 0, 1, 0, 13, 0, 1, 0, 1, 0, 24, 0, 1, 0, 7, 0, 17, 0, 1, 0, 0, 0, 19, 0, 1, 0, 1, 0, 21, 0, 13, 0, 1, 0, 23, 0, 1, 0, 1, 0, 25, 0, 0, 0, 1, 0, 27, 0, 1, 0, 17, 0, 29, 0, 1, 0, 13, 0, 31, 0, 0, 0, 1, 0 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,9 LINKS Seiichi Manyama, Table of n, a(n) for n = 1..1000 D. Borwein, J. M. Borwein, P. B. Borwein and R. Girgensohn, Giuga's conjecture on primality, The American Mathematical Monthly, Vol. 103, No. 1 (1996), 40-50. Romeo Meštrović, Generalizations of Carmichael numbers I, arXiv:1305.1867v1 [math.NT], May 4, 2013. R. Mestrovic, On a Congruence Modulo n^3 Involving Two Consecutive Sums of Powers, Journal of Integer Sequences, Vol. 17 (2014), 14.8.4. Eric Weisstein's World of Mathematics, Agoh's Conjecture FORMULA a(n) = - n*Bernoulli(n-1) mod n. EXAMPLE - 21 * Bernoulli(20) = 21 * 174611 / 330 = 1222277 / 110  and 1 / 110 == 17 mod 21, so a(21) = 1222277 * 17 mod 21 = 7. - Jonathan Sondow, Aug 13 2013 MATHEMATICA a[ n_ ] := Mod[ Numerator[ -n* BernoulliB[ n-1 ]]*PowerMod[ Denominator[ n*BernoulliB[ n-1 ] ], -1, n ], n ] (* Jonathan Sondow, Aug 13 2013 *) PROG (PARI) a(n) = -n*bernfrac(n-1) % n; \\ Michel Marcus, Aug 08 2017 CROSSREFS Cf. A228037. Sequence in context: A318659 A318513 A323878 * A055976 A293305 A316896 Adjacent sequences:  A046091 A046092 A046093 * A046095 A046096 A046097 KEYWORD nonn AUTHOR EXTENSIONS a(21), a(51), a(57), a(65), a(81) corrected by Jonathan Sondow, Aug 13 2013 STATUS approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

Last modified October 21 01:18 EDT 2019. Contains 328291 sequences. (Running on oeis4.)