The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A228158 Numbers n such that the cardinality of (natural numbers <=n with a first digit of 1) = n/2. 0
2, 16, 22, 176, 222, 1776, 2222, 17776, 22222, 177776, 222222, 1777776, 2222222, 17777776, 22222222, 177777776, 222222222, 1777777776, 2222222222, 17777777776, 22222222222, 177777777776, 222222222222, 1777777777776, 2222222222222, 17777777777776 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
COMMENTS
This is conceptually related to Benford's law.
LINKS
FORMULA
a(n) for odd values of n is simply "2" repeated (n+1)/2 times (sum as i=1->(n/2) of 10^(i-1)). For even values of n, it's a(n-1)*8.
G.f.: 2*(1+8*x)/((1-x)*(1+x)*(1-10*x^2)). [Joerg Arndt, Aug 14 2013]
PROG
(PARI) Vec(2*(1+8*x)/((1-x)*(1+x)*(1-10*x^2))+O(x^66)) \\ Joerg Arndt, Aug 14 2013
CROSSREFS
Sequence in context: A119599 A333475 A330611 * A330662 A337426 A295822
KEYWORD
base,easy,nonn
AUTHOR
Michael Turniansky, Aug 14 2013
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 May 14 14:46 EDT 2024. Contains 372533 sequences. (Running on oeis4.)