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-6 of 6 results.

A384047 Triangle read by rows: T(n, k) for 1 <= k <= n is the largest divisor of k that is a unitary divisor of n.

Original entry on oeis.org

1, 1, 2, 1, 1, 3, 1, 1, 1, 4, 1, 1, 1, 1, 5, 1, 2, 3, 2, 1, 6, 1, 1, 1, 1, 1, 1, 7, 1, 1, 1, 1, 1, 1, 1, 8, 1, 1, 1, 1, 1, 1, 1, 1, 9, 1, 2, 1, 2, 5, 2, 1, 2, 1, 10, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 11, 1, 1, 3, 4, 1, 3, 1, 4, 3, 1, 1, 12, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 13
Offset: 1

Views

Author

Amiram Eldar, May 18 2025

Keywords

Examples

			Triangle begins:
  1
  1, 2
  1, 1, 3
  1, 1, 1, 4
  1, 1, 1, 1, 5
  1, 2, 3, 2, 1, 6
  1, 1, 1, 1, 1, 1, 7
  1, 1, 1, 1, 1, 1, 1, 8
  1, 1, 1, 1, 1, 1, 1, 1, 9
  1, 2, 1, 2, 5, 2, 1, 2, 1, 10
		

Crossrefs

Upper right triangle of A322482.

Programs

  • Mathematica
    udiv[n_] := Select[Divisors[n], CoprimeQ[#, n/#] &]; T[n_, k_] := Max[Intersection[udiv[n], Divisors[k]]]; Table[T[n, k], {n, 1, 10}, {k, 1, n}] // Flatten
  • PARI
    udiv(n) = select(x -> gcd(x, n/x) == 1, divisors(n));
    T(n, k) = vecmax(setintersect(udiv(n), divisors(k)));

Formula

T(n, 1) = 1.
T(n, n) = n.
T(n, k) <= A050873(n, k) = gcd(n, k), with equality if n is squarefree (A005117).

A065472 Decimal expansion of Product_{p prime} (1 - 1/(p+1)^2).

Original entry on oeis.org

7, 7, 5, 8, 8, 3, 5, 1, 0, 0, 0, 3, 8, 9, 5, 4, 9, 9, 6, 2, 0, 4, 0, 4, 2, 8, 4, 4, 2, 7, 9, 0, 0, 6, 1, 1, 4, 8, 2, 4, 1, 3, 4, 6, 5, 9, 7, 3, 0, 1, 6, 2, 7, 6, 2, 2, 1, 0, 6, 3, 1, 1, 6, 4, 6, 1, 3, 8, 7, 6, 4, 9, 2, 4, 9, 7, 4, 5, 6, 9, 9, 5, 3, 7, 1, 9, 3, 1, 3, 2, 3, 3, 1, 2, 8, 1, 4, 2
Offset: 0

Views

Author

N. J. A. Sloane, Nov 19 2001

Keywords

Comments

The probablity that two randomly chosen squarefree numbers are coprime. - Amiram Eldar, Aug 04 2020
The asymptotic mean of A001157(n)/(n*A000203(n)). - Richard R. Forberg, May 27 2023

Examples

			0.7758835100038954996204042844279...
		

Crossrefs

Programs

  • Mathematica
    digits = 98; Exp[NSum[(-1)^n*(2^(n-1)-2)*PrimeZetaP[n-1]/(n-1), {n, 3, Infinity}, WorkingPrecision -> 2 digits, Method -> "AlternatingSigns"]] // RealDigits[#, 10, digits]& // First (* Jean-François Alcover, Apr 18 2016 *)
  • PARI
    prodeulerrat(1 - 1/(p+1)^2) \\ Amiram Eldar, Mar 17 2021

Formula

Equals lim_{n->oo} (Pi^2/(3*n^2*log(n))) * Sum_{k=1..n} A145388(k). - Amiram Eldar, May 14 2019
Equals Sum_{k>=1} mu(k)/sigma(k)^2, where mu is the Möbius function (A008683) and sigma(k) is the sum of divisors of k (A000203). - Amiram Eldar, Jan 14 2022

Extensions

Definition corrected by Dan Asimov, Apr 15 2006

A343525 If n = Product (p_j^k_j) then a(n) = Product (2*p_j^k_j + 1), with a(1) = 1.

Original entry on oeis.org

1, 5, 7, 9, 11, 35, 15, 17, 19, 55, 23, 63, 27, 75, 77, 33, 35, 95, 39, 99, 105, 115, 47, 119, 51, 135, 55, 135, 59, 385, 63, 65, 161, 175, 165, 171, 75, 195, 189, 187, 83, 525, 87, 207, 209, 235, 95, 231, 99, 255, 245, 243, 107, 275, 253, 255, 273, 295, 119, 693, 123, 315, 285, 129, 297, 805
Offset: 1

Views

Author

Ilya Gutkovskiy, Apr 18 2021

Keywords

Comments

The unitary analog of A060640.

Crossrefs

Programs

  • Maple
    a:= n-> mul(2*i[1]^i[2]+1, i=ifactors(n)[2]):
    seq(a(n), n=1..80);  # Alois P. Heinz, Apr 18 2021
  • Mathematica
    a[1] = 1; a[n_] := Times @@ ((2 #[[1]]^#[[2]] + 1) & /@ FactorInteger[n]); Table[a[n], {n, 66}]
  • PARI
    a(n) = my(f=factor(n)); for (k=1, #f~, f[k,1] = 2*f[k,1]^f[k,2]+1; f[k,2]=1); factorback(f); \\ Michel Marcus, Apr 18 2021

Formula

a(n) = Sum_{d|n, gcd(d, n/d) = 1} d * usigma(n/d).
a(n) = Sum_{d|n, gcd(d, n/d) = 1} d * 2^omega(d).
Dirichlet g.f.: zeta(s-1) * zeta(s) * Product_{p prime} (1 + 1/p^(s-1) - 2/p^(2*s-1)). - Amiram Eldar, Jul 24 2024

A333557 a(n) = Sum_{d|n, gcd(d, n/d) = 1} uphi(d) * uphi(n/d), where uphi = unitary totient function (A047994).

Original entry on oeis.org

1, 2, 4, 6, 8, 8, 12, 14, 16, 16, 20, 24, 24, 24, 32, 30, 32, 32, 36, 48, 48, 40, 44, 56, 48, 48, 52, 72, 56, 64, 60, 62, 80, 64, 96, 96, 72, 72, 96, 112, 80, 96, 84, 120, 128, 88, 92, 120, 96, 96, 128, 144, 104, 104, 160, 168, 144, 112, 116, 192, 120, 120, 192, 126, 192, 160, 132, 192, 176, 192
Offset: 1

Views

Author

Ilya Gutkovskiy, Mar 26 2020

Keywords

Crossrefs

Programs

  • Mathematica
    uphi[1] = 1; uphi[n_] := Times @@ (#[[1]]^#[[2]] - 1 & /@ FactorInteger[n]); a[n_] := Sum[If[GCD[d, n/d] == 1, uphi[d] uphi[n/d], 0], {d, Divisors[n]}]; Table[a[n], {n, 1, 70}]
    Table[Sum[If[GCD[d, n/d] == 1, (-2)^PrimeNu[n/d] 2^PrimeNu[d] d, 0], {d, Divisors[n]}], {n, 1, 70}]
    f[p_, e_] := 2*(p^e-1); a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* Amiram Eldar, Apr 30 2023 *)
  • PARI
    a(n) = sumdiv(n, d, if (gcd(d, n/d) == 1, (-2)^omega(n/d)*2^omega(d)*d)); \\ Michel Marcus, Mar 27 2020

Formula

If n = Product (p_j^k_j) then a(n) = Product (2 * (p_j^k_j - 1)).
a(n) = 2^omega(n) * uphi(n).
a(n) = Sum_{d|n, gcd(d, n/d) = 1} (-2)^omega(n/d) * 2^omega(d) * d.
a(n) = Sum_{d|n, gcd(d, n/d) = 1} (-1)^omega(n/d) * A145388(d).

A333576 a(1) = 1; thereafter a(n) = n * uphi(n) / 2.

Original entry on oeis.org

1, 1, 3, 6, 10, 6, 21, 28, 36, 20, 55, 36, 78, 42, 60, 120, 136, 72, 171, 120, 126, 110, 253, 168, 300, 156, 351, 252, 406, 120, 465, 496, 330, 272, 420, 432, 666, 342, 468, 560, 820, 252, 903, 660, 720, 506, 1081, 720, 1176, 600, 816, 936, 1378, 702, 1100, 1176, 1026, 812, 1711, 720
Offset: 1

Views

Author

Ilya Gutkovskiy, Mar 27 2020

Keywords

Comments

The unitary version of A023896.

Crossrefs

Programs

  • Mathematica
    uphi[n_] := Times @@ (#[[1]]^#[[2]] - 1 & /@ FactorInteger[n]); a[1] = 1; a[n_] := n uphi[n]/2; Table[a[n], {n, 1, 60}]
    a[n_] := (n/2) Sum[If[GCD[d, n/d] == 1, (-1)^PrimeNu[n/d] (d + 1), 0], {d, Divisors[n]}]; Table[a[n], {n, 1, 60}]
  • PARI
    a(n) = if(n == 1, 1, my(f = factor(n)); prod(i = 1, #f~, f[i, 1]^f[i, 2] - 1) * n / 2); \\ Amiram Eldar, Sep 21 2024

Formula

a(n) = (n/2) * Sum_{d|n, gcd(d, n/d) = 1} (-1)^omega(n/d) * (d + 1).
Sum_{k=1..n} a(k) ~ c * n^3, where c = (Pi^2/36) * Product_{p prime} (1 - (2*p-1)/p^3) = A353908 * A065464 = 0.117407... . - Amiram Eldar, Sep 21 2024

A380650 The largest number which is a linear combination of the divisors of n with nonnegative integer coefficients such that no linear combination with smaller nonnegative integer coefficients is equal to n.

Original entry on oeis.org

0, 1, 2, 3, 4, 7, 6, 7, 8, 13, 10, 17, 12, 19, 22, 15, 16, 25, 18, 31, 32, 31, 22, 37, 24, 37, 26, 45, 28, 60, 30, 31, 52, 49, 58, 59, 36, 55, 62, 67, 40, 85, 42, 73, 76, 67, 46, 77, 48, 73, 82, 87, 52, 79, 94, 97, 92, 85, 58
Offset: 1

Views

Author

Alexei Vernitski, Jan 29 2025

Keywords

Comments

The mean of this sequence and Euler's totient function A000010 is approximately (but not exactly) equal to n.
The definition has evolved from a recreational question asked by P. M. Higgins, asking what maximal sum of money can be produced using British coins so no sum of one pound is produced by any subset of these coins.
The terms up to and including a(29)=28 agree with the formula a(n) = (A145388(n) - 1)/2, but a(30)=60, while the formula gives 67. This difference should be confirmed by an independent calculation using the definition in the name. - Hugo Pfoertner, Feb 14 2025

Examples

			For n = 12, the largest sum is 17 = 0*1 + 0*2 + 1*3 + 2*4 + 1*6 = 0*1 + 0*2 + 3*3 + 2*4 + 0*6.
For n = 30, the largest sum is 60 = 1*1 + 0*2 + 0*3 + 0*5 + 4*6 + 2*10 + 1*15.
		

Crossrefs

Showing 1-6 of 6 results.