login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

a(n) = n - (2^n (mod n)).
3

%I #8 Aug 10 2022 09:56:15

%S 1,2,1,4,3,2,5,8,1,6,9,8,11,10,7,16,15,8,17,4,13,18,21,8,18,22,1,12,

%T 27,26,29,32,25,30,17,8,35,34,31,24,39,20,41,28,28,42,45,32,19,26,43,

%U 36,51,26,12,24,49,54,57,44,59,58,55,64,33,2,65,52,61,26,69,8,71,70,7,60,59

%N a(n) = n - (2^n (mod n)).

%H Alois P. Heinz, <a href="/A082494/b082494.txt">Table of n, a(n) for n = 1..10000</a>

%p a:= n-> n-(2&^n mod n):

%p seq(a(n), n=1..100); # _Alois P. Heinz_, Apr 08 2015

%Y Cf. A015910, A082493, A215747.

%K easy,nonn,look

%O 1,2

%A Anonymous, Apr 28 2003