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.

A173667 Number of real zeros of the polynomial whose coefficients are the decimal expansion of n.

This page as a plain text file.
%I A173667 #14 Aug 01 2024 14:12:56
%S A173667 0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
%T A173667 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
%U A173667 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,0,0,0,0,0,0,0,0,0,2,0,0
%N A173667 Number of real zeros of the polynomial whose coefficients are the decimal expansion of n.
%C A173667 From the example a(121)=2, P(121,x)=(x+1)^2, it is seen that the roots are counted with multiplicity. For n=0, the polynomial would be P=0 with infinitely many real roots. - _M. F. Hasler_, Nov 24 2010
%C A173667 a(n) is the number of real zeros of the polynomial P(n,x) = Sum_{k=0..p} d(k)
%C A173667   x^k where d(k) are the digits of the decimal expansion of n = d(p) d(p-1)...d(0), n =0,1,2,...
%e A173667 a(121) = 2 because 1+2x+x^2 = 0 has 2 real roots.
%e A173667 a(1597200)=6 because x^6 + 5x^5 + 9x^4+7x^3+2x^2 = x^2 (x+2)(x+1)^3 has 6 real roots.
%p A173667 with(numtheory):T:=array(1..10000000): x2:=0: printf(`%d, `, x2):for n from
%p A173667   1 to 300 do: for i from 1 to 8 do: T[i]:=0:od: l:=length(n) : n0:=n:for m from
%p A173667   1 to l do:q:=n0:u:=irem(q,10):v:=iquo(q,10):n0:=v :u: T[m]:=u:od:x:=fsolve(T[1]+
%p A173667   T[2]*z + T[3]*z^2+ T[4]*z^3+ T[5]*z^4 + T[6]*z^5 + T[7]*z^6 + T[8]*z^7, z, real):x1:=[x]: x2:=nops(x1): printf(`%d, `, x2):od:
%o A173667 (PARI) A173667(n)=sum(k=1,#n=factor(1.*Pol(eval(Vec(Str(n)))))~,(poldegree(n[1,k])==1)*n[2,k] ) /* factorization over the reals => linear factor for each root. poldegree()==1 could be replaced by poldisc()>=0 */ \\ _M. F. Hasler_, Nov 25 2010
%K A173667 nonn,base
%O A173667 1,100
%A A173667 _Michel Lagneau_, Nov 24 2010