OFFSET
1,1
COMMENTS
All even integers 2p >=8 are Brazilian numbers (A125134), because 2p=2(p-1)+2 is written 22 in base p-1 if p-1>2, that is true if p >=4. But, among Brazilian numbers, there are also odd ones...
The only square of a prime is 121. - Robert G. Wilson v, May 21 2015
LINKS
Daniel Lignon and Robert Israel, Table of n, a(n) for n = 1..10000 (first 703 from Daniel Lignon)
MAPLE
N:= 1000: # to get all terms <= N
for b from 2 to floor(N/2-1) do
dk:= 1 + (b mod 2);
for j from 1 to b-1 by 2 do
for k from dk by dk do
if j=1 and k=1 then next fi;
x:= j*(b^(k+1)-1)/(b-1);
if x > N then break fi;
B[x]:= 1;
od
od
od:
sort(map(op, [indices(B)])); # Robert Israel, May 27 2015
MATHEMATICA
fQ[n_] := Block[{b = 2}, While[b < n - 1 && Length[ Union[ IntegerDigits[n, b]]] > 1, b++]; b < n - 1]; Select[1 + 2 Range@100, fQ] (* Robert G. Wilson v, May 21 2015 *)
PROG
(PARI) forstep(n=5, 300, 2, for(b=2, n-2, d=digits(n, b); if(vecmin(d)==vecmax(d), print1(n, ", "); break))) \\ Derek Orr, Apr 30 2015
CROSSREFS
KEYWORD
nonn,base,easy
AUTHOR
Daniel Lignon, Apr 27 2015
STATUS
approved