[go: up one dir, main page]

login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A258813 Numbers n with the property that it is possible to write the base 2 expansion of n as concat(a_2,b_2), with a_2>0 and b_2>0 such that, converting a_2 and b_2 to base 10 as a and b, we have sigma(a) + sigma (b) = sigma(n) - n. 9

%I #18 Jun 30 2015 04:10:03

%S 9,15,27,39,51,77,143,207,329,377,473,611,903,1241,1243,1273,1437,

%T 1591,2117,2303,2975,4189,8401,8657,11993,13849,15611,16771,18239,

%U 18599,19359,25331,28877,37291,41747,41807,61549,67037,72601,82169,83411,83711,87449,99329

%N Numbers n with the property that it is possible to write the base 2 expansion of n as concat(a_2,b_2), with a_2>0 and b_2>0 such that, converting a_2 and b_2 to base 10 as a and b, we have sigma(a) + sigma (b) = sigma(n) - n.

%H Paolo P. Lava, <a href="/A258813/b258813.txt">Table of n, a(n) for n = 1..80</a>

%e 9 in base 2 is 1001. If we take 1001 = concat(10,01) then 10 and 01 converted to base 10 are 2 and 1. Finally sigma(2) + sigma(1) = sigma(9) - 9 = 4.

%e 180953 in base 2 is 101100001011011001. If we take 101100001011011001 = concat(101100001011,011001) then 101100001011 and 011001 converted to base 10 are 2827 and 25. Finally sigma(2827) + sigma(25) = sigma(180953) - 180953 = 3127.

%p with(numtheory): P:=proc(q) local a,b,c,j,k,n;

%p for n from 1 to q do c:=convert(n,binary,decimal);

%p j:=0; for k from 1 to ilog10(c) do

%p a:=convert(trunc(c/10^k),decimal,binary);

%p b:=convert((c mod 10^k),decimal,binary);

%p if a*b>0 then if sigma(a)+sigma(b)=sigma(n)-n then print(n);

%p break; fi; fi; od; od; end: P(10^9);

%o (PARI) isok(n) = {b = binary(n); if (#b > 1, for (k=1, #b-1, vba = Vecrev(vector(k, i, b[i])); vbb = Vecrev(vector(#b-k, i, b[k+i])); da = sum(i=1, #vba, vba[i]*2^(i-1)); db = sum(i=1, #vbb, vbb[i]*2^(i-1)); if (da && db && (sigma(da)+sigma(db) == sigma(n)-n), return(1));););} \\ _Michel Marcus_, Jun 13 2015

%Y Cf. A253824, A253825, A258843, A258844.

%K nonn,base

%O 1,1

%A _Paolo P. Lava_, Jun 11 2015

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified August 30 00:57 EDT 2024. Contains 375520 sequences. (Running on oeis4.)