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

A336040 Characteristic function of refactorable numbers (A033950).

Original entry on oeis.org

1, 1, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0
Offset: 1

Views

Author

Wesley Ivan Hurt, Jul 07 2020

Keywords

Examples

			a(1) = 1 since d(1) = 1 and 1 divides 1.
a(2) = 1 since d(2) = 2 and 2 divides 2.
a(3) = 0 since d(3) = 2, but 2 does not divide 3.
		

Crossrefs

Cf. A000005, A033950, A054008, A336041 (inverse Möbius transform), A335182, A335665, A349322.

Programs

  • Mathematica
    a[n_] := Boole @ Divisible[n, DivisorSigma[0, n]]; Array[a, 100] (* Amiram Eldar, Jul 08 2020 *)
  • PARI
    a(n) = n%numdiv(n) == 0; \\ Michel Marcus, Jul 07 2020

Formula

a(n) = 1 - ceiling(n/d(n)) + floor(n/d(n)), where d(n) is the number of divisors of n (A000005).
a(n) = [A054008(n) == 0], where [ ] is the Iverson bracket. - Antti Karttunen, Nov 24 2021
a(p) = 0 for odd primes p. - Wesley Ivan Hurt, Nov 28 2021

A335182 Sum of the refactorable divisors of n.

Original entry on oeis.org

1, 3, 1, 3, 1, 3, 1, 11, 10, 3, 1, 15, 1, 3, 1, 11, 1, 30, 1, 3, 1, 3, 1, 47, 1, 3, 10, 3, 1, 3, 1, 11, 1, 3, 1, 78, 1, 3, 1, 51, 1, 3, 1, 3, 10, 3, 1, 47, 1, 3, 1, 3, 1, 30, 1, 67, 1, 3, 1, 75, 1, 3, 10, 11, 1, 3, 1, 3, 1, 3, 1, 182, 1, 3, 1, 3, 1, 3, 1, 131, 10, 3, 1, 99
Offset: 1

Views

Author

Wesley Ivan Hurt, Jul 17 2020

Keywords

Comments

Inverse Möbius transform of n * c(n), where c(n) is the characteristic function of refactorable numbers (A336040). - Wesley Ivan Hurt, Jun 21 2024

Examples

			a(6) = 3; The divisors of 6 are {1,2,3,6}. 1 and 2 are refactorable since d(1) = 1|1 and d(2) = 2|2, so a(6) = 1 + 2 = 3.
a(7) = 1; The divisors of 7 are {1,7} and 1 is the only refactorable divisor of 7. So a(7) = 1.
a(8) = 11; The divisors of 8 are {1,2,4,8}. 1, 2 and 8 are refactorable since d(1) = 1|1, d(2) = 2|2 and d(8) = 4|8, so a(8) = 1 + 2 + 8 = 11.
a(9) = 10; The divisors of 9 are {1,3,9}. 1 and 9 are refactorable since d(1) = 1|1 and d(9) = 3|9, so a(9) = 1 + 9 = 10.
		

Crossrefs

Cf. A000005 (tau), A033950 (refactorable numbers), A336040 (refactorable characteristic), A336041 (number of refactorable divisors), A335665 (their product).
Difference of A349322 and A349658.

Programs

  • Mathematica
    a[n_] := DivisorSum[n, # &, Divisible[#, DivisorSigma[0, #]] &]; Array[a, 80] (* Amiram Eldar, Nov 24 2021 *)
  • PARI
    isr(n) = n%numdiv(n)==0; \\ A033950
    a(n) = sumdiv(n, d, if (isr(d), d)); \\ Michel Marcus, Jul 20 2020

Formula

a(n) = Sum_{d|n} d * c(d), where c = A336040.
a(n) = Sum_{d|n} d * (1 - ceiling(d/tau(d)) + floor(d/tau(d))), where tau(n) is the number of divisors of n (A000005).
a(n) = A349322(n) - A349658(n). - Antti Karttunen, Nov 24 2021
a(p) = 1 for odd primes p. - Wesley Ivan Hurt, Nov 28 2021

A335665 Product of the refactorable divisors of n.

Original entry on oeis.org

1, 2, 1, 2, 1, 2, 1, 16, 9, 2, 1, 24, 1, 2, 1, 16, 1, 324, 1, 2, 1, 2, 1, 4608, 1, 2, 9, 2, 1, 2, 1, 16, 1, 2, 1, 139968, 1, 2, 1, 640, 1, 2, 1, 2, 9, 2, 1, 4608, 1, 2, 1, 2, 1, 324, 1, 896, 1, 2, 1, 1440, 1, 2, 9, 16, 1, 2, 1, 2, 1, 2, 1, 1934917632, 1, 2, 1, 2, 1, 2, 1, 51200
Offset: 1

Views

Author

Wesley Ivan Hurt, Jul 17 2020

Keywords

Examples

			a(6) = 2; The divisors of 6 are {1,2,3,6}. 1 and 2 are refactorable since d(1) = 1|1 and d(2) = 2|2, so a(6) = 1 * 2 = 2.
a(7) = 1; The divisors of 7 are {1,7} and 1 is the only refactorable divisor of 7. So a(7) = 1.
a(8) = 16; The divisors of 8 are {1,2,4,8}. 1, 2 and 8 are refactorable since d(1) = 1|1, d(2) = 2|2 and d(8) = 4|8, so a(8) = 1 * 2 * 8 = 16.
a(9) = 9; The divisors of 9 are {1,3,9}. 1 and 9 are refactorable since d(1) = 1|1 and d(9) = 3|9, so a(9) = 1 * 9 = 9.
		

Crossrefs

Cf. A000005 (tau), A033950 (refactorable numbers), A336040 (refactorable characteristic), A336041 (number of refactorable divisors), A335182 (their sum).
Cf. also A349322 (similar formula, but with sum instead of product).

Programs

  • Mathematica
    a[n_] := Product[If[Divisible[d, DivisorSigma[0, d]], d, 1], {d, Divisors[n]}]; Array[a, 60] (* Amiram Eldar, Nov 24 2021 *)
  • PARI
    isr(n) = n%numdiv(n)==0; \\ A033950
    a(n) = my(d=divisors(n)); prod(k=1, #d, if (isr(d[k]), d[k], 1)); \\ Michel Marcus, Jul 18 2020

Formula

a(n) = Product_{d|n} d^c(d), where c(n) is the refactorable characteristic of n (A336040).
a(n) = Product_{d|n} d^(1 - ceiling(d/tau(d)) + floor(d/tau(d))), where tau(n) is the number of divisors of n (A000005).
a(p) = 1 for odd primes p. - Wesley Ivan Hurt, Nov 28 2021

A349658 Number of nonrefactorable divisors of n.

Original entry on oeis.org

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

Views

Author

Wesley Ivan Hurt, Nov 23 2021

Keywords

Crossrefs

Programs

  • Mathematica
    a[n_] := DivisorSum[n, 1 &, !Divisible[#, DivisorSigma[0, #]] &]; Array[a, 100] (* Amiram Eldar, Nov 24 2021 *)
  • PARI
    a(n) = sumdiv(n, d, d%numdiv(d) != 0); \\ Michel Marcus, Nov 24 2021

Formula

a(n) = A000005(n) - A336041(n).
a(n) = A349322(n) - A335182(n). - Antti Karttunen, Nov 24 2021
a(p) = 1 for odd primes p. - Wesley Ivan Hurt, Nov 28 2021
Showing 1-4 of 4 results.