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.

A378988 a(n) = 2*n XOR 1+sigma(n), where XOR is bitwise-xor, A003987.

Original entry on oeis.org

0, 0, 3, 0, 13, 1, 7, 0, 28, 7, 27, 5, 21, 5, 7, 0, 49, 12, 51, 3, 11, 9, 55, 13, 18, 31, 31, 1, 37, 117, 31, 0, 115, 115, 119, 20, 109, 113, 119, 11, 121, 53, 123, 13, 21, 21, 111, 29, 88, 58, 47, 11, 93, 21, 39, 9, 35, 47, 75, 209, 69, 29, 23, 0, 215, 21, 195, 247, 235, 29, 199, 84, 217, 231, 235, 21, 251, 53, 207
Offset: 1

Views

Author

Antti Karttunen, Dec 16 2024

Keywords

Comments

For any hypothetical quasiperfect number q (for which sigma(q) = 2*q+1, see A336701), a(q) would be equal to 2*q XOR 2*q+2 = 2*(q XOR q+1) = 2*A038712(1+q) = A100892(1+q).
See also A000079 and A235796 concerning the "almost perfect" or "least deficient" numbers that give positions of 0's here.

Crossrefs

Cf. A000079 (conjectured to give positions of all 0's), A000396 (positions of 1's), A000203, A003987, A028982 (positions of even terms), A028983 (of odd terms), A038712, A100892, A318467, A336701, A378998, A379009 [= a(n^2)].

Programs

  • Mathematica
    Array[BitXor[2*#, DivisorSigma[1, #] + 1] &, 100] (* Paolo Xausa, Dec 16 2024 *)
  • PARI
    A378988(n) = bitxor(n+n,1+sigma(n));

Formula

For all n in A028983, a(n) = 2n+1 XOR sigma(n) = 1+A318467(n).