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.

A135558 Sums of three distinct nonzero Fibonacci numbers.

This page as a plain text file.
%I A135558 #19 Jul 06 2025 15:19:24
%S A135558 6,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,
%T A135558 31,32,34,35,36,37,38,39,40,41,42,43,44,45,47,48,49,50,52,55,56,57,58,
%U A135558 59,60,61,62,63,64,65,66,68,69,70,71,73,76,77,78,79,81,84,89,90,91,92,93,94,95
%N A135558 Sums of three distinct nonzero Fibonacci numbers.
%C A135558 These numbers may have more than one such representation.
%H A135558 R. J. Mathar, <a href="/A135558/b135558.txt">Table of n, a(n) for n = 1..1000</a>
%H A135558 Colm Mulcahy, <a href="http://www.maa.org/community/maa-columns/past-columns-card-colm/additional-certainties">Additional Certainties</a>, February 2008.
%p A135558 isA135558 := proc(n) # returns true if n is in the sequence
%p A135558     local xi,yi,x,y,z ;
%p A135558     for xi from 2 do
%p A135558         x := A000045(xi) ;
%p A135558         if 3*x > n then
%p A135558             return false;
%p A135558         end if;
%p A135558         for yi from xi+1 do
%p A135558             y := A000045(yi) ;
%p A135558             if x+2*y > n then
%p A135558                 break;
%p A135558             else
%p A135558                 z := n-x-y ;
%p A135558                 if z >y and isA000045(z) then # see isFib in A000045
%p A135558                     return true;
%p A135558                 end if;
%p A135558             end if;
%p A135558         end do:
%p A135558     end do:
%p A135558 end proc:
%p A135558 A135558 := proc(n)
%p A135558     option remember;
%p A135558     local a;
%p A135558     if n = 1 then
%p A135558         6;
%p A135558     else
%p A135558         for a from procname(n-1)+1 do
%p A135558             if isA135558(a) then
%p A135558                 return a;
%p A135558             end if;
%p A135558         end do:
%p A135558     end if;
%p A135558 end proc: # _R. J. Mathar_, Sep 09 2015
%t A135558 fibs[n_ /; n >= 6] := Reap[Module[{k = 1}, While[Fibonacci[k] < n, Sow[Fibonacci[k++]]]]][[2, 1]];
%t A135558 okQ[n_] := AnyTrue[IntegerPartitions[n, {3}, fibs[n]], Length[Union[#]] == 3&];
%t A135558 Select[Range[6, 100], okQ] (* _Jean-François Alcover_, Dec 12 2023 *)
%t A135558 Select[Total/@Subsets[Fibonacci[Range[2,12]],{3}]//Union,#<=100&] (* _Harvey P. Dale_, Jul 06 2025 *)
%Y A135558 Cf. A000045, A135709 (Complement).
%K A135558 nonn
%O A135558 1,1
%A A135558 _Colm Mulcahy_, Feb 23 2008, Mar 02 2008
%E A135558 More terms from _N. J. A. Sloane_, Mar 01 2008, corrected Mar 05 2008