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.

Previous Showing 31-32 of 32 results.

A331821 Positive numbers k such that -k and -(k + 1) are both negabinary-Niven numbers (A331728).

Original entry on oeis.org

2, 3, 8, 9, 15, 24, 27, 32, 33, 39, 54, 55, 63, 77, 111, 114, 115, 123, 128, 129, 135, 144, 159, 174, 175, 203, 234, 235, 245, 255, 264, 294, 295, 329, 370, 371, 384, 413, 414, 415, 444, 447, 474, 475, 495, 504, 507, 512, 513, 519, 534, 535, 543, 580, 581, 624
Offset: 1

Views

Author

Amiram Eldar, Jan 27 2020

Keywords

Examples

			8 is a term since both -8 and -(8 + 1) = -9 are negabinary-Niven numbers: A039724(-8) = 1000 and 1 + 0 + 0 + 0 = 1 is a divisor of 8, and A039724(-9) = 1011 and 1 + 0 + 1 + 1 = 3 is a divisor of 9.
		

Crossrefs

Programs

  • Mathematica
    negaBinWt[n_] := negaBinWt[n] = If[n == 0, 0, negaBinWt[Quotient[n - 1, -2]] + Mod[n, 2]]; negaBinNivenQ[n_] := Divisible[n, negaBinWt[-n]]; c = 0; k = 1; s = {}; v = Table[-1, {2}]; While[c < 60, If[negaBinNivenQ[k], v = Join[Rest[v], {k}]; If[AllTrue[Differences[v], # == 1 &], c++; AppendTo[s, k - 1]]]; k++]; s

A337079 The number of twin binary Niven numbers (k, k+1) such that k <= 2^n.

Original entry on oeis.org

1, 1, 1, 1, 2, 2, 5, 8, 18, 35, 61, 98, 187, 304, 492, 880, 1583, 2779, 5196, 9407, 17387, 31772, 58450, 106360, 193875, 351836, 642844, 1173333, 2155913, 3993379, 7466547, 14048253, 26680668, 50751057, 97052665, 185557893, 354235368, 674995568, 1284856970
Offset: 1

Views

Author

Amiram Eldar, Aug 14 2020

Keywords

Examples

			a(5) = 2 since there are two binary Niven numbers k below 2^5 = 32 such that k+1 is also a binary Niven number: 1 and 20.
		

Crossrefs

Programs

  • Mathematica
    binNivenQ[n_] := Divisible[n, DigitCount[n, 2, 1]]; s = {}; c = 0; p = 2; q1 = True; Do[q2 = binNivenQ[n]; If[q1 && q2, c++]; If[n - 1 == p, AppendTo[s, c]; p *= 2]; q1 = q2, {n, 2, 2^20}]; s

Formula

a(n) ~ c * 2^n/n^2, where c is a constant (consequence of the theorem of De Koninck et al., 2008). Apparently c ~ 0.28.
Previous Showing 31-32 of 32 results.