OFFSET
1,1
COMMENTS
The sum of the first k odd-indexed primorial numbers (A002110) is a term, since its primorial-base representation is 1010...10, with the block "10" repeated k times (these numbers are 2, 32, 2342, 512852, 223605722, ...).
LINKS
EXAMPLE
5 is a term since its primorial-base representation, 21, has one odd digit, 1, and one even digit, 2.
MATHEMATICA
With[{max = 5}, bases = Prime@ Range[max, 1, -1]; nmax = Times @@ bases - 1; prmBaseDigits[n_] := IntegerDigits[n, MixedRadix[bases]]; Select[Range[nmax], EvenQ[Length[(d = prmBaseDigits[#])]] && Count[d, _?EvenQ] == Length[d]/2 &]]
PROG
(PARI) is(n) = {my(p = 2, o = 0, e = 0); if(n < 1, return(0)); while(n > 0, if((n%p)%2 == 0, e++, o++); n \= p; p = nextprime(p+1)); e == o; }
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Amiram Eldar, May 23 2023
STATUS
approved