login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A073111 Number of permutations p of (1,2,3,...,n) such that 1^p(1)+2^p(2)+3^p(3)+...+n^p(n) is prime. 0
0, 2, 0, 0, 35, 211, 0, 0, 56204, 337661, 0, 0, 454113487 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
a(4*k)=a(4*k+3)=0
LINKS
EXAMPLE
For n=3: permutations (1,3,2), (3,1,2), (2,3,1), (2,1,3) are OK since 1^1+2^3+3^2=13, 1^3+2^1+3^2=11, 1^2+2^3+3^1=11 and 1^2+2^1+3^3=13, hence a(3)=4.
For n=2: both permutations (1,2), (2,1) are OK since 1^1+2^2=5 and 1^2+2^1=3; hence a(2)=2.
PROG
(PARI) a(n)=sum(k=1, n!, if(isprime(sum(i=1, n, i^component(numtoperm(n, k), i)))-1, 0, 1))
CROSSREFS
Sequence in context: A288125 A020916 A179072 * A229685 A230469 A004076
KEYWORD
more,nonn
AUTHOR
Benoit Cloitre, Aug 19 2002
EXTENSIONS
a(10) and a(11) from Mohammed Bouayoun (bouyao(AT)wanadoo.fr), Mar 29 2004
a(12)-a(13) from Robert Gerbicz, Nov 27 2010
STATUS
approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 19 10:56 EDT 2024. Contains 371791 sequences. (Running on oeis4.)