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.

A161885 Smallest k such that n^5 = a_1^5+...+a_k^5 and all a_i are positive integers less than n.

This page as a plain text file.
%I A161885 #31 Feb 16 2025 08:33:10
%S A161885 32,26,19,18,14,12,9,11,9,13,6,12,8,10,9,8,10,10,9,10,10,7,6,9,7,9,8,
%T A161885 9,6,9,6,8,7,7,6,8,7,8,7,7,7,9,8,9,7,8,6,7,8,7,7,7,7,7,7,7,7,7,6,7,7,
%U A161885 7,6,8,8,6,7,7,7,7,5,7,7,7,7,8,6,7,7,7,7,7,6,7,7,7,7,7,6,7,7,7,5,7,6,7,7,6,7
%N A161885 Smallest k such that n^5 = a_1^5+...+a_k^5 and all a_i are positive integers less than n.
%C A161885 Based on Fermat's Last Theorem: 2 never occurs in this sequence. It is not known whether 3 occurs in this sequence. The first time 4 occurs is for 144^5=27^5+84^5+110^5+133^5.
%C A161885 The first time 5, 6, 7, 8, 9, 10 occur is for n=73, 12, 23, 14, 8, 15; see sequence A252485. - _M. F. Hasler_, Dec 17 2014
%H A161885 Giovanni Resta, <a href="/A161885/b161885.txt">Table of n, a(n) for n = 2..400</a>
%H A161885 Jean-Charles Meyrignac, <a href="http://euler.free.fr/">Computing Minimal Equal Sums Of Like Powers</a>
%H A161885 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/DiophantineEquation5thPowers.html">Diophantine Equation 5th Powers</a>
%e A161885 a(29) = 9 since 29^5 = 5^5 + 9^5 + 10^5 + 10^5 + 10^5 + 15^5 + 15^5 + 17^5 + 28^5, and there is no sum of less than 9 fifth powers equal to 26^5;
%e A161885 a(30) = 6 since 30^5 = 5^5 + 10^5 + 11^5 + 16^5 + 19^5 + 29^5;
%e A161885 a(72) = 5 since 72^5 = 19^5 + 43^5 + 46^5 + 47^5 + 67^5. - _M. F. Hasler_, Dec 17 2014
%o A161885 (PARI) a(n,verbose=0,m=5)={N=n^m;for(k=3,32,forvec(v=vector(k-1,i,[1,n\sqrtn(k+1-i,m)]),ispower(N-sum(i=1,k-1,v[i]^m),m,&K)&&K>0&&!(verbose&&print1("/*"n" "v"*/"))&&return(k),1))} \\ _M. F. Hasler_, Dec 17 2014
%o A161885 (PARI) a(n)={
%o A161885     my(N=n^5,k=3);
%o A161885     while(1,
%o A161885         my(v=vector(k-1,i,[sqrtnint(max((N-(k-i)*(n-1)^5-1)\i,0),5)+1,sqrtnint((N-i+1)\(k-i+1),5)]));
%o A161885         forvec(x=v,
%o A161885             my(s=N-sum(i=1,#x,x[i]^5));
%o A161885             if(s>0 && ispower(s,5), return(k))
%o A161885         ,
%o A161885             1
%o A161885         );
%o A161885         k++
%o A161885     );
%o A161885 }; \\ _Charles R Greathouse IV_, Dec 18 2014
%Y A161885 Cf. A161882, A161883, A161884.
%K A161885 nonn
%O A161885 2,1
%A A161885 _Dmitry Kamenetsky_, Jun 21 2009
%E A161885 a(43)-a(83) from _M. F. Hasler_, Dec 17 2014
%E A161885 a(77) corrected by _Charles R Greathouse IV_, Dec 19 2014
%E A161885 a(84)-a(100) from _Charles R Greathouse IV_, Dec 19 2014