[SeqFan] about A000217 sequence

50 views
Skip to first unread message

Jean Louis

unread,
Jul 6, 2026, 7:26:54 PM (7 days ago) Jul 6
to seq...@googlegroups.com
Hi,

I found a possible relation between the A000217 sequence and sum of two consecutive squares (part of Fermat's Christmas theorem).

The relation is with the form of sum of consecutives squares (s = x² + y² and y = x+1) for values (of s) ending by 13 (100z + 13 form, then z values are this sequence).


Greetings, JL.

Gareth McCaughan

unread,
Jul 6, 2026, 7:54:50 PM (7 days ago) Jul 6
to seq...@googlegroups.com

Yes, this thing is true. Rephrasing it more explicitly:

We're looking at f(n) := n^2 + (n+1)^2 = 2n^2 + 2n + 1 = 2n(n+1) + 1. If n is -2, -1, 0, 1, 2 mod 5 then f(n) is 0, 1, 1, 0, 3 mod 5.

Suppose n = 5m+2; then f(n) = 2(5m+2)(5m+3) + 1 = 50m(m+1) + 13 = 100 m(m+1)/2 + 13.

So for these values of n the values are obtained by 100 . triangular + 13.

I don't think this really has anything to do with Fermat's "Christmas theorem". Yes, you're taking a sum of two squares, but "sums of two squares" and "sums of two _consecutive_ squares" are very different things.

-- 
g

Daniel Mondot

unread,
Jul 6, 2026, 10:25:12 PM (7 days ago) Jul 6
to seq...@googlegroups.com
Interestingly, while there is a relationship between some sums of 2 consecutive squares and triangular numbers...
There is also a relationship between 2 consecutive triangular numbers and the squares.

And if you combine these 2 findings, you end up with: (5k-3)^2 + (5k-2)^2 + (5k+2)^2 + (5k+3)^2 = 100k^2 + 26  for any k.

There is also a relationship between the sums of 2 even triangular numbers and some squares (specifically 16n^2), see A016802.

Daniel.

--
You received this message because you are subscribed to the Google Groups "SeqFan" group.
To unsubscribe from this group and stop receiving emails from it, send an email to seqfan+un...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/seqfan/CACGMPepTZJBHjWVpkHobj8Gv5Qbw-UTzyBZAOU%2BnNpG%3D8f6XpA%40mail.gmail.com.

Jean Louis

unread,
Jul 7, 2026, 7:08:35 AM (7 days ago) Jul 7
to SeqFan
Hi Gareth and Daniel,

Thank you for your precisions, I added this conversation link to the Readme.
I continued working this night (for me in France) and see your messages this morning...

>> So for these values of n the values are obtained by 100 . triangular + 13.

Yes, I added a similar remark for that on second column paragraph (and s(k) = 100.T(k) + 40.k + 41)

>>  There is also a relationship between 2 consecutive triangular numbers and the squares. ...
Yes, I add a specific paragraph for these relationships !

Thank you both.

JL

----

Le mardi 7 juillet 2026 à 04:25:12 UTC+2, dmo...@gmail.com a écrit :
Interestingly, while there is a relationship between some sums of 2 consecutive squares and triangular numbers...
There is also a relationship between 2 consecutive triangular numbers and the squares.

And if you combine these 2 findings, you end up with: (5k-3)^2 + (5k-2)^2 + (5k+2)^2 + (5k+3)^2 = 100k^2 + 26  for any k.

There is also a relationship between the sums of 2 even triangular numbers and some squares (specifically 16n^2), see A016802.

Daniel.

Reply all
Reply to author
Forward
0 new messages