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.

A231787 Count of the first 10^n primes containing at least one 1's digit.

This page as a plain text file.
%I A231787 #10 Sep 27 2019 11:26:58
%S A231787 4,46,468,5325,65575,737451,7948534,83168848,844383541,8470537436,
%T A231787 85169381579
%N A231787 Count of the first 10^n primes containing at least one 1's digit.
%F A231787 a(n) ~ 10^n. - _Charles R Greathouse IV_, May 21 2014
%e A231787 a(1)=4 because there are 4 primes not greater than 29 (the 10th prime) that contain a 1's digit.  Namely: 11, 13, 17, 19.
%t A231787 cnt = 0; Table[Do[p = Prime[k]; If[MemberQ[IntegerDigits[p], 1], cnt++], {k, 10^(n - 1) + 1, 10^n}]; cnt, {n, 5}] (* _T. D. Noe_, Nov 13 2013 *)
%t A231787 Module[{nn=7,p},p=Table[If[DigitCount[p,10,1]>0,1,0],{p,Prime[ Range[ 10^nn]]}];Table[Total[Take[p,10^k]],{k,nn}]] (* The program generates the first 7 terms of the sequence; to generate more, increase the value of nn but the program may take a long time to run. *) (* _Harvey P. Dale_, Sep 27 2019 *)
%Y A231787 Cf. A231726-A231790, A231792-A231796, A091634-A091643, A231412, A228413-A228421.
%K A231787 more,nonn,base
%O A231787 1,1
%A A231787 _Robert Price_, Nov 13 2013