Logo

Greetings from The On-Line Encyclopedia of Integer Sequences!

Hints

Search: id:A117494
Displaying 1-1 of 1 results found. page 1
     Format: long | short | internal | text      Sort: relevance | references | number      Highlight: on | off
A117494 a(n) = number of m's, 1 <= m <= n, where GCD(m,n) is prime. +0
1
0, 1, 1, 1, 1, 3, 1, 2, 2, 5, 1, 4, 1, 7, 6, 4, 1, 8, 1, 6, 8, 11, 1, 8, 4, 13, 6, 8, 1, 14, 1, 8, 12, 17, 10, 10, 1, 19, 14, 12, 1, 20, 1, 12, 14, 23, 1, 16, 6, 24, 18, 14, 1, 24, 14, 16, 20, 29, 1, 20, 1, 31, 18, 16, 16, 32, 1, 18, 24, 34, 1, 20, 1, 37, 28, 20, 16, 38, 1, 24, 18, 41, 1, 28 (list; graph; listen)
OFFSET

1,6

EXAMPLE

Of the positive integers <= 12, exactly four (2, 3, 9, and 10) have a GCD with 12 that is prime. (GCD(2,12) = 2, GCD(3,12) = 3, GCD(9,12) = 3, GCD(10,12) = 2)

So a(12) = 4.

MAPLE

a:=proc(n) local c, m: c:=0: for m from 1 to n do if isprime(gcd(m, n))=true then c:=c+1 else c:=c fi od: end: seq(a(n), n=1..100); - Emeric Deutsch (deutsch(AT)duke.poly.edu), Apr 01 2006

MATHEMATICA

f[n_] := Length@ Select[GCD[n, Range@n], PrimeQ@ # &]; Array[f, 84] - Robert G. Wilson v (rgwv(at)rgwv.com), Apr 06 2006

CROSSREFS

Sequence in context: A010280 A125266 A002016 this_sequence A057056 A016469 A125061

Adjacent sequences: A117491 A117492 A117493 this_sequence A117495 A117496 A117497

KEYWORD

nonn

AUTHOR

Leroy Quet (qq-quet(AT)mindspring.com), Mar 22 2006

EXTENSIONS

More terms from Emeric Deutsch (deutsch(AT)duke.poly.edu), Apr 01 2006

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 September 6 16:04 EDT 2008. Contains 143483 sequences.


AT&T Labs Research