I really like Fermat's theorem on sums of two squares... and its proof probably requires the Brahmagupta–Fibonacci identity (or by another name, Diophantus identity), so I like that as well. When looking at this identity and its generalizations, it has come to my mind that I may be able to generalize it as well, or at least discover something similar. The Brahmagupta-Fibonacci identity says that the product of two integers that are each expressible as the sums of two squares, so this product is also expressible as the sums of two squares. This can be checked by practicing basic algebra:
(a²+b²)(c²+d²) = (ac-bd)²+(ad+bc)² = (ac+bd)²+(ad-bc)²
Brahmagupta actually knew a more general identity:
(a²+nb²)(c²+nd²) = (ac-nbd)²+n(ad+bc)² = (ac+nbd)²+n(ad-bc)²
So I made the conjecture that the product of two integers that are each expressible as (x²+xy+y²), for different integer values of x and y, so this product is also expressible as (x²+xy+y²) for some integer values of x and y. My conjecture was justified by checking it for small values of x and y. But it was harder to prove the conjecture, as I had no formula to check. However, by looking at many examples, I managed to guess the formula, so I could check it then:
(a²+ab+b²)(c²+cd+d²) = (bd-ac)²+(bd-ac)(ad+bc+ac)+(ad+bc+ac)² = e²+ef+f²
where:
e = bd-ac and f =ad+bc+ac
Then I was thinking about how useful this result might be... and I have also checked WikiPedia more, maybe I find something about it... and I've found! Actually, Gauss and Lagrange were working on something even more general, i.e. (integral) binary quadratic forms, so they probably also knew what I "discovered" here. Still, it was good to take care of it, as this feels better than solving crossword puzzles, for example.
By the way, I also checked numbers of the form x²-xy+y², and I have found that:
- They are always positive or zero, as when xy is positive, then either x²>xy or y²>xy
- They are exactly the same numbers as those of the form u²+uw+w², because we can convert them this way: x²-xy+y² = (-x)²+(-x)y+y² = u²+uw+w² where u=(-x) and w=y. Still, it is interesting that they also seem to be the same numbers for only non-negative values of x, y, u and w.