# Integers of the form $a^2+b^2$ over real algebraic numbers

Assume $\alpha_{0},...,\alpha_{k}, \beta_{0},...,\beta_{j}, \gamma_{0},...,\gamma_{k}, \delta_{0},...,\delta_{j}$ are sets of indexed positive integers.

Assume also:

$$a=\sum_{i=0}^k (-1)^i\alpha_i^{\frac1\gamma_i}$$

$$b=\sum_{i=0}^j (-1)^i\beta_i^{\frac1\delta_i}$$

Under which non-trivial conditions $a^2+b^2$ is equal to a positive integer $n$?

Ok, the question as it is apparently doesn't meet the standards.

Given that the problem for natural numbers is quite simple and irreducible rationals cannot be generated by the sums, I'm talking about sums of radicals. I'm not immediately interested in complex extensions so the radicals will be evaluated to the positive branch or remain unevaluated until they meet a multiple or their additive inverse.

So the problem can be split into 2 questions.

1) More basic. When does a squared alternating finite sum of radicals generate an integer?

2) When does the sum of 2 squared alternating sums of radicals generate an integer?

First case. These sums considered singularly, once squared, can generate an integer IFF:

a) trivial. The terms are already integers OR

b) trivial. the terms consist of a single square root $(i.e. k = 0$ and $\gamma_0=2)$ OR

c) non-trivial @Vincent. For constant $\gamma$ the $\alpha$ terms' non common prime factors must have degree equal to a multiple of $\gamma$. The common prime factors of $\alpha$ terms must have degrees modulo $\gamma$ congruent to $m$ where $m=\gamma$ or $m=\frac{\gamma}{2}$

d) Here I stop because there seem to be a lot of other options and I can't figure out a way to characterize all of them.

Second case. Here we can say that the sum of 2 squared alternating series of radicals generates an integer IFF:

a) trivial. both the sums satisfy a condition of the previous point OR

b) Given expansions similar to $a = 2-\sqrt2$ and $b = 32^\frac14 = 2*2^\frac14$ we get an integer n despite both terms being irrational. And this strategy can apparently be used for much more intricate terms.

c) Here I stop too.

Every non-answering suggestion/comment regarding which approach could be more promising is appreciated too.

• Speaking of the first case, do you consider sums like $1^1$ and $1^1-2^1+4^{1/2}$ different? If not, then the story ends after (b). There is no other "OR". Sep 2, 2016 at 12:11
• Thanks Ivan but yes. The "hard" part is that I'm interested in the features of $\alpha, \gamma$ etc... and the indexes (or any other isomorphic parametrization) so while equivalent your sums derive from different expansions. Sep 2, 2016 at 12:47
• Then, in effect, you are asking when a sum of the said form is zero. Like, with $2^{1/2}+4^{1/4}-8^{1/2}$ as a non-trivial example. Well, then it's all about field extensions. You find out which field you are in, and collect the terms. Sep 2, 2016 at 13:38
• @Ivan Neretin I'll hopefully have the weekend to look into this and try to get what you mean with zero sum. However in a certain sense this reminds me of finding the n-th root of unity with fixed $n=2$ and the set of integers instead of 1. There you actually have to have sum zero for all the complex parts which typically consist of radicals. Sep 3, 2016 at 1:05

You can limit a lot the number of cases to explore by saying stuff like $\frac{\sqrt{3}}{\sqrt{2}}$ is not rational. This is the answer of this question : Linear independence of roots over Q. In simpler terms, it shows that the sum of roots of different primes with rational coefficients can never be anything but irrational or $0$.
This means that for $\gamma$ constant, either the non-rational terms of your sum cancel each other, or (exclusive or) $a$ is irrational (write the factorization into prime numbers of your $\alpha$s and you will see it).
If you dig around, you may find something concerning linear independence of roots of primes with different degrees ($\gamma$ not constant).
Then, regarding 2), you can apply the same thing by expanding your sum $(\sum_{i=1}^nx_i)^2 = \sum_{i=1}^n\sum_{j=1}^n x_ix_j$