OFFSET
1,2
COMMENTS
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
EXAMPLE
The divisors of 84 that are 1 or whose prime indices are relatively prime are {1, 2, 4, 6, 12, 14, 28, 42, 84}, so a(84) = 9.
MAPLE
N:= 100: # for a(1)..a(N)
g:= proc(n) uses numtheory; igcd(op(map(pi, factorset(n))))=1 end proc:
V:= Vector(N, 1):
for k in select(g, [$2..N]) do
R:=[seq(i, i=k..N, k)]:
V[R]:= map(`+`, V[R], 1);
od:
convert(V, list); # Robert Israel, Sep 19 2019
MATHEMATICA
Table[Length[Select[Divisors[n], #==1||GCD@@PrimePi/@First/@FactorInteger[#]==1&]], {n, 100}]
CROSSREFS
KEYWORD
nonn
AUTHOR
Gus Wiseman, Sep 17 2019
STATUS
approved