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!)
A087080 Number of elements in the coprime subsets of the integers 1 to n. 4

%I #12 Oct 20 2020 08:20:40

%S 0,1,4,12,20,52,60,148,196,300,332,780,828,1904,2080,2348,2812,6352,

%T 6608,14736,15632,17456,18640,41152,42432,60912,64800,80928,85408,

%U 186304,187584,406400,457344,497472,523456,585280,596288,1284224,1348032,1457792,1495424

%N Number of elements in the coprime subsets of the integers 1 to n.

%C A coprime set of integers has (m,n)=1 for each pair of integers in the set.

%D Alan Sutcliffe, Divisors and Common Factors in Sets of Integers, awaiting publication.

%H Fausto A. C. Cariboni, <a href="/A087080/b087080.txt">Table of n, a(n) for n = 0..120</a>

%e a(4)=20 since the 12 coprime subsets of (1,2,3,4) are ( ) (1) (2) (3) (4) (1,2) (1,3) (1,4) (2,3) (3,4) (1,2,3) (1,3 4) and these contain 20 elements.

%o (PARI) iscoprime(v) = {local(i); for (i=1, #v-1, for (j=i+1, #v, if (gcd(v[i], v[j]) != 1, return (0)););); return (1);}

%o a(n) = {sn = vector(n, i, i); pset = vector(1<<#sn, i, vecextract(sn, i-1)); nb = 0; for (i=1, #pset, if (iscoprime(pset[i]), nb += #pset[i]);); return (nb);} \\ _Michel Marcus_, Jul 12 2013

%Y A087077 gives the number of elements in the primitive subsets. A084422 gives the number coprime subsets. A087081 gives the sum of the elements in coprime subsets.

%K nonn

%O 0,3

%A Alan Sutcliffe (alansut(AT)ntlworld.com), Aug 12 2003

%E Terms a(38) and beyond from _Fausto A. C. Cariboni_, Oct 20 2020

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 23 03:30 EDT 2024. Contains 371906 sequences. (Running on oeis4.)