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

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A034706 Numbers which are sums of consecutive triangular numbers. 4
0, 1, 3, 4, 6, 9, 10, 15, 16, 19, 20, 21, 25, 28, 31, 34, 35, 36, 45, 46, 49, 52, 55, 56, 64, 66, 74, 78, 80, 81, 83, 84, 85, 91, 100, 105, 109, 110, 116, 119, 120, 121, 130, 136, 144, 145, 153, 155, 161, 164, 165, 166, 169, 171, 185, 190, 196, 199, 200, 202, 210 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,3

LINKS

Reinhard Zumkeller, Table of n, a(n) for n = 1..10000

MAPLE

isA034706 := proc(n)

    local a, b;

    for a from 0 do

        if a*(a+1)/2 > n then

            return false;

        end if;

        for b from a do

            tab := (1+b-a)*(a^2+b*a+a+b^2+2*b)/6 ;

            if tab = n then

                return true;

            elif tab > n then

                break;

            end if;

        end do:

    end do:

end proc:

for n from 0 to 100 do

    if isA034706(n) then

        printf("%d, ", n) ;

    end if;

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

PROG

(Haskell)

-- import Data.Set (deleteFindMin, union, fromList); import Data.List (inits)

a034706 n = a034706_list !! (n-1)

a034706_list = f 0 (tail $ inits $ a000217_list) (fromList [0]) where

   f x vss'@(vs:vss) s

     | y < x = y : f x vss' s'

     | otherwise = f w vss (union s $ fromList $ scanl1 (+) ws)

     where ws@(w:_) = reverse vs

           (y, s') = deleteFindMin s

-- Reinhard Zumkeller, May 12 2015

CROSSREFS

Complement gives A050941.

Cf. A000217, A034705, A269414.

Sequence in context: A005122 A166161 A130904 * A245810 A054686 A005214

Adjacent sequences:  A034703 A034704 A034705 * A034707 A034708 A034709

KEYWORD

nonn

AUTHOR

Erich Friedman

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 October 18 16:09 EDT 2018. Contains 316323 sequences. (Running on oeis4.)