Lm1:
for x, y being Integer
for D being Nat holds
( (x ^2) - (D * (y ^2)) = 1 iff [x,y] is Pell's_solution of D )
Lm2:
for n, k being Nat st n > 0 holds
k + (n |^ k) <= (1 + n) |^ k
Lm3:
for j, n, k being Nat st k < n holds
1 - ((j * k) / n) <= (1 - (k / n)) |^ j
Lm4:
for n, k being Nat st k < n holds
( 1 - (k / n) = (n - k) / n & 1 / (1 - (k / n)) = n / (n - k) )
Lm5:
for n, k being Nat st 0 < 2 * k & 2 * k <= n holds
1 / (1 - (k / n)) <= 1 + ((2 * k) / n)
Lm6:
for i, j, n being Nat st i <= j & j < n & i,j are_congruent_mod n holds
i = j
Lm7:
for i, j, n being Nat st i < n & j < n & i,j are_congruent_mod n holds
i = j
Lm8:
for i, j, n being Nat
for a being non trivial Nat st Px (a,i), Px (a,j) are_congruent_mod Px (a,n) & i < n & j < n holds
i = j
Lm9:
for i, n being Nat
for a being non trivial Nat st i < n & ( not a = 2 or not n = 1 ) holds
Px (a,i) < (Px (a,n)) / 2
Lm10:
for i, j, n being Nat
for a being non trivial Nat st Px (a,i), Px (a,j) are_congruent_mod Px (a,n) & n < i & i <= 2 * n & n < j & j <= 2 * n holds
i = j
theorem Th26:
for
a being non
trivial Nat for
y,
n,
b,
c,
d,
r,
s,
t,
u,
v,
x being
Nat st 1
<= n &
[x,y] is
Pell's_solution of
(a ^2) -' 1 &
[u,v] is
Pell's_solution of
(a ^2) -' 1 &
[s,t] is
Pell's_solution of
(b ^2) -' 1 &
v = (4 * r) * (y ^2) &
b = a + ((u ^2) * ((u ^2) - a)) &
s = x + (c * u) &
t = n + ((4 * d) * y) &
n <= y holds
( not
b is
trivial &
u ^2 > a &
y = Py (
a,
n) )
theorem Th27:
for
a being non
trivial Nat for
y,
n being
Nat st 1
<= n &
y = Py (
a,
n) holds
ex
b,
c,
d,
r,
s,
t,
u,
v,
x being
Nat st
(
[x,y] is
Pell's_solution of
(a ^2) -' 1 &
[u,v] is
Pell's_solution of
(a ^2) -' 1 &
[s,t] is
Pell's_solution of
(b ^2) -' 1 &
v = (4 * r) * (y ^2) &
b = a + ((u ^2) * ((u ^2) - a)) &
s = x + (c * u) &
t = n + ((4 * d) * y) &
n <= y )
theorem Th30:
for
k being
positive Nat holds
(
k + 1 is
prime iff ex
a,
b,
c,
d,
e,
f,
g,
h,
i,
j,
l,
m,
n,
o,
p,
q,
r,
s,
t,
u,
w,
v,
x,
y,
z being
Nat st
(
q = ((w * z) + h) + j &
z = ((((g * k) + g) + k) * (h + j)) + h &
((((2 * k) |^ 3) * ((2 * k) + 2)) * ((n + 1) |^ 2)) + 1
= f ^2 &
e = ((p + q) + z) + (2 * n) &
(((e |^ 3) * (e + 2)) * ((a + 1) |^ 2)) + 1
= o ^2 &
[x,y] is
Pell's_solution of
(a ^2) -' 1 &
u ^2 = ((((16 * ((a ^2) - 1)) * (r ^2)) * (y ^2)) * (y ^2)) + 1 &
(x + (c * u)) ^2 = ((((a + ((u ^2) * ((u ^2) - a))) ^2) - 1) * ((n + ((4 * d) * y)) ^2)) + 1 &
[m,l] is
Pell's_solution of
(a ^2) -' 1 &
l = k + (i * (a - 1)) &
(n + l) + v = y &
m = (p + (l * ((a - n) - 1))) + (b * ((((2 * a) * (n + 1)) - ((n + 1) ^2)) - 1)) &
x = (q + (y * ((a - p) - 1))) + (s * ((((2 * a) * (p + 1)) - ((p + 1) ^2)) - 1)) &
p * m = (z + ((p * l) * (a - p))) + (t * ((((2 * a) * p) - (p ^2)) - 1)) ) )
theorem
for
k being
positive Nat holds
(
k + 1 is
prime iff ex
a,
b,
c,
d,
e,
f,
g,
h,
i,
j,
l,
m,
n,
o,
p,
q,
r,
s,
t,
u,
w,
v,
x,
y,
z being
Nat st
0 = (((((((((((((((((w * z) + h) + j) - q) ^2) + (((((((g * k) + g) + k) * (h + j)) + h) - z) ^2)) + (((((((2 * k) |^ 3) * ((2 * k) + 2)) * ((n + 1) |^ 2)) + 1) - (f ^2)) ^2)) + (((((p + q) + z) + (2 * n)) - e) ^2)) + ((((((e |^ 3) * (e + 2)) * ((a + 1) |^ 2)) + 1) - (o ^2)) ^2)) + ((((x ^2) - (((a ^2) -' 1) * (y ^2))) - 1) ^2)) + (((((((16 * ((a ^2) - 1)) * (r ^2)) * (y ^2)) * (y ^2)) + 1) - (u ^2)) ^2)) + (((((((a + ((u ^2) * ((u ^2) - a))) ^2) - 1) * ((n + ((4 * d) * y)) ^2)) + 1) - ((x + (c * u)) ^2)) ^2)) + ((((m ^2) - (((a ^2) -' 1) * (l ^2))) - 1) ^2)) + (((k + (i * (a - 1))) - l) ^2)) + ((((n + l) + v) - y) ^2)) + ((((p + (l * ((a - n) - 1))) + (b * ((((2 * a) * (n + 1)) - ((n + 1) ^2)) - 1))) - m) ^2)) + ((((q + (y * ((a - p) - 1))) + (s * ((((2 * a) * (p + 1)) - ((p + 1) ^2)) - 1))) - x) ^2)) + ((((z + ((p * l) * (a - p))) + (t * ((((2 * a) * p) - (p ^2)) - 1))) - (p * m)) ^2) )