login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A051533 Numbers that are the sum of two positive triangular numbers. 28
2, 4, 6, 7, 9, 11, 12, 13, 16, 18, 20, 21, 22, 24, 25, 27, 29, 30, 31, 34, 36, 37, 38, 39, 42, 43, 46, 48, 49, 51, 55, 56, 57, 58, 60, 61, 64, 65, 66, 67, 69, 70, 72, 73, 76, 79, 81, 83, 84, 87, 88, 90, 91, 92, 93, 94, 97, 99, 100, 101, 102, 106, 108 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

COMMENTS

Numbers n such that 8n+2 is in A085989. - Robert Israel, Mar 06 2017

LINKS

T. D. Noe, Table of n, a(n) for n = 1..1000

Eric Weisstein's World of Mathematics, Fermat's Polygonal Number Theorem

FORMULA

A053603(a(n)) > 0. - Reinhard Zumkeller, Jun 28 2013

A061336(a(n)) = 2. - M. F. Hasler, Mar 06 2017

EXAMPLE

666 is in the sequence because we can write 666 = 435 + 231 = binomial(22,2) + binomial(30,2).

MAPLE

isA051533 := proc(n)

    local a, ta;

    for a from 1 do

        ta := A000217(a) ;

        if 2*ta > n then

            return false;

        end if;

        if isA000217(n-ta) then

            return true;

        end if;

    end do:

end proc:

for n from 1 to 200 do

    if isA051533(n) then

        printf("%d, ", n) ;

    end if;

end do: # R. J. Mathar, Dec 16 2015

MATHEMATICA

f[k_] := If[!

   Head[Reduce[m (m + 1) + n (n + 1) == 2 k && 0 < m && 0 < n, {m, n},

       Integers]] === Symbol, k, 0]; DeleteCases[Table[f[k], {k, 1, 108}], 0] (* Ant King, Nov 22 2010 *)

nn=50; tri=Table[n(n+1)/2, {n, nn}]; Select[Union[Flatten[Table[tri[[i]]+tri[[j]], {i, nn}, {j, i, nn}]]], #<=tri[[-1]] &]

With[{nn=70}, Take[Union[Total/@Tuples[Accumulate[Range[nn]], 2]], nn]] (* Harvey P. Dale, Jul 16 2015 *)

PROG

(Haskell)

a051533 n = a051533_list !! (n-1)

a051533_list = filter ((> 0) . a053603) [1..]

-- Reinhard Zumkeller, Jun 28 2013

(PARI) is(n)=for(k=ceil((sqrt(4*n+1)-1)/2), (sqrt(8*n-7)-1)\2, if(ispolygonal(n-k*(k+1)/2, 3), return(1))); 0 \\ Charles R Greathouse IV, Jun 09 2015

CROSSREFS

Cf. A000217, A020756 (sums of two triangular numbers), A001481 (sums of two squares), A007294, A051611 (complement).

Cf. A061336: minimal number of triangular numbers that sum up to n.

Cf. A085989.

Sequence in context: A052056 A187974 A193715 * A186151 A184732 A039009

Adjacent sequences:  A051530 A051531 A051532 * A051534 A051535 A051536

KEYWORD

easy,nonn,nice

AUTHOR

Klaus Strassburger (strass(AT)ddfi.uni-duesseldorf.de)

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent | More pages
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified September 18 13:45 EDT 2018. Contains 315130 sequences. (Running on oeis4.)