# A curious sum

franktaw at netscape.net franktaw at netscape.net
Tue May 27 01:08:13 CEST 2008

```Actually, this is pretty straightforward.  For
A002620(k) < m < A002620(k+1), m occurs once in the group
ending with A002620(k) (which is group number k-1) and in the
next group; and A002620(k) occurs in its own group and the
second one after.

I'm inclined to submit both sequences: the signed A002260, and
the cumulative sums.  Any suggestions or other comments?

-----Original Message-----
From: franktaw at netscape.net

Consider first the sequence which counts up to k (A002260):

1, 1,2, 1,2,3, 1,2,3,4, 1,2,3,4,5, 1,2,3,4,5,6, ...

Now, alternate the signs in  each group so that the final sign is
positive:

1, -1,2, 1,-2,3, -1,2,-3,4, 1,-2,3,-4,5, -1,2,-3,4,-5,6 ...

Take the cumulative sum of this sequence:

1, 0,2, 3,1,4, 3,5,2,6, 7,5,8,4,9, 8,10,7,11,6,12, ...

It appears that every positive integer occurs exactly twice in this
sequence (with 0 occurring only once).

(Note that the last elements of each group are the quarter-squares
(A002620), and the next to last elements are the same sequence, shifted
left by two.  These next to last elements are the minimum in the
group.)

Franklin,

You might consider cross-referencing your sequence to these others, also
related to A002260:

A014370 If n = binomial(b,2)+binomial(c,1), b>c>=0 then a(n) =
binomial(b+1,3)+binomial(c+1,2).

A051678 Square-pyramid-tree numbers: a(n)=sum(b(m),m=1..n), b(m)=1^2,
1^2,2^2, 1^2,2^2,3^2,..=(A002260)^2.

Note these also have the same parity as your sequence:

1,0,2,3,1,4,3,5,2,6,7,5,8,4,9,8,10,7,11,6,12,13,11,14,10,15,9,16,15,17,14,18
,13,19,12,20,21,19,22,18,23,17,24,16,25,24,26,23,27,22,28,21,29,20,30,

1,0,0,1,1,0,1,1,0,0,1,1,0,0,1,0,0,1,1,0,0,1,1,0,0,1,1,0,1,1,0,0,1,1,0,0,1,1,
0,0,1,1,0,0,1,0,0,1,1,0,0,1,1,0,0,

The run lengths in the parity sequence are:

1,2,2,1,2,2,2,2,1,2,2,2,2,2,2,1,2,2,2,2,2,2,2,2,1, ...

(not in the OEIS).

Regards,
Jeremy Gardiner

On 26/5/08 22:06, "franktaw at netscape.net" <franktaw at netscape.net> wrote:

> Consider first the sequence which counts up to k (A002260):
>
> 1, 1,2, 1,2,3, 1,2,3,4, 1,2,3,4,5, 1,2,3,4,5,6, ...
>
> Now, alternate the signs in  each group so that the final sign is
> positive:
>
> 1, -1,2, 1,-2,3, -1,2,-3,4, 1,-2,3,-4,5, -1,2,-3,4,-5,6 ...
>
> Take the cumulative sum of this sequence:
>
> 1, 0,2, 3,1,4, 3,5,2,6, 7,5,8,4,9, 8,10,7,11,6,12, ...
>

```