:: EULER_1 semantic presentation  Show TPTP formulae Show IDV graph for whole article:: Showing IDV graph ... (Click the Palm Trees again to close it)

Lm1: for k, n being Nat holds k gcd n = k hcf n
proof end;

Lm2: for a, b being Nat holds
( a,b are_relative_prime iff a,b are_relative_prime )
proof end;

Lm3: for a, k being Nat
for i being Integer st i > 0 & a = i & k > 0 holds
i mod k = a mod k
proof end;

Lm4: for a, m being Nat
for i being Integer holds
( a = i & m > 0 & m divides i iff ( a = i & m > 0 & m divides a ) )
proof end;

Lm5: for k being Nat
for j being Integer st k <> 0 & [\(j / k)/] + 1 >= j / k holds
k >= j - ([\(j / k)/] * k)
proof end;

theorem Th1: :: EULER_1:1  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for k, n being natural number holds
( k in n iff k < n )
proof end;

Lm6: not 1 is prime
by INT_2:def 5;

theorem Th2: :: EULER_1:2  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for n being Nat holds
( n,n are_relative_prime iff n = 1 )
proof end;

theorem Th3: :: EULER_1:3  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for k, n being Nat st k <> 0 & k < n & n is prime holds
k,n are_relative_prime
proof end;

theorem Th4: :: EULER_1:4  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for n, k being Nat holds
( n is prime & k in { kk where kk is Nat : ( n,kk are_relative_prime & kk >= 1 & kk <= n ) } iff ( n is prime & k in n & not k in {0} ) )
proof end;

theorem Th5: :: EULER_1:5  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for A being finite set
for x being set st x in A holds
card (A \ {x}) = (card A) - (card {x})
proof end;

theorem Th6: :: EULER_1:6  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for a, b being Nat st a hcf b = 1 holds
for c being Nat holds (a * c) hcf (b * c) = c
proof end;

theorem Th7: :: EULER_1:7  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for a, b, c being Nat st a <> 0 & b <> 0 & c <> 0 & (a * c) hcf (b * c) = c holds
a,b are_relative_prime
proof end;

theorem Th8: :: EULER_1:8  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for a, b being Nat st a hcf b = 1 holds
(a + b) hcf b = 1
proof end;

theorem Th9: :: EULER_1:9  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for a, b, c being Nat holds (a + (b * c)) hcf b = a hcf b
proof end;

theorem Th10: :: EULER_1:10  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for m, n being Nat st m,n are_relative_prime holds
ex k being Nat st
( ex i0, j0 being Integer st
( k = (i0 * m) + (j0 * n) & k > 0 ) & ( for l being Nat st ex i, j being Integer st
( l = (i * m) + (j * n) & l > 0 ) holds
k <= l ) )
proof end;

theorem Th11: :: EULER_1:11  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for m, n being Nat st m,n are_relative_prime holds
for k being Nat ex i, j being Integer st (i * m) + (j * n) = k
proof end;

theorem Th12: :: EULER_1:12  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for A, B being non empty finite set st ex f being Function of A,B st
( f is one-to-one & f is onto ) holds
Card A = Card B
proof end;

theorem Th13: :: EULER_1:13  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for i, k, n being Integer holds (i + (k * n)) mod n = i mod n
proof end;

theorem Th14: :: EULER_1:14  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for a, b, c being Nat st a <> 0 & b <> 0 & c <> 0 & c divides a * b & a,c are_relative_prime holds
c divides b
proof end;

theorem Th15: :: EULER_1:15  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for a, b, c being Nat st a <> 0 & b <> 0 & c <> 0 & a,c are_relative_prime & b,c are_relative_prime holds
a * b,c are_relative_prime
proof end;

theorem Th16: :: EULER_1:16  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for x, y, i being Integer st x <> 0 & y <> 0 & i > 0 holds
(i * x) gcd (i * y) = i * (x gcd y)
proof end;

theorem Th17: :: EULER_1:17  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for a, b being Nat
for x being Integer st a <> 0 & b <> 0 holds
(a + (x * b)) gcd b = a gcd b
proof end;

definition
let n be Nat;
func Euler n -> Nat equals :: EULER_1:def 1
Card { k where k is Nat : ( n,k are_relative_prime & k >= 1 & k <= n ) } ;
coherence
Card { k where k is Nat : ( n,k are_relative_prime & k >= 1 & k <= n ) } is Nat
proof end;
end;

:: deftheorem defines Euler EULER_1:def 1 :
for n being Nat holds Euler n = Card { k where k is Nat : ( n,k are_relative_prime & k >= 1 & k <= n ) } ;

set X = { k where k is Nat : ( 1,k are_relative_prime & k >= 1 & k <= 1 ) } ;

for x being set holds
( x in { k where k is Nat : ( 1,k are_relative_prime & k >= 1 & k <= 1 ) } iff x = 1 )
proof end;

then Lm7: Card {1} = Card { k where k is Nat : ( 1,k are_relative_prime & k >= 1 & k <= 1 ) } by TARSKI:def 1
.= Euler 1 ;

theorem :: EULER_1:18  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
Euler 1 = 1 by Lm7, CARD_1:79;

set X = { k where k is Nat : ( 2,k are_relative_prime & k >= 1 & k <= 2 ) } ;

for x being set holds
( x in { k where k is Nat : ( 2,k are_relative_prime & k >= 1 & k <= 2 ) } iff x = 1 )
proof end;

then Lm8: Card {1} = Card { k where k is Nat : ( 2,k are_relative_prime & k >= 1 & k <= 2 ) } by TARSKI:def 1
.= Euler 2 ;

theorem :: EULER_1:19  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
Euler 2 = 1 by Lm8, CARD_1:79;

theorem Th20: :: EULER_1:20  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for n being Nat st n > 1 holds
Euler n <= n - 1
proof end;

theorem :: EULER_1:21  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for n being Nat st n is prime holds
Euler n = n - 1
proof end;

theorem :: EULER_1:22  Show TPTP formulae Show IDV graph:: Showing IDV graph ... (Click the Palm Tree again to close it) Show TPTP problem
for m, n being Nat st m > 1 & n > 1 & m,n are_relative_prime holds
Euler (m * n) = (Euler m) * (Euler n)
proof end;