User:Fjackson/sandbox

Properties
The largest number that always divides the product $abcd$ is 12. The quadruple with the minimal product is (1, 2, 2, 3).

Similar to a Pythagorean triple which generates a distinct right triangle, a Pythagorean quadruple will generate a distinct Heronian triangle . If a, b, c, d is a Pythagorean quadruple with $a^2 + b^2 + c^2 = d^2$ it will generate a Heronian triangle with sides x, y, z as follows:-
 * $$x = d^2 - a^2$$
 * $$y = d^2 - b^2$$
 * $$z = d^2 - c^2$$.

It will have a semiperimeter $s = d^2$, an area $A = abcd$ and an inradius $r = abc/d$.

The exradii will be:-
 * $r_x = bcd/a$
 * $r_y = acd/b$
 * $r_z = abd/c$.

The circumradius will be $R=(d^2 - a^2)(d^2 - b^2)(d^2 - c^2)/(4abcd) = abcd(1/a^2 + 1/b^2 + 1/c^2 -1/d^2)/4$.

The ordered sequence of areas of this class of Heronian triangles can be found at.

Properties

 * Any odd number of the form $2m+1$, where m is an integer and $m>1$, can be the odd leg of a primitive Pythagorean triple [PPT]. See almost-isosceles PPT section below. However, only even numbers divisible by 4 can be the even leg of a PPT. This is because Euclid's formula for the even leg given above is $2mn$ and one of m or n must be even.
 * The hypotenuse c is the sum of two squares. This requires all of its prime factors to be primes of the form 4n + 1. Therefore c is of the form 4n + 1. A sequence of possible hypotenuse numbers for a PPT can be found at.

Examples
As a consequence of the definition, 3 is an Ulam number (1+2); and 4 is an Ulam number (1+3). (Here 2+2 is not a second representation of 4, because the previous terms must be distinct.) The integer 5 is not an Ulam number, because 5 = 1 + 4 = 2 + 3. The first few terms are
 * 1, 2, 3, 4, 6, 8, 11, 13, 16, 18, 26, 28, 36, 38, 47, 48, 53, 57, 62, 69, 72, 77, 82, 87, 97, 99, 102, 106, 114, 126, 131, 138, 145, 148, 155, 175, 177, 180, 182, 189, 197, 206, 209, 219, 221, 236, 238, 241, 243, 253, 258, 260, 273, 282, ....

There are infinitely many Ulam numbers. For, after the first n numbers in the sequence have already been determined, it is always possible to extend the sequence by one more element: Un &minus; 1 + Un is uniquely represented as a sum of two of the first n numbers, and there may be other smaller numbers that are also uniquely represented in this way, so the next element can be chosen as the smallest of these uniquely representable numbers.

Ulam is said to have conjectured that the numbers have zero density, but they seem to have a density of approximately 0.07398.

Properties
Apart from 1 + 2 = 3 any subsequent Ulam number cannot be the sum of its two prior consecutive Ulam numbers.
 * Proof: Assume that for n > 2, Un&minus;1 + Un = Un + 1 is the required sum in only one way then so does Un&minus;2 + Un produce a sum in only one way and it falls between Un and Un + 1. This contradicts the condition that Un + 1 is the next smallest Ulam number.

For n > 2, any three consecutive Ulam numbers (Un&minus;1, Un, Un + 1) as integer sides will form a triangle.
 * Proof: The previous property states that for n > 2, Un&minus;2 + Un &ge; Un + 1. Consequently Un&minus;1 + Un > Un + 1 and because Un&minus;1 < Un < Un + 1 the triangle inequality is satisfied.

The sequence of Ulam numbers forms a complete sequence.
 * Proof: By definition Un = Uj + Uk where j < k < n and is the smallest integer that is the sum of two distinct smaller Ulam numbers in exactly one way. This means that for all Un with n > 3, the greatest value that Uj can have is Un&minus;3 and the greatest value that Uk can have is Un&minus;1.
 * Hence Un &le; Un&minus;1 + Un&minus;3 < 2Un&minus;1 and U1 = 1, U2 = 2, U3 = 3. This is a sufficient condition for Ulam numbers to be a complete sequence.

For every integer n > 1 there is always at least one Ulam number Uj such that n &le; Uj < 2n.
 * Proof: It has been proved that there are infinitely many Ulam numbers and they start at 1. Therefore for every integer n > 1 it is possible to find j such that Uj&minus;1 &le; n &le; Uj. From the proof above for n > 3, Uj &le; Uj&minus;1 + Uj&minus;3 < 2Uj&minus;1. Therefore n &le; Uj < 2Uj&minus;1 &le; 2n. Also for n = 2 and 3 the property is true by calculation.

In any sequence of 5 consecutive positive integers there can be a maximum of 2 Ulam numbers.
 * Proof: Assume that the sequence {i, i+1,..., i+4} has its first value i = Uj an Ulam number then it is possible that i+1 is the next Ulam number Uj+1. Now consider i+2, this cannot be the next Ulam number Uj+2 because it is not a unique sum of two previous terms. i+2 = Uj+1+U1 = Uj+U2 . A similar argument exists for i+3 and i+4.

Inequalities
Ulam numbers are pseudo-random and too irregular to have tight bounds. Nevertheless from the properties above, namely, at worst the next Ulam number Un+1 &le; Un + Un-2 and in any five consecutive positive integers at most two can be Ulam numbers, it can be stated that
 * $5⁄2n-7$ &le; Un &le; Nn+1 for n > 0.

where Nn are the numbers in Narayana’s cows sequence: 1,1,1,2,3,4,6,9,13,19,... with the recurrence  relation Nn = Nn-1 +Nn-3 that starts at N0.

Almost-isosceles Pythagorean triples
No Pythagorean triples are isosceles, because the ratio of the hypotenuse to either other side is $\sqrt{2}$, but $\sqrt{2}$ cannot be expressed as the ratio of 2 integers.

There are, however, right-angled triangles with integral sides for which the lengths of the non-hypotenuse sides differ by one, such as,


 * $$3^2+4^2 = 5^2$$


 * $$20^2+21^2 = 29^2$$

and an infinite number of others. They can be completely parameterized as,


 * $$(\tfrac{x-1}{2})^2+(\tfrac{x+1}{2})^2 = y^2$$

where {x, y} are the solutions to the Pell equation $$x^2-2y^2 = -1$$.

If a, b, c are the sides of this type of primitive Pythagorean triple then the solution to the Pell equation above is given by the recursive formula


 * $$a_n=6a_{n-1}-a_{n-2}+2$$ with $$a_1=3$$ and $$a_2=20$$
 * $$b_n=6b_{n-1}-b_{n-2}-3$$ with $$b_1=4$$ and $$b_2=21$$
 * $$c_n=6c_{n-1}-c_{n-2}$$ with $$c_1=5$$ and $$c_2=29$$.

When it is the longer non-hypotenuse side and hypotenuse that differ by one, such as in


 * $$5^2+12^2 = 13^2$$
 * $$7^2+24^2 = 25^2$$

then the complete solution for the primitive Pythagorean triple a, b, c is


 * $$a=2m+1, \quad b=2m^2+2m, \quad c=2m^2+2m+1$$

and


 * $$(2m+1)^2+(2m^2+2m)^2=(2m^2+2m+1)^2$$

where integer $$m>0$$ is the generating parameter.

It also shows that all odd numbers (greater than 1) appear in a primitive Pythagorean triple.

Another property of this type of almost-isosceles primitive Pythagorean triple is that the sides are related such that
 * $$a^b+b^a=Kc$$

for some integer $$K$$. Or in other words $$a^b+b^a$$ is divisible by $$c$$ such as in
 * $$(5^{12}+12^5)/13 = 18799189$$.

Mersenne numbers in nature and elsewhere
In computer science, unsigned $n$-bit integers can be used to express numbers up to $M_{n}$. Signed $(n + 1)$-bit integers can express values between $&minus;(M_{n} + 1)$ and $M_{n}$, using the two's complement representation.

In the mathematical problem Tower of Hanoi, solving a puzzle with an $n$-disc tower requires $M_{n}$ steps, assuming no mistakes are made. The number of rice grains on the whole chessboard in the wheat and chessboard problem is $M_{64}$.

The asteroid with minor planet number 8191 is named 8191 Mersenne after Marin Mersenne, because 8191 is a Mersenne prime (3 Juno, 7 Iris, 31 Euphrosyne and 127 Johanna having been discovered and named during the 19th century).

In geometry, an integer right triangle that is primitive and has its even leg a power of 2 ( $&ge; 4$ ) generates a unique right triangle such that its inradius is always a Mersenne number. For example if the even leg is $2^{n + 1}$ then because it is primitive it constrains the odd leg to be $4^{n} &minus; 1$, the hypotenuse to be $4^{n} + 1$ and its inradius to be $2^{n} &minus; 1$.

Furthermore, if a Mersenne number is used as the side of a primitive right triangle then $M_{0}$ and $M_{1}$ give the Mersenne numbers 0 and 1, neither of which can be the side of a primitive right triangle. For n > 1, all $M_{n}$ are congruent to 3 mod 4. Consequently, no Mersenne number can be the hypotenuse of a primitive right triangle. This leaves the odd leg as the only candidate. However, unless the Mersenne number is prime, the right triangle is not unique. The number of primitive right triangles whose odd leg is $M_{n}$ starting at n = 2 is 1, 1, 2, 1, 2, 1, 4, 2, 4, 2, 8, ... .

Occurrences and counts of integers within primitive Pythagorean triples
Not all integers can be the leg or hypotenuse of a primitive Pythagorean triple. For example only integers congruent to 1 modulo 4 and divisible only by primes congruent to 1 modulo 4 can be a hypotenuse. However 1 cannot be a hypotenuse because the legs of its right triangle would not be integral as they would have to be <1. The first integer that can be a hypotenuse is therefore 5.

Similarly, 1 or 2 cannot be a leg. 1 is odd and it has to be represented by the Euclidean parameter m^2-n^2=1 where m>n>0 and m, n have differing parities. This is not possible. Also 2 is even and has to be represented by the Euclidean parameter 2mn=2. Again this is not possible. The first integer that can be a leg is 3.

Finally neither a leg nor hypotenuse can be congruent to 2 modulo 4. This is because the hypotenuse is always 1 modulo 4 and the leg has to be represented by 2mn or m^2-n^2 neither of which can be 2 modulo 4.

Consequently, it is possible to define two functions L(s) and H(s) where s is an integer side length and L(s), H(s) are counts of primitive Pythagorean triples that contains s as either a leg - L(s) or a hypotenuse - H(s). Given the integer s and its prime factorisation L(s) and H(s) are derived as follows:-

General rational triangles
A generalisation to the congruent number problem is to determine whether triangles with rational sides (rational or Heron triangle) not restricted to right triangles have integer areas. It has been proved that every positive number is the area of some rational triangle.

This gives rise to the term t-congruent number. A t-congruent number is the integer area of a rational triangle that has one of its internal angles &theta; such that t = tan &theta;/2. Consequently the generalisation above can be re-stated as "Any square-free natural number n can be realised as a t-congruent number for some integer t.

Other special rational triangles
Congruent numbers stem from rational right triangles. So is there any other special rational triangle that can generate a variation on congruent numbers? Two cases have been studied.

Prime counting function - Inequalities
In his well-known notebooks, Ramanujan proves that the inequality"$\pi(x)^2 < \frac{ex}{\log x} \pi\bigg( \frac{x}{e} \bigg)$"holds for all sufficiently large values of $$x$$.

Dudek and Platt have recently shown that this is true if $$x \geq e^{9400}$$. Moreover, they prove that on the assumption of the Riemann hypothesis, the largest integer counterexample to the above inequality is at $$x= 38, 358, 837, 682$$.

Adding Test Latex
This answer has been updated with a generalization of the identity $$2\sum_{0}^{n} m + (n+1) = (n+1)^2$$

By the binomial theorem
 * $$(n+1)^p-n^p=1+\sum_{r=1}^{r=p-1}\binom pr n^r$$

summing both sides over n starting at 1 gives
 * $$(n+1)^p-1=n+\sum_{r=1}^{r=p-1}\binom pr \sum_{m=1}^{m=n}m^r$$

Hence for $$p=2,3,4,5,...$$


 * $$2\sum_{0}^{n} m + (n+1) = (n+1)^2$$
 * $$3\sum_{0}^{n} m^2 + 3\sum_{0}^{n} m + (n+1) = (n+1)^3$$
 * $$4\sum_{0}^{n} m^3 + 6\sum_{0}^{n} m^2 + 4\sum_{0}^{n} m + (n+1) = (n+1)^4$$
 * $$5\sum_{0}^{n} m^4 + 10\sum_{0}^{n} m^3 + 10\sum_{0}^{n} m^2 + 5\sum_{0}^{n} m + (n+1) = (n+1)^5$$ etc.

This also provides an iterative process for determining the formulas of the power sums.

Collatz steps for Mersenne Primes above a-45
Above a-45, the ranking of Mersenne primes is provisional. So, the formal sequence of Mersenne primes is only verifiable up to a-45. Consequently, the formal sequence of Collatz steps for Mersenne primes is only verifiable up to s(a-45).

The comment section of OEIS A181777 has all 6 unranked steps for a-46 to a-51 and your value for a-48 is confirmed.

Apologies for a tardy reply but have been away visiting friends.

Practical number

 * $$p_i\leq1+\sigma(p_1^{\alpha_1}p_2^{\alpha_2}\dots p_{i-1}^{\alpha_{i-1}})=1+\sigma(p_1^{\alpha_1})\sigma(p_2^{\alpha_2})\dots \sigma(p_{i-1}^{\alpha_{i-1}})=1+\prod_{j=1}^{i-1}\frac{p_j^{\alpha_j+1}-1}{p_j-1},$$