Logo

Greetings from The On-Line Encyclopedia of Integer Sequences!

Hints

Search: id:A071553
Displaying 1-1 of 1 results found. page 1
     Format: long | short | internal | text      Sort: relevance | references | number      Highlight: on | off
A071553 Least x greater than 1 such that x^n == 1 (mod i) for each i=1,2,3,...,n. +0
1
2, 3, 7, 5, 61, 11, 421, 13, 121, 71, 27721, 23, 360361, 4159, 841, 307, 12252241, 1121, 232792561, 2393, 4398241, 483209, 5354228881, 4093, 1460244241, 11232649, 61934401, 7598557, 2329089562801, 406639, 72201776446801, 6998993 (list; graph; listen)
OFFSET

1,1

COMMENT

Let m(n) = A003418(n) = LCM(1,2,...,n). Then a(n) <= m(n)+1, with equality if and only if n=1 or n is prime. - David W. Wilson, Vladeta Jovovic, Dean Hickerson.

MATHEMATICA

<<NumberTheory`NumberTheoryFunctions` (* Load ChineseRemainder function, needed below. *)

f[n_, m_] := Select[Range[0, m-1], PowerMod[ #, n, m]==1&]; a[1]=2; a[n_] := Module[{lcm, pe, i, m, s, j, x}, lcm=LCM@@Range[n]; pe=Sort[Select[Range[n], Length[FactorInteger[ # ]]==1&&#*FactorInteger[ # ][[1, 1]]>n&], Length[f[n, #1]]/#1<Length[f[n, #2]]/#2&]; For[i=1; m=1; s={0}, i<=Length[pe], i++, s=Union@@Outer[ChineseRemainder[{#1, #2}, {m, pe[[i]]}]&, s, f[n, pe[[i]]]]; m*=pe[[i]]; For[j=2, j<=Length[s], j++, If[PowerMod[x=s[[j]], n, lcm]==1, Return[x]]]; If[PowerMod[1+m, n, lcm]==1, Return[1+m]]; ]]; (* f[n, m] is list of x with x^n==1 (mod m), 0 <= x < m *)

PROGRAM

(PARI) for(n=1, 12, s=2; while(sum(i=1, n, sign((s^n-1)%i))>0, s++); print1(s, ", "))

CROSSREFS

Sequence in context: A069587 A059843 A092927 this_sequence A021812 A155891 A069772

Adjacent sequences: A071550 A071551 A071552 this_sequence A071554 A071555 A071556

KEYWORD

nonn,nice

AUTHOR

Benoit Cloitre (benoit7848c(AT)orange.fr), May 30 2002

EXTENSIONS

Edited by Robert G. Wilson v (rgwv(AT)rgwv.com), Jun 07 2002

More terms from Don Reble (djr(AT)nk.ca), Jun 07 2002

Corrected and extended by Vladeta Jovovic (vladeta(AT)eunet.rs), Jun 09 2002

Corrected and extended by Dean Hickerson (dean.hickerson(AT)yahoo.com), Jun 13 2002

page 1

Search completed in 0.002 seconds

Lookup | Welcome | Find friends | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
More pages | Superseeker | Maintained by N. J. A. Sloane (njas@research.att.com)

Last modified December 20 16:54 EST 2009. Contains 171081 sequences.


AT&T Labs Research