Description: Closure of the gcd operator. (Contributed by Thierry Arnoux, 2-Feb-2020)
Ref | Expression | ||
---|---|---|---|
Assertion | gcdnncl | ⊢ ( ( 𝑀 ∈ ℕ ∧ 𝑁 ∈ ℕ ) → ( 𝑀 gcd 𝑁 ) ∈ ℕ ) |
Step | Hyp | Ref | Expression |
---|---|---|---|
1 | simpl | ⊢ ( ( 𝑀 ∈ ℕ ∧ 𝑁 ∈ ℕ ) → 𝑀 ∈ ℕ ) | |
2 | 1 | nnzd | ⊢ ( ( 𝑀 ∈ ℕ ∧ 𝑁 ∈ ℕ ) → 𝑀 ∈ ℤ ) |
3 | simpr | ⊢ ( ( 𝑀 ∈ ℕ ∧ 𝑁 ∈ ℕ ) → 𝑁 ∈ ℕ ) | |
4 | 3 | nnzd | ⊢ ( ( 𝑀 ∈ ℕ ∧ 𝑁 ∈ ℕ ) → 𝑁 ∈ ℤ ) |
5 | 3 | nnne0d | ⊢ ( ( 𝑀 ∈ ℕ ∧ 𝑁 ∈ ℕ ) → 𝑁 ≠ 0 ) |
6 | 5 | neneqd | ⊢ ( ( 𝑀 ∈ ℕ ∧ 𝑁 ∈ ℕ ) → ¬ 𝑁 = 0 ) |
7 | 6 | intnand | ⊢ ( ( 𝑀 ∈ ℕ ∧ 𝑁 ∈ ℕ ) → ¬ ( 𝑀 = 0 ∧ 𝑁 = 0 ) ) |
8 | gcdn0cl | ⊢ ( ( ( 𝑀 ∈ ℤ ∧ 𝑁 ∈ ℤ ) ∧ ¬ ( 𝑀 = 0 ∧ 𝑁 = 0 ) ) → ( 𝑀 gcd 𝑁 ) ∈ ℕ ) | |
9 | 2 4 7 8 | syl21anc | ⊢ ( ( 𝑀 ∈ ℕ ∧ 𝑁 ∈ ℕ ) → ( 𝑀 gcd 𝑁 ) ∈ ℕ ) |