OFFSET
1,2
COMMENTS
All numbers that are a power of 2 times a member of the sequence share the property that the binary representation is the same as the decimal representation of the first 1's and 0's multiple.
Of the values listed, only 1200341 and 3427673 are primes. - Jonathan Vos Post, Aug 09 2012
FORMULA
EXAMPLE
For example 21*481=10101 (the first multiple of 21 containing only 1's and 0's) and the binary representation of 21 is 10101.
MAPLE
rebase := proc(n, bin, bout)
local a, c, i;
a := 0 ;
c := convert(n, base, bin) ;
add( op(i, c)*bout^(i-1), i=1..nops(c)) ;
end proc:
isA079339 := proc(n, c)
local c2, b;
if modp(c, n) > 0 then
return false;
end if;
c2 := rebase(c, 10, 2) ;
for b from 1 to c2-1 do
if modp( rebase(b, 2, 10), n) = 0 then
return false;
end if;
end do:
return true ;
end proc:
for n from 1 by 2 do
sb := rebase(n, 2, 10) ;
if isA079339(n, sb) then
print(n);
end if;
end do: # R. J. Mathar, Aug 09 2012
CROSSREFS
KEYWORD
nonn,base,more
AUTHOR
Patrick McKinley, Aug 05 2012
STATUS
approved