OFFSET
1,2
LINKS
Alois P. Heinz, Table of n, a(n) for n = 1..220
FORMULA
EXAMPLE
a(4) = 11 because there are 11 nonempty subsets of {1,2,3,4} having pairwise coprime elements: {1}, {2}, {3}, {4}, {1,2}, {1,3}, {1,4}, {2,3}, {3,4}, {1,2,3}, {1,3,4}.
PROG
(PARI) f(n, k=1)=if(n==1, return(2)); if(gcd(k, n)==1, f(n-1, n*k)) + f(n-1, k)
a(n)=f(n)-1 \\ Charles R Greathouse IV, Aug 24 2016
CROSSREFS
KEYWORD
nonn
AUTHOR
Alois P. Heinz, Mar 06 2011
STATUS
approved