%I #22 Feb 09 2019 23:25:10
%S 0,0,1,0,1,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,
%T 1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
%U 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
%N Parity of n*floor(log n).
%C a(n)=1 for n: 3, 5, 7, 21, 23, 25, 27, 29, 31, 33, 35, 37, 39, 41, 43, 45, 47, 49, 51, 53, 149, 151, .... - _Robert G. Wilson v_, Feb 01 2015
%H Antti Karttunen, <a href="/A072629/b072629.txt">Table of n, a(n) for n = 1..100000</a>
%H <a href="/index/Ch#char_fns">Index entries for characteristic functions</a>
%F a(n) = n*floor(log(n)) mod 2.
%e Parity either alternates or it is steadily 0. Intervals of such kind also change and return: 01010...0000....0101.., etc.
%t f[n_] := Mod[n*Floor@ Log@ n, 2]; Array[f, 105] (* _Robert G. Wilson v_, Feb 01 2015 *)
%o (PARI) a(n) = (log(n)\1*n)%2; \\ _Charles R Greathouse IV_, Sep 04 2015, corrected by _Antti Karttunen_, Feb 06 2019
%Y Cf. A004648, A072608, A072609, A072610, A072630.
%K nonn
%O 1,1
%A _Labos Elemer_, Jun 28 2002