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.

A164820 Numbers n such that n-th digit (after decimal point) of e and of Euler-Mascheroni constant gamma are the same.

This page as a plain text file.
%I A164820 #13 Sep 08 2022 08:45:47
%S A164820 4,30,33,34,48,49,52,59,60,66,96,113,115,134,146,155,163,169,175,180,
%T A164820 193,196,200,206,211,235,251,274,288,300,302,304,330,336,338,350,354,
%U A164820 358,368,373,381,399,412,419,430,436,438,440,491,506,536,542,552,579
%N A164820 Numbers n such that n-th digit (after decimal point) of e and of Euler-Mascheroni constant gamma are the same.
%H A164820 Harvey P. Dale, <a href="/A164820/b164820.txt">Table of n, a(n) for n = 1..1000</a>
%e A164820 e = 2.7182818284..., gamma = 0.5772156649...; fourth digit of e and fourth digit of gamma are both 2, hence 4 is in the sequence.
%p A164820 P:=proc(i) local a,b,c,d,n; a:=convert(evalf(gamma,1000),string); b:=convert(evalf(exp(1)-2,1000),string); for n from 2 by 1 to i do if substring(a,n)=substring(b,n) then print(n-1); fi; od; end: P(900);
%t A164820 With[{nn=600},Position[Thread[{Rest[RealDigits[E,10,nn+1][[1]]], RealDigits[ EulerGamma,10,nn][[1]]}],{x_,x_}]]//Flatten (* _Harvey P. Dale_, Oct 08 2017 *)
%o A164820 (Magma) m:=600; e:=Exp(One(RealField(m+1))); se:=IntegerToString(Round(10^m*(e-2))); g:=EulerGamma(RealField(m)); sg:=IntegerToString(Round(10^m*g)); [ a: a in [1..m] | se[a] eq sg[a] ]; // _Klaus Brockhaus_, Sep 03 2009
%Y A164820 Cf. A068394, A164819.
%K A164820 easy,nonn,base
%O A164820 1,1
%A A164820 _Paolo P. Lava_ and _Giorgio Balzarotti_, Aug 27 2009
%E A164820 Edited and listed terms verified by _Klaus Brockhaus_, Sep 03 2009