cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-3 of 3 results.

A154886 Number of ways to partition n into reduced fractions i/j with j <= n.

Original entry on oeis.org

1, 5, 51, 655, 20980, 578779, 46097340, 2889706132, 485416306983, 68334145684271, 24330218582223815, 3847311627258606534, 2716890193805515507433, 1270766589764097820833691, 2188031110546839992589840986, 1331298554328475793875243619997
Offset: 1

Views

Author

Reinhard Zumkeller, Jan 17 2009

Keywords

Examples

			a(2) = #{2, 3/2+1/2, 1+1, 1+1/2+1/2, 1/2+1/2+1/2+1/2} = 5.
		

Crossrefs

Programs

  • Mathematica
    modifiedFarey[n_] := Union@ Flatten@ Table[a/b, {b, n}, {a, b*n}]; t[n_, k_] := Length@ IntegerPartitions[n, {k}, modifiedFarey@ n]; Plus @@@ Table[t[n, k], {n, 7, 7}, {k, n*(Plus @@ EulerPhi@ Range@n)}] (* Robert G. Wilson v, Aug 30 2010 *)

Extensions

a(7) from Robert G. Wilson v, Aug 30 2010
a(8)-a(16) from Robert Gerbicz, Nov 19 2010

A154888 Number of ways to partition 1 into distinct reduced fractions i/j with j <= n.

Original entry on oeis.org

1, 1, 2, 3, 5, 7, 11, 16, 24, 37, 48, 71, 88, 133, 284, 435, 472, 773, 826, 1835, 4369, 5546, 5649, 9924, 16465, 19944, 32324, 75913, 76168, 140802, 141141, 238514, 537697, 598296, 2556065, 4674085, 4674844, 4985386, 9716587, 23983712, 23984971, 48523606, 48525215
Offset: 1

Views

Author

Reinhard Zumkeller, Jan 18 2009

Keywords

Comments

a(n) = A116084(n) + 1 for all n because the decompositions are the same except for the additional fraction 1/1 allowed here but excluded in A116084. - M. F. Hasler, Jul 14 2016

Examples

			a(6) = #[1, 5/6+1/6, 4/5+1/5, 3/4+1/4, 2/3+1/3, 3/5+2/5, 1/2+1/3+1/6] = 7.
		

Crossrefs

Equals A116084(n) + 1.

Programs

  • Mathematica
    Farey[n_] := Union@ Flatten@ Table[ a/b, {b, n}, {a, b}]; t[n_, k_] := t[n, k] = Block[{c = j = 0, ip = IntegerPartitions[1, {k}, Farey@ n]}, len = 1 + Length@ ip; While[j < len, If[Plus @@ Union@ ip[[j]] == 1, c++ ]; j++ ]; c]; f[n_] := Plus @@ Table[ t[n, k], {k, Ceiling[n/2]}]; Array[f, 24] (* Robert G. Wilson v, Aug 30 2010 *)

Extensions

a(22)-a(26) from Robert G. Wilson v, Aug 30 2010
a(27)-a(34) from Don Reble, Jul 13 2016
a(35)-a(41) from Giovanni Resta, Jul 15 2016
a(42)-a(43) from Jinyuan Wang, Dec 12 2024

A290474 Number of fractional partitions of n where each element of a partition is a rational number r/s such that r < s, s <= n, and gcd(r,s) = 1.

Original entry on oeis.org

1, 0, 1, 12, 135, 4477, 100160, 8663934, 485380025, 80730951180, 10180011676356, 4126137351376215, 563950787766342780, 456369006693283278869, 200330760220853808357439, 335435016971402890883460861, 197675615401466868237710861644, 561969529551274362018496511765678
Offset: 0

Views

Author

Joseph Wheat, Aug 03 2017

Keywords

Comments

a(n) = (n^2 + 1)^(-1 + Sum_{k=1..n} phi(k)) - f(n) where phi(n) is Euler's totient function, and f(n) is the number of trivial solutions which do not satisfy the equation q_1*x_1 + q_2*x_2 + ... + q_m*x_m = n. Each coefficient is a rational number satisfying the criteria given in the definition, and m = -1 + Sum_{k=1..n} phi(k).

Examples

			For n=3, the number of partitions is equal to the number of nonnegative integer solutions for the equation: (1/2)*x_1 + (1/3)*x_2 + (2/3)*x_3 = 3. The set S of solutions is {[0,1,4], [0,3,3], [0,5,2], [0,7,1], [0,9,0], [2,0,3], [2,2,2], [2,4,1], [2,6,0], [4,1,1], [4,3,0], [6,0,0]}. Therefore, |S| = a(3) = 12.
		

Crossrefs

Programs

  • PARI
    s(v, n, t) = {if(t==#v, f = n\v[t]; v[t]*f == n, sum(i=0, n\v[t], s(v, n-v[t]*i, t+1)))}
    a(n) = {if(n<=2, return(n-1)); my(fractions = List(), q = 0); for(i=2, n, for(j=1, i-1, if(gcd(i, j)==1, listput(fractions, j/i)))); s(fractions, n, 1)} \\ David A. Corneth, Aug 03 2017

Extensions

a(7)-a(17) from Alois P. Heinz, Aug 03 2017
Showing 1-3 of 3 results.