# Conjecture on the square root of the sum of the squares of the prime factors of a number

Let $A_{n}$ denote the square root of the sum of the squares of the prime factors of $n$.

For example, $A_{60}=\sqrt{2^2+2^2+3^2+5^2}\approx6.48$.

I have recently made the following observations:

• There does not exist $n$ such that $A_{n},A_{n+1},A_{n+2},A_{n+3}$ are all integers
• There does not exist $n$ such that $A_{n},A_{n+1},A_{n+2}$ are all non-prime integers

I tested these statements up to 1.2 billion, and both of them seemed to withstand.

I am basically trying to find out if either one of them has already been conjectured, proved or refuted.

I have previously posted this question on Mathematics.

The original (and much longer) version can be found here.

My initial motivation was to depict every natural number as an $n$-dimensional rectangle with measures given by its prime-factorization, and then observe the ones which yield diagonal of an integer length.

Soon thereafter, it came clear to me that sequences of consecutive such numbers were rather sporadic. An example of a sequence of $3$ consecutive such numbers which yield diagonal of an integer length:

• $A_{2729}=\sqrt{2729^2}=2729$
• $A_{2730}=\sqrt{2^2+3^2+5^2+7^2+13^2}=16$
• $A_{2731}=\sqrt{2731^2}=2731$

The only answer I received gave a probabilistic argument to the fact that both conjectures are (probably) false, which I more or less understand, but I would nevertheless like to obtain a more absolute resolution.

UPDATE:

Checking up to $2$ billion, I have counted $1585$ triplets:

• The trivial triplet $1-2-3$
• $2$ triplets of the form $C-C-P$
• $4$ triplets of the form $P-C-C$
• $7$ triplets of the form $C-P-C$
• $1571$ triplets of the form $P-C-P$

I have also encountered the following quadruplet, which refutes the first conjecture:

• $A_{1776463301}=\sqrt{1776463301^2}=1776463301$
• $A_{1776463302}=\sqrt{2^2+3^2+173^2+857^2+1997}=2180$
• $A_{1776463303}=\sqrt{1776463303^2}=1776463303$
• $A_{1776463304}=\sqrt{2^2+2^2+2^2+7^2+11^2+179^2+16111}=16112$

UPDATE #$2$:

Up to $4$ billion, I have counted $28$ pairs of consecutive non-primes which yield integer-length diagonals, but I have not encountered a single triplet of consecutive non-primes which yield integer-length diagonals.

• What about n=0? – The Masked Avenger Jan 6 '15 at 16:13
• @TheMaskedAvenger: There are infinitely many prime factors of $0$, so in essence, $A_0=\infty$. IMHO, the prime-factorization of $0$ is not well defined, and therefore, so is $A_0$. We can argue about this of course, but the purpose of my description was to provide the question in a concise manner, as clean and simple as possible. Adding the notion on $0$ would just make the users obliged to read an additional two or three sentences, which in my opinion is not required. I believe that the motivation of the question is clear enough without it. Thank you. – barak manos Jan 6 '15 at 16:43
• I think adding the triplet near the link will encourage other readers to follow the link, especially if one knows that Greg Martin rendered an opinion on the problem. – The Masked Avenger Jan 6 '15 at 19:06
• Relevant OEIS entry: oeis.org/A067666 – Max Alekseyev Jan 7 '15 at 10:35
• No, I am counting repeats. Squares are 0 or 1 mod 4, so if the sum of squares is a square, there can't be (say) exactly 6 odd squares in the sum. Regarding bitlength, if n=pq with p large enough, q^2 smaller than 2p, p^2 + q^2 will be smaller than (p+1)^2, and again A_n will not be integral. – The Masked Avenger Jan 9 '15 at 18:22

It may be of interest to consider in general when A=A_n is integral. I will assume n is given and drop the subscript.

A is integral when n =p^k, for p prime and k a square.

A integral and n composite means n has (counting multiplicity) at least 4 prime factors.

Let m be a positive integer. There are integers a and b with b one of 1,3 , 9 such that mb2^a =n and A is integral. b could also be a prime or the square of a prime. It is possible that 2^a may be replaceable by p^a but I haven't thought much about it.

In all, it seems the answer given in the other thread has a plausible argument for both conjectures being negative, and the setup guarantees few if any small counterexamples. Finding a sequence of 5 composite consecutive n giving integral A seems natural; such n having as few as four prime factors in addition seems highly unlikely.

• The expression "few if any counterexamples" is a bit problematic here, because if there aren't any counterexamples then the conjecture is true, right? – barak manos Jan 9 '15 at 20:57
• In addition, I don't quite understand the last statement: "a sequence of $5$ composite consecutive $n$... such $n$ having as few as four prime factors". There are $5$ different n's here: $n,n+1,n+2,n+3,n+4$. Do you refer to each one of them in that statement, or only to the first one (in which case, the others will not yield an integer value)? – barak manos Jan 9 '15 at 21:05
• I'm sorry for being unclear. I'm with Greg in thinking there are arbitrarily long sequences of integers n which are intervals of integers with no primes, and all of whose A values are integral. I would be surprised to find an interval of 5 such numbers below 10^20. – The Masked Avenger Jan 10 '15 at 0:06
• So the last statement is that I believe in the existence of an n such that for i from 0 to 4, n+i is composite and A_(n+i) is integral. I further believe (but cannot prove) that such an n is greater than 10^16. – The Masked Avenger Jan 10 '15 at 0:10