How to find the sum of the the first n elements in the series 1,2,4,5,7,8… as a function of n?

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
5
down vote

favorite
1












I see I can split it up into two arithmetic series (1,4,7... and 2,5,8...) and add the two sums, but what is the compact notation for the sum of these two series as a function of n?







share|cite|improve this question
















  • 9




    You should define your sequence clearly. I assume it's just the naturals less the multiples of $3$ but why make your readers guess? If I am correct, the answer is then the difference between a triangular number and three times another triangular number.
    – lulu
    Sep 2 at 3:50














up vote
5
down vote

favorite
1












I see I can split it up into two arithmetic series (1,4,7... and 2,5,8...) and add the two sums, but what is the compact notation for the sum of these two series as a function of n?







share|cite|improve this question
















  • 9




    You should define your sequence clearly. I assume it's just the naturals less the multiples of $3$ but why make your readers guess? If I am correct, the answer is then the difference between a triangular number and three times another triangular number.
    – lulu
    Sep 2 at 3:50












up vote
5
down vote

favorite
1









up vote
5
down vote

favorite
1






1





I see I can split it up into two arithmetic series (1,4,7... and 2,5,8...) and add the two sums, but what is the compact notation for the sum of these two series as a function of n?







share|cite|improve this question












I see I can split it up into two arithmetic series (1,4,7... and 2,5,8...) and add the two sums, but what is the compact notation for the sum of these two series as a function of n?









share|cite|improve this question











share|cite|improve this question




share|cite|improve this question










asked Sep 2 at 3:44









Ido Sarig

1313




1313







  • 9




    You should define your sequence clearly. I assume it's just the naturals less the multiples of $3$ but why make your readers guess? If I am correct, the answer is then the difference between a triangular number and three times another triangular number.
    – lulu
    Sep 2 at 3:50












  • 9




    You should define your sequence clearly. I assume it's just the naturals less the multiples of $3$ but why make your readers guess? If I am correct, the answer is then the difference between a triangular number and three times another triangular number.
    – lulu
    Sep 2 at 3:50







9




9




You should define your sequence clearly. I assume it's just the naturals less the multiples of $3$ but why make your readers guess? If I am correct, the answer is then the difference between a triangular number and three times another triangular number.
– lulu
Sep 2 at 3:50




You should define your sequence clearly. I assume it's just the naturals less the multiples of $3$ but why make your readers guess? If I am correct, the answer is then the difference between a triangular number and three times another triangular number.
– lulu
Sep 2 at 3:50










3 Answers
3






active

oldest

votes

















up vote
2
down vote



accepted










Let us first find the formula for even $n$. In this case, $m = n/2$ is a whole number, and moreover the sum of the first $n$ elements of your sequence is the sum of the first $m$ elements of the two arithmetic progressions, that is,
$$
m + 3fracm(m-1)2 + 2m + 3fracm(m-1)2 = 3 (m + m(m-1)) = frac3n^24.
$$



If $n$ is odd, then $n-1$ is even and we know that the sum of the first $n-1$ entries is $frac3(n-1)^24$. Moreover, the last entry in the sequence was the $((n-1)/2 + 1)$-st entry of the first arithmetic progression, that is $1,4,7,10, ldots$. But the value of that entry is $3 ((n-1)/2 + 1) - 2 = 3(n-1)/2 + 1$, so using the formula for the even case, the sum of the first $n$ entries equals
$$
frac3(n-1)^24 + 3(n-1)/2 + 1 = frac34 (n^2 - 2n + 2n + 1 - 2 + 4/3) = frac3n^24 + frac14.
$$






share|cite|improve this answer


















  • 1




    Thanks, I get it, But shouldn't that sentence read "If n is odd, then n−1 is even and we know that the sum of the first n−1 entries is [3⋅(n−1)]^2/4?.
    – Ido Sarig
    Sep 2 at 18:33







  • 1




    You're completely right. I don't know why I wrote that. Reloading the page should yield the corrected version.
    – AlgebraicsAnonymous
    Sep 2 at 18:36


















up vote
9
down vote













Your sequence $1,2,4,5,7,8,dots$ satisfies the second order nonhomogeneous linear recurrence
$$a_n=a_n-2+3$$
with initial values
$$a_1=1, a_2=2.$$
The solution is
$$a_n=frac6n-3-(-1)^n4.$$
The sum of the first $n$ terms is
$$sum_k=1^n a_k=frac34n^2+frac1-(-1)^n8=boxedfrac34n^2+frac1-cos npi8.$$






share|cite|improve this answer


















  • 1




    Did you guess this sequence or can you conclude this formula for $a_n$ once you notice it satisfies this second order nonhomogeneous linear recurrence?
    – Cornman
    Sep 2 at 4:11











  • Thanks. I am not familiar with such homogeneous equations. I think this is some valuable inside!
    – Cornman
    Sep 2 at 4:17






  • 4




    @bof $(-1)^n$ is usually considered the simpler, nicer form, especially in combinatorics.
    – mephistolotl
    Sep 2 at 6:46






  • 1




    @bof Don't you think $(-1)^n$ is good enough?
    – Szeto
    Sep 2 at 6:46






  • 2




    @bof Using an extra $cos$ does not make your answer bad.
    – Szeto
    Sep 2 at 8:39

















up vote
4
down vote













If you consider
$$a_k=1+3kqquad b_k=2+3k$$ then
$$sum_k=0^n a_k=sum_k=0^n (1+3k)=sum_k=0^n 1+3sum_k=0^n k=n+1+3 frac12 n (n+1)=frac12 (n+1) (3 n+2)$$
$$sum_k=0^n b_k=sum_k=0^n (2+3k)=2sum_k=0^n 1+3sum_k=0^n k=2(n+1)+3 frac12 n (n+1)=frac12 (n+1) (3 n+4)$$



Just continue.






share|cite|improve this answer




















    Your Answer




    StackExchange.ifUsing("editor", function ()
    return StackExchange.using("mathjaxEditing", function ()
    StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix)
    StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
    );
    );
    , "mathjax-editing");

    StackExchange.ready(function()
    var channelOptions =
    tags: "".split(" "),
    id: "69"
    ;
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function()
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled)
    StackExchange.using("snippets", function()
    createEditor();
    );

    else
    createEditor();

    );

    function createEditor()
    StackExchange.prepareEditor(
    heartbeatType: 'answer',
    convertImagesToLinks: true,
    noModals: false,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    noCode: true, onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    );



    );













     

    draft saved


    draft discarded


















    StackExchange.ready(
    function ()
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f2902318%2fhow-to-find-the-sum-of-the-the-first-n-elements-in-the-series-1-2-4-5-7-8-as%23new-answer', 'question_page');

    );

    Post as a guest






























    3 Answers
    3






    active

    oldest

    votes








    3 Answers
    3






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes








    up vote
    2
    down vote



    accepted










    Let us first find the formula for even $n$. In this case, $m = n/2$ is a whole number, and moreover the sum of the first $n$ elements of your sequence is the sum of the first $m$ elements of the two arithmetic progressions, that is,
    $$
    m + 3fracm(m-1)2 + 2m + 3fracm(m-1)2 = 3 (m + m(m-1)) = frac3n^24.
    $$



    If $n$ is odd, then $n-1$ is even and we know that the sum of the first $n-1$ entries is $frac3(n-1)^24$. Moreover, the last entry in the sequence was the $((n-1)/2 + 1)$-st entry of the first arithmetic progression, that is $1,4,7,10, ldots$. But the value of that entry is $3 ((n-1)/2 + 1) - 2 = 3(n-1)/2 + 1$, so using the formula for the even case, the sum of the first $n$ entries equals
    $$
    frac3(n-1)^24 + 3(n-1)/2 + 1 = frac34 (n^2 - 2n + 2n + 1 - 2 + 4/3) = frac3n^24 + frac14.
    $$






    share|cite|improve this answer


















    • 1




      Thanks, I get it, But shouldn't that sentence read "If n is odd, then n−1 is even and we know that the sum of the first n−1 entries is [3⋅(n−1)]^2/4?.
      – Ido Sarig
      Sep 2 at 18:33







    • 1




      You're completely right. I don't know why I wrote that. Reloading the page should yield the corrected version.
      – AlgebraicsAnonymous
      Sep 2 at 18:36















    up vote
    2
    down vote



    accepted










    Let us first find the formula for even $n$. In this case, $m = n/2$ is a whole number, and moreover the sum of the first $n$ elements of your sequence is the sum of the first $m$ elements of the two arithmetic progressions, that is,
    $$
    m + 3fracm(m-1)2 + 2m + 3fracm(m-1)2 = 3 (m + m(m-1)) = frac3n^24.
    $$



    If $n$ is odd, then $n-1$ is even and we know that the sum of the first $n-1$ entries is $frac3(n-1)^24$. Moreover, the last entry in the sequence was the $((n-1)/2 + 1)$-st entry of the first arithmetic progression, that is $1,4,7,10, ldots$. But the value of that entry is $3 ((n-1)/2 + 1) - 2 = 3(n-1)/2 + 1$, so using the formula for the even case, the sum of the first $n$ entries equals
    $$
    frac3(n-1)^24 + 3(n-1)/2 + 1 = frac34 (n^2 - 2n + 2n + 1 - 2 + 4/3) = frac3n^24 + frac14.
    $$






    share|cite|improve this answer


















    • 1




      Thanks, I get it, But shouldn't that sentence read "If n is odd, then n−1 is even and we know that the sum of the first n−1 entries is [3⋅(n−1)]^2/4?.
      – Ido Sarig
      Sep 2 at 18:33







    • 1




      You're completely right. I don't know why I wrote that. Reloading the page should yield the corrected version.
      – AlgebraicsAnonymous
      Sep 2 at 18:36













    up vote
    2
    down vote



    accepted







    up vote
    2
    down vote



    accepted






    Let us first find the formula for even $n$. In this case, $m = n/2$ is a whole number, and moreover the sum of the first $n$ elements of your sequence is the sum of the first $m$ elements of the two arithmetic progressions, that is,
    $$
    m + 3fracm(m-1)2 + 2m + 3fracm(m-1)2 = 3 (m + m(m-1)) = frac3n^24.
    $$



    If $n$ is odd, then $n-1$ is even and we know that the sum of the first $n-1$ entries is $frac3(n-1)^24$. Moreover, the last entry in the sequence was the $((n-1)/2 + 1)$-st entry of the first arithmetic progression, that is $1,4,7,10, ldots$. But the value of that entry is $3 ((n-1)/2 + 1) - 2 = 3(n-1)/2 + 1$, so using the formula for the even case, the sum of the first $n$ entries equals
    $$
    frac3(n-1)^24 + 3(n-1)/2 + 1 = frac34 (n^2 - 2n + 2n + 1 - 2 + 4/3) = frac3n^24 + frac14.
    $$






    share|cite|improve this answer














    Let us first find the formula for even $n$. In this case, $m = n/2$ is a whole number, and moreover the sum of the first $n$ elements of your sequence is the sum of the first $m$ elements of the two arithmetic progressions, that is,
    $$
    m + 3fracm(m-1)2 + 2m + 3fracm(m-1)2 = 3 (m + m(m-1)) = frac3n^24.
    $$



    If $n$ is odd, then $n-1$ is even and we know that the sum of the first $n-1$ entries is $frac3(n-1)^24$. Moreover, the last entry in the sequence was the $((n-1)/2 + 1)$-st entry of the first arithmetic progression, that is $1,4,7,10, ldots$. But the value of that entry is $3 ((n-1)/2 + 1) - 2 = 3(n-1)/2 + 1$, so using the formula for the even case, the sum of the first $n$ entries equals
    $$
    frac3(n-1)^24 + 3(n-1)/2 + 1 = frac34 (n^2 - 2n + 2n + 1 - 2 + 4/3) = frac3n^24 + frac14.
    $$







    share|cite|improve this answer














    share|cite|improve this answer



    share|cite|improve this answer








    edited Sep 2 at 18:36

























    answered Sep 2 at 5:28









    AlgebraicsAnonymous

    1,04512




    1,04512







    • 1




      Thanks, I get it, But shouldn't that sentence read "If n is odd, then n−1 is even and we know that the sum of the first n−1 entries is [3⋅(n−1)]^2/4?.
      – Ido Sarig
      Sep 2 at 18:33







    • 1




      You're completely right. I don't know why I wrote that. Reloading the page should yield the corrected version.
      – AlgebraicsAnonymous
      Sep 2 at 18:36













    • 1




      Thanks, I get it, But shouldn't that sentence read "If n is odd, then n−1 is even and we know that the sum of the first n−1 entries is [3⋅(n−1)]^2/4?.
      – Ido Sarig
      Sep 2 at 18:33







    • 1




      You're completely right. I don't know why I wrote that. Reloading the page should yield the corrected version.
      – AlgebraicsAnonymous
      Sep 2 at 18:36








    1




    1




    Thanks, I get it, But shouldn't that sentence read "If n is odd, then n−1 is even and we know that the sum of the first n−1 entries is [3⋅(n−1)]^2/4?.
    – Ido Sarig
    Sep 2 at 18:33





    Thanks, I get it, But shouldn't that sentence read "If n is odd, then n−1 is even and we know that the sum of the first n−1 entries is [3⋅(n−1)]^2/4?.
    – Ido Sarig
    Sep 2 at 18:33





    1




    1




    You're completely right. I don't know why I wrote that. Reloading the page should yield the corrected version.
    – AlgebraicsAnonymous
    Sep 2 at 18:36





    You're completely right. I don't know why I wrote that. Reloading the page should yield the corrected version.
    – AlgebraicsAnonymous
    Sep 2 at 18:36











    up vote
    9
    down vote













    Your sequence $1,2,4,5,7,8,dots$ satisfies the second order nonhomogeneous linear recurrence
    $$a_n=a_n-2+3$$
    with initial values
    $$a_1=1, a_2=2.$$
    The solution is
    $$a_n=frac6n-3-(-1)^n4.$$
    The sum of the first $n$ terms is
    $$sum_k=1^n a_k=frac34n^2+frac1-(-1)^n8=boxedfrac34n^2+frac1-cos npi8.$$






    share|cite|improve this answer


















    • 1




      Did you guess this sequence or can you conclude this formula for $a_n$ once you notice it satisfies this second order nonhomogeneous linear recurrence?
      – Cornman
      Sep 2 at 4:11











    • Thanks. I am not familiar with such homogeneous equations. I think this is some valuable inside!
      – Cornman
      Sep 2 at 4:17






    • 4




      @bof $(-1)^n$ is usually considered the simpler, nicer form, especially in combinatorics.
      – mephistolotl
      Sep 2 at 6:46






    • 1




      @bof Don't you think $(-1)^n$ is good enough?
      – Szeto
      Sep 2 at 6:46






    • 2




      @bof Using an extra $cos$ does not make your answer bad.
      – Szeto
      Sep 2 at 8:39














    up vote
    9
    down vote













    Your sequence $1,2,4,5,7,8,dots$ satisfies the second order nonhomogeneous linear recurrence
    $$a_n=a_n-2+3$$
    with initial values
    $$a_1=1, a_2=2.$$
    The solution is
    $$a_n=frac6n-3-(-1)^n4.$$
    The sum of the first $n$ terms is
    $$sum_k=1^n a_k=frac34n^2+frac1-(-1)^n8=boxedfrac34n^2+frac1-cos npi8.$$






    share|cite|improve this answer


















    • 1




      Did you guess this sequence or can you conclude this formula for $a_n$ once you notice it satisfies this second order nonhomogeneous linear recurrence?
      – Cornman
      Sep 2 at 4:11











    • Thanks. I am not familiar with such homogeneous equations. I think this is some valuable inside!
      – Cornman
      Sep 2 at 4:17






    • 4




      @bof $(-1)^n$ is usually considered the simpler, nicer form, especially in combinatorics.
      – mephistolotl
      Sep 2 at 6:46






    • 1




      @bof Don't you think $(-1)^n$ is good enough?
      – Szeto
      Sep 2 at 6:46






    • 2




      @bof Using an extra $cos$ does not make your answer bad.
      – Szeto
      Sep 2 at 8:39












    up vote
    9
    down vote










    up vote
    9
    down vote









    Your sequence $1,2,4,5,7,8,dots$ satisfies the second order nonhomogeneous linear recurrence
    $$a_n=a_n-2+3$$
    with initial values
    $$a_1=1, a_2=2.$$
    The solution is
    $$a_n=frac6n-3-(-1)^n4.$$
    The sum of the first $n$ terms is
    $$sum_k=1^n a_k=frac34n^2+frac1-(-1)^n8=boxedfrac34n^2+frac1-cos npi8.$$






    share|cite|improve this answer














    Your sequence $1,2,4,5,7,8,dots$ satisfies the second order nonhomogeneous linear recurrence
    $$a_n=a_n-2+3$$
    with initial values
    $$a_1=1, a_2=2.$$
    The solution is
    $$a_n=frac6n-3-(-1)^n4.$$
    The sum of the first $n$ terms is
    $$sum_k=1^n a_k=frac34n^2+frac1-(-1)^n8=boxedfrac34n^2+frac1-cos npi8.$$







    share|cite|improve this answer














    share|cite|improve this answer



    share|cite|improve this answer








    edited Sep 2 at 5:32

























    answered Sep 2 at 4:08









    bof

    46.7k349113




    46.7k349113







    • 1




      Did you guess this sequence or can you conclude this formula for $a_n$ once you notice it satisfies this second order nonhomogeneous linear recurrence?
      – Cornman
      Sep 2 at 4:11











    • Thanks. I am not familiar with such homogeneous equations. I think this is some valuable inside!
      – Cornman
      Sep 2 at 4:17






    • 4




      @bof $(-1)^n$ is usually considered the simpler, nicer form, especially in combinatorics.
      – mephistolotl
      Sep 2 at 6:46






    • 1




      @bof Don't you think $(-1)^n$ is good enough?
      – Szeto
      Sep 2 at 6:46






    • 2




      @bof Using an extra $cos$ does not make your answer bad.
      – Szeto
      Sep 2 at 8:39












    • 1




      Did you guess this sequence or can you conclude this formula for $a_n$ once you notice it satisfies this second order nonhomogeneous linear recurrence?
      – Cornman
      Sep 2 at 4:11











    • Thanks. I am not familiar with such homogeneous equations. I think this is some valuable inside!
      – Cornman
      Sep 2 at 4:17






    • 4




      @bof $(-1)^n$ is usually considered the simpler, nicer form, especially in combinatorics.
      – mephistolotl
      Sep 2 at 6:46






    • 1




      @bof Don't you think $(-1)^n$ is good enough?
      – Szeto
      Sep 2 at 6:46






    • 2




      @bof Using an extra $cos$ does not make your answer bad.
      – Szeto
      Sep 2 at 8:39







    1




    1




    Did you guess this sequence or can you conclude this formula for $a_n$ once you notice it satisfies this second order nonhomogeneous linear recurrence?
    – Cornman
    Sep 2 at 4:11





    Did you guess this sequence or can you conclude this formula for $a_n$ once you notice it satisfies this second order nonhomogeneous linear recurrence?
    – Cornman
    Sep 2 at 4:11













    Thanks. I am not familiar with such homogeneous equations. I think this is some valuable inside!
    – Cornman
    Sep 2 at 4:17




    Thanks. I am not familiar with such homogeneous equations. I think this is some valuable inside!
    – Cornman
    Sep 2 at 4:17




    4




    4




    @bof $(-1)^n$ is usually considered the simpler, nicer form, especially in combinatorics.
    – mephistolotl
    Sep 2 at 6:46




    @bof $(-1)^n$ is usually considered the simpler, nicer form, especially in combinatorics.
    – mephistolotl
    Sep 2 at 6:46




    1




    1




    @bof Don't you think $(-1)^n$ is good enough?
    – Szeto
    Sep 2 at 6:46




    @bof Don't you think $(-1)^n$ is good enough?
    – Szeto
    Sep 2 at 6:46




    2




    2




    @bof Using an extra $cos$ does not make your answer bad.
    – Szeto
    Sep 2 at 8:39




    @bof Using an extra $cos$ does not make your answer bad.
    – Szeto
    Sep 2 at 8:39










    up vote
    4
    down vote













    If you consider
    $$a_k=1+3kqquad b_k=2+3k$$ then
    $$sum_k=0^n a_k=sum_k=0^n (1+3k)=sum_k=0^n 1+3sum_k=0^n k=n+1+3 frac12 n (n+1)=frac12 (n+1) (3 n+2)$$
    $$sum_k=0^n b_k=sum_k=0^n (2+3k)=2sum_k=0^n 1+3sum_k=0^n k=2(n+1)+3 frac12 n (n+1)=frac12 (n+1) (3 n+4)$$



    Just continue.






    share|cite|improve this answer
























      up vote
      4
      down vote













      If you consider
      $$a_k=1+3kqquad b_k=2+3k$$ then
      $$sum_k=0^n a_k=sum_k=0^n (1+3k)=sum_k=0^n 1+3sum_k=0^n k=n+1+3 frac12 n (n+1)=frac12 (n+1) (3 n+2)$$
      $$sum_k=0^n b_k=sum_k=0^n (2+3k)=2sum_k=0^n 1+3sum_k=0^n k=2(n+1)+3 frac12 n (n+1)=frac12 (n+1) (3 n+4)$$



      Just continue.






      share|cite|improve this answer






















        up vote
        4
        down vote










        up vote
        4
        down vote









        If you consider
        $$a_k=1+3kqquad b_k=2+3k$$ then
        $$sum_k=0^n a_k=sum_k=0^n (1+3k)=sum_k=0^n 1+3sum_k=0^n k=n+1+3 frac12 n (n+1)=frac12 (n+1) (3 n+2)$$
        $$sum_k=0^n b_k=sum_k=0^n (2+3k)=2sum_k=0^n 1+3sum_k=0^n k=2(n+1)+3 frac12 n (n+1)=frac12 (n+1) (3 n+4)$$



        Just continue.






        share|cite|improve this answer












        If you consider
        $$a_k=1+3kqquad b_k=2+3k$$ then
        $$sum_k=0^n a_k=sum_k=0^n (1+3k)=sum_k=0^n 1+3sum_k=0^n k=n+1+3 frac12 n (n+1)=frac12 (n+1) (3 n+2)$$
        $$sum_k=0^n b_k=sum_k=0^n (2+3k)=2sum_k=0^n 1+3sum_k=0^n k=2(n+1)+3 frac12 n (n+1)=frac12 (n+1) (3 n+4)$$



        Just continue.







        share|cite|improve this answer












        share|cite|improve this answer



        share|cite|improve this answer










        answered Sep 2 at 4:16









        Claude Leibovici

        113k1155127




        113k1155127



























             

            draft saved


            draft discarded















































             


            draft saved


            draft discarded














            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f2902318%2fhow-to-find-the-sum-of-the-the-first-n-elements-in-the-series-1-2-4-5-7-8-as%23new-answer', 'question_page');

            );

            Post as a guest













































































            Comments

            Popular posts from this blog

            What does second last employer means? [closed]

            List of Gilmore Girls characters

            Confectionery