login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A276039 Numbers using only digits 1 and 7. 12
1, 7, 11, 17, 71, 77, 111, 117, 171, 177, 711, 717, 771, 777, 1111, 1117, 1171, 1177, 1711, 1717, 1771, 1777, 7111, 7117, 7171, 7177, 7711, 7717, 7771, 7777, 11111, 11117, 11171, 11177, 11711, 11717, 11771, 11777, 17111, 17117, 17171, 17177, 17711, 17717, 17771, 17777 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
Numbers k such that the product of digits of k is a power of 7.
There are no prime terms whose number of digits is divisible by 3: for every d that is a multiple of 3, every d-digit number j consisting of no digits other than 1's and 7's will have a digit sum divisible by 3, so j will also be divisible by 3. - Mikk Heidemaa, Mar 27 2021
LINKS
EXAMPLE
7717 is in the sequence because 7*7*1*7 = 343 = 7^3.
MATHEMATICA
Select[Range[20000], IntegerQ[Log[7, Times@@(IntegerDigits[#])]] &] (* or *) Flatten[Table[FromDigits/@Tuples[{1, 7}, n], {n, 6}]]
PROG
(Magma) [n: n in [1..24000] | Set(Intseq(n)) subset {1, 7}];
(PARI) is(n) = my(d=digits(n), e=[0, 2, 3, 4, 5, 6, 8, 9]); if(#setintersect(Set(d), Set(e))==0, return(1), return(0)) \\ Felix Fröhlich, Aug 19 2016
(PARI) a(n) = { my(b = binary(n + 1)); b = b[^1]; b = apply(x -> 6*x + 1, b); fromdigits(b) } \\ David A. Corneth, Mar 27 2021
(Python)
def a(n):
b = bin(n+1)[3:]
return int("".join(b.replace("1", "7").replace("0", "1")))
print([a(n) for n in range(1, 47)]) # Michael S. Branicky, Mar 27 2021
CROSSREFS
Cf. similar sequences listed in A276037.
Sequence in context: A094104 A167513 A260891 * A199327 A260892 A020455
KEYWORD
nonn,easy,base
AUTHOR
Vincenzo Librandi, Aug 19 2016
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 17 23:23 EDT 2024. Contains 371767 sequences. (Running on oeis4.)