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.

A091862 a(n) = 1 if the sum of all exponents of the prime-factorization of n has no carries when summed in base 2, or a(n) = 0 if there are any carries.

This page as a plain text file.
%I A091862 #22 Dec 23 2023 09:33:40
%S A091862 1,1,1,1,1,0,1,1,1,0,1,1,1,0,0,1,1,1,1,1,0,0,1,0,1,0,1,1,1,0,1,1,0,0,
%T A091862 0,0,1,0,0,0,1,0,1,1,1,0,1,1,1,1,0,1,1,0,0,0,0,0,1,0,1,0,1,1,0,0,1,1,
%U A091862 0,0,1,0,1,0,1,1,0,0,1,1,1,0,1,0,0,0,0,0,1,0,0,1,0,0,0,0,1,1,1,0,1,0,1,0,0
%N A091862 a(n) = 1 if the sum of all exponents of the prime-factorization of n has no carries when summed in base 2, or a(n) = 0 if there are any carries.
%C A091862 Characteristic function for A268375. - _Antti Karttunen_, Nov 23 2017
%H A091862 Antti Karttunen, <a href="/A091862/b091862.txt">Table of n, a(n) for n = 1..65537</a>
%H A091862 <a href="/index/Ch#char_fns">Index entries for characteristic functions</a>.
%H A091862 <a href="/index/Eu#epf">Index entries for sequences computed from exponents in factorization of n</a>.
%H A091862 <a href="/index/Bi#binary">Index entries for sequences related to binary expansion of n</a>.
%F A091862 If A268374(n) = 0, then a(n) = 1, 0 otherwise. - _Antti Karttunen_, Nov 23 2017
%e A091862 a(12) = 1 because 12 = 2^2 *3^1 and, in base 2, 2 = '10', 1 = '1' and '10' and '1' have their ones in different positions. But a(24) = 0 because 24 = 2^3 *3^1 and in base 2 3 = '11', 1 = '1', which both share a rightmost one.
%t A091862 f[e_] := Position[Reverse[IntegerDigits[e, 2]], 1] // Flatten; a[n_] := Boole[UnsameQ @@ Flatten[f /@ FactorInteger[n][[;; , 2]]]]; Array[a, 100] (* _Amiram Eldar_, Dec 23 2023 *)
%o A091862 (PARI) a(n) = {my(e = factor(n)[,2], b = 0); for(i=1, #e, b = bitor(b, e[i])); n == 1 || b == vecsum(e);} \\ _Amiram Eldar_, Dec 23 2023
%Y A091862 Cf. A091863, A267116, A268374, A289618.
%Y A091862 Cf. A268375 (positions of ones), A268376 (of zeros).
%K A091862 nonn,base
%O A091862 1,1
%A A091862 _Leroy Quet_, Mar 13 2004
%E A091862 More terms from Pab Ter (pabrlos(AT)yahoo.com), May 25 2004