cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A358439 Number of even digits necessary to write all positive n-digit integers.

This page as a plain text file.
%I A358439 #37 Mar 31 2024 17:11:04
%S A358439 4,85,1300,17500,220000,2650000,31000000,355000000,4000000000,
%T A358439 44500000000,490000000000,5350000000000,58000000000000,
%U A358439 625000000000000,6700000000000000,71500000000000000,760000000000000000,8050000000000000000,85000000000000000000,895000000000000000000
%N A358439 Number of even digits necessary to write all positive n-digit integers.
%C A358439 If nonnegative n-digit integers were considered, then a(1) would be 5.
%C A358439 Also, a(n) is the total number of holes in all positive n-digit integers, assuming 4 has no hole. Digits 0, 6 and 9 have 1 hole, digit 8 has 2 holes, and other digits have no holes or (circular) loops (as in A064532).
%C A358439 Proof of the first formula: For n>=2, to write all positive n-digit integers, digits 6, 8, 9 occur A081045(n-1) = (9n+1)*10^(n-2) times each, and digit 0 occurs A212704(n-1) = 9*(n-1)*10^(n-2) times; so a(n) = 4*A081045(n-1) + A212704(n-1).
%C A358439 For a(1), if 0 were included then there would be 5 holes in the 1-digit numbers 0..9.
%H A358439 <a href="/index/Rec#order_02">Index entries for linear recurrences with constant coefficients</a>, signature (20,-100).
%F A358439 a(n) = 5*(9n-1)*10^(n-2).
%F A358439 Formulas coming from the name with even digits:
%F A358439 a(n) = A358854(10^n-1) - A358854(10^(n-1)-1).
%F A358439 a(n) = A113119(n) - A359271(n) for n >= 2.
%F A358439 Formula coming from the comment with holes:
%F A358439 a(n) = Sum_{k=10^(n-1)..10^n-1} A064532(k).
%e A358439 To write the integers from 10 up to 99, each of the digits 2, 4, 6 and 8 must be used 19 times, and digit 0 must be used 9 times hence a(2) = 4*19 + 9 = 85.
%p A358439 seq((5*(9*n-1))*10^(n-2), n = 1 .. 30);
%t A358439 a[n_] := 5*(9*n - 1)*10^(n - 2); Array[a, 22] (* _Amiram Eldar_, Nov 16 2022 *)
%Y A358439 Cf. A064532, A081045, A212704.
%Y A358439 Cf. A113119, A196563, A358854, A359271.
%K A358439 nonn,base,easy
%O A358439 1,1
%A A358439 _Bernard Schott_, Nov 16 2022