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”).
%I #20 Jan 24 2024 01:49:08
%S 0,3,4,7,8,11,12,15,16,19,20,23,25,26,29,30,33,34,37,38,41,42,45,46,
%T 48,51,52,55,56,59,60,63,64,67,68,71,73,74,77,78,81,82,85,86,89,90,93,
%U 94,96,99,100,103,104,107,108,111,112,115,116,119,121,122,125
%N Numbers k for which the sum of digits is even when k is written in the factorial base (A007623).
%C Numbers k for which minimal number of factorials needed to add to get k is even.
%C This sequence offers one possible analog to A001969 (evil numbers) in factorial base system. A227130 gives another kind of analog.
%C In each range [0,n!-1] exactly half of the integers are found in this sequence, and the other half of them are found in the complement, A227149.
%C The sequence gives the positions of even permutations in the tables A055089 and A195663; and equivalently, the positions of even numbers in A055091.
%H Antti Karttunen, <a href="/A227148/b227148.txt">Table of n, a(n) for n = 1..2520</a>
%H Wikipedia, <a href="http://en.wikipedia.org/wiki/Parity_of_a_permutation">Parity of permutation</a>.
%t q[n_] := Module[{k = n, m = 2, s = 0, r}, While[{k, r} = QuotientRemainder[k, m]; k != 0|| r != 0, s += r; m++]; EvenQ[s]]; Select[Range[0, 125], q] (* _Amiram Eldar_, Jan 24 2024 *)
%o (Scheme, with _Antti Karttunen_'s IntSeq-library): (define A227148 (MATCHING-POS 1 0 (lambda (i) (even? (A034968 i)))))
%Y Complement: A227149. Cf. also A001969, A034968, A227130.
%K nonn,base
%O 1,2
%A _Antti Karttunen_, Jul 02 2013