Logo

Greetings from The On-Line Encyclopedia of Integer Sequences!

Hints

Search: id:A135464
Displaying 1-1 of 1 results found. page 1
     Format: long | short | internal | text      Sort: relevance | references | number      Highlight: on | off
A135464 Numbers n with property that for each single digit d of the base 3 expansion of n, we can also see the base 3 expansion of d^2 as a substring. Also n may not contain any 0 digits. +0
2
1, 11, 111, 112, 211, 1111, 1112, 1121, 1122, 1211, 2111, 2112, 2211, 11111, 11112, 11121, 11122, 11211, 11212, 11221, 11222, 12111, 12112, 12211, 21111, 21112, 21121, 21122, 21211, 22111, 22112, 22211, 111111, 111112, 111121 (list; graph; listen)
OFFSET

1,2

COMMENT

The base 3 expansion of n may only contain 1's and 2's, and if a 2 is present then 11 must also be present. These are the only restrictions.

LINKS

David Applegate, Table of n, a(n) for n = 1..300

PROGRAM

(AWK, from David Applegate) awk 'function g(s, v, n){if (n==0){if (index(s, "2")==0||index(s, "11")>0)print v; }else{g(s "1", v*3+1, n-1); g(s "2", v*3+2, n-1); }}BEGIN{for (i=1; i<=8; i++)g("", 0, i); }'

For C++ program see the Applegate link in A135463.

CROSSREFS

Base 3 analogue of A134962. Cf. A135465.

Sequence in context: A061493 A093788 A098759 this_sequence A083278 A039987 A039989

Adjacent sequences: A135461 A135462 A135463 this_sequence A135465 A135466 A135467

KEYWORD

nonn,base,easy

AUTHOR

David Applegate and njas, Feb 07 2008

page 1

Search completed in 0.002 seconds

Lookup | Welcome | Find friends | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
More pages | Superseeker | Maintained by N. J. A. Sloane (njas@research.att.com)

Last modified July 23 10:48 EDT 2008. Contains 142285 sequences.


AT&T Labs Research