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

A340795 a(n) is the number of divisors of n that are Brazilian.

Original entry on oeis.org

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

Views

Author

Bernard Schott, Jan 21 2021

Keywords

Comments

The cases a(n) = 0 and a(n) = 1 are respectively detailed in A341057 and A341058.

Examples

			For n = 16, the divisors are 1, 2, 4, 8 and 16. Only 8 = 22_3 and 16 = 22_7 are Brazilian numbers, so a(16) = 2.
For n = 30, the divisors are 1, 2, 3, 5, 6, 10, 15 and 30. Only 10 = 22_4, 15 = 33_4 and 30 = 33_9 are Brazilian numbers, so a(30) = 3.
For n = 49, the divisors are 1, 7 and 49. Only 7 = 111_2 is Brazilian, so a(49) = 1 although 49 that is square of prime <> 121 is not Brazilian.
		

Crossrefs

Programs

  • Mathematica
    brazQ[n_] := Module[{b = 2, found = False}, While[b < n - 1 && Length[Union[IntegerDigits[n, b]]] > 1, b++]; b < n - 1]; a[n_] := DivisorSum[n, 1 &, brazQ[#] &]; Array[a, 100] (* Amiram Eldar, Jan 21 2021 *)
  • PARI
    isb(n) = for(b=2, n-2, d=digits(n, b); if(vecmin(d)==vecmax(d), return(1))); \\ A125134
    a(n) = sumdiv(n, d, isb(d)); \\ Michel Marcus, Jan 24 2021

A340796 a(n) is the smallest number with exactly n divisors that are Brazilian.

Original entry on oeis.org

1, 7, 14, 24, 40, 48, 60, 84, 140, 144, 120, 168, 252, 700, 240, 336, 560, 360, 420, 672, 1120, 2304, 960, 720, 1008, 1080, 840, 2184, 1800, 1260, 2016, 5376, 8960, 2160, 1680, 2880, 4032, 3600, 7056, 19600, 3960, 2520, 3360, 6480, 9072, 9900, 6300, 11520, 16128
Offset: 0

Views

Author

Bernard Schott, Jan 21 2021

Keywords

Comments

Primes can be partitioned into Brazilian primes and non-Brazilian primes. If two distinct primes each larger than 11 are in the same category then the larger one has a multiplicity that is smaller than or equal to that of the smaller prime. - David A. Corneth, Jan 24 2021

Examples

			Of the eight divisors of 24, three are Brazilian numbers: 8, 12 and 24, and there is no smaller number with three Brazilian divisors, hence a(3) = 24.
		

Crossrefs

Similar with: A087997 (palindromes), A333456 (Niven), A335038 (Zuckerman).

Programs

  • Mathematica
    brazQ[n_] := Module[{b = 2, found = False}, While[b < n - 1 && Length[Union[IntegerDigits[n, b]]] > 1, b++]; b < n - 1]; d[n_] := DivisorSum[n, 1 &, brazQ[#] &]; m = 30; s = Table[0, {m}]; c = 0; n = 1; While[c < m, i = d[n]; If[i < m && s[[i + 1]] == 0, c++; s[[i + 1]] = n]; n++]; s (* Amiram Eldar, Jan 21 2021 *)
  • PARI
    isokb(n) = for(b=2, n-2, d=digits(n, b); if(vecmin(d)==vecmax(d), return(1))); \\ A125134
    isok(k, n) = sumdiv(k, d, isokb(d)) == n;
    a(n) = my(k=1); while (!isok(k, n), k++); k; \\ Michel Marcus, Jan 23 2021

Extensions

More terms from Amiram Eldar, Jan 21 2021
Showing 1-2 of 2 results.