%I #16 Sep 01 2023 08:17:17
%S 0,2,5,12,15,24,33,56,59,68,77,104,113,140,167,240,243,252,261,288,
%T 297,324,351,432,441,468,495,576,603,684,765,992,995,1004,1013,1040,
%U 1049,1076,1103,1184,1193,1220,1247,1328,1355,1436
%N (A160414(n)-1)/4, n >= 1.
%C As is obvious from symmetry, for all n>=1 one has A160414(n) = 1 + a multiple of 4.
%C Partial sums of 3^A000120(n-1)-(n/2 if n=2^k), n>1.
%C Numbers whose first differences are in A160727. - _Omar E. Pol_, Dec 02 2012
%H Paolo Xausa, <a href="/A219954/b219954.txt">Table of n, a(n) for n = 1..10000</a>
%t A219954list[nmax_]:=Accumulate[Table[If[n==1,0,3^DigitCount[n-1,2,1]-If[IntegerQ[Log2[n]],n/2,0]],{n,nmax}]];A219954list[100] (* _Paolo Xausa_, Sep 01 2023 *)
%o (PARI) my(s=-1,t(n)=3^norml2(binary(n-1))-if(n==(1<<valuation(n,2)),n\2));vector(99,i,s+=t(i))
%Y Cf. A160727.
%K nonn
%O 1,2
%A _M. F. Hasler_, Dec 01 2012
|