ILE Home Intuitionistic Logic Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  ILE Home  >  Th. List  >  fz0fzdiffz0 GIF version

Theorem fz0fzdiffz0 9506
Description: The difference of an integer in a finite set of sequential nonnegative integers and and an integer of a finite set of sequential integers with the same upper bound and the nonnegative integer as lower bound is a member of the finite set of sequential nonnegative integers. (Contributed by Alexander van der Vekens, 6-Jun-2018.)
Assertion
Ref Expression
fz0fzdiffz0 ((𝑀 ∈ (0...𝑁) ∧ 𝐾 ∈ (𝑀...𝑁)) → (𝐾𝑀) ∈ (0...𝑁))

Proof of Theorem fz0fzdiffz0
StepHypRef Expression
1 fz0fzelfz0 9503 . . 3 ((𝑀 ∈ (0...𝑁) ∧ 𝐾 ∈ (𝑀...𝑁)) → 𝐾 ∈ (0...𝑁))
2 elfzle1 9410 . . . . . . 7 (𝐾 ∈ (𝑀...𝑁) → 𝑀𝐾)
32adantl 271 . . . . . 6 ((𝑀 ∈ (0...𝑁) ∧ 𝐾 ∈ (𝑀...𝑁)) → 𝑀𝐾)
43adantl 271 . . . . 5 ((𝐾 ∈ (0...𝑁) ∧ (𝑀 ∈ (0...𝑁) ∧ 𝐾 ∈ (𝑀...𝑁))) → 𝑀𝐾)
5 elfznn0 9495 . . . . . . 7 (𝑀 ∈ (0...𝑁) → 𝑀 ∈ ℕ0)
65adantr 270 . . . . . 6 ((𝑀 ∈ (0...𝑁) ∧ 𝐾 ∈ (𝑀...𝑁)) → 𝑀 ∈ ℕ0)
7 elfznn0 9495 . . . . . 6 (𝐾 ∈ (0...𝑁) → 𝐾 ∈ ℕ0)
8 nn0sub 8786 . . . . . 6 ((𝑀 ∈ ℕ0𝐾 ∈ ℕ0) → (𝑀𝐾 ↔ (𝐾𝑀) ∈ ℕ0))
96, 7, 8syl2anr 284 . . . . 5 ((𝐾 ∈ (0...𝑁) ∧ (𝑀 ∈ (0...𝑁) ∧ 𝐾 ∈ (𝑀...𝑁))) → (𝑀𝐾 ↔ (𝐾𝑀) ∈ ℕ0))
104, 9mpbid 145 . . . 4 ((𝐾 ∈ (0...𝑁) ∧ (𝑀 ∈ (0...𝑁) ∧ 𝐾 ∈ (𝑀...𝑁))) → (𝐾𝑀) ∈ ℕ0)
11 elfz3nn0 9496 . . . . 5 (𝐾 ∈ (0...𝑁) → 𝑁 ∈ ℕ0)
1211adantr 270 . . . 4 ((𝐾 ∈ (0...𝑁) ∧ (𝑀 ∈ (0...𝑁) ∧ 𝐾 ∈ (𝑀...𝑁))) → 𝑁 ∈ ℕ0)
13 elfz2nn0 9493 . . . . . . 7 (𝑀 ∈ (0...𝑁) ↔ (𝑀 ∈ ℕ0𝑁 ∈ ℕ0𝑀𝑁))
14 elfz2 9400 . . . . . . . . . . 11 (𝐾 ∈ (𝑀...𝑁) ↔ ((𝑀 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ 𝐾 ∈ ℤ) ∧ (𝑀𝐾𝐾𝑁)))
15 zsubcl 8761 . . . . . . . . . . . . . . . . . . . . . . 23 ((𝐾 ∈ ℤ ∧ 𝑀 ∈ ℤ) → (𝐾𝑀) ∈ ℤ)
1615zred 8838 . . . . . . . . . . . . . . . . . . . . . 22 ((𝐾 ∈ ℤ ∧ 𝑀 ∈ ℤ) → (𝐾𝑀) ∈ ℝ)
1716ancoms 264 . . . . . . . . . . . . . . . . . . . . 21 ((𝑀 ∈ ℤ ∧ 𝐾 ∈ ℤ) → (𝐾𝑀) ∈ ℝ)
18173adant2 962 . . . . . . . . . . . . . . . . . . . 20 ((𝑀 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ 𝐾 ∈ ℤ) → (𝐾𝑀) ∈ ℝ)
19 zre 8724 . . . . . . . . . . . . . . . . . . . . 21 (𝐾 ∈ ℤ → 𝐾 ∈ ℝ)
20193ad2ant3 966 . . . . . . . . . . . . . . . . . . . 20 ((𝑀 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ 𝐾 ∈ ℤ) → 𝐾 ∈ ℝ)
21 zre 8724 . . . . . . . . . . . . . . . . . . . . 21 (𝑁 ∈ ℤ → 𝑁 ∈ ℝ)
22213ad2ant2 965 . . . . . . . . . . . . . . . . . . . 20 ((𝑀 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ 𝐾 ∈ ℤ) → 𝑁 ∈ ℝ)
2318, 20, 223jca 1123 . . . . . . . . . . . . . . . . . . 19 ((𝑀 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ 𝐾 ∈ ℤ) → ((𝐾𝑀) ∈ ℝ ∧ 𝐾 ∈ ℝ ∧ 𝑁 ∈ ℝ))
2423adantr 270 . . . . . . . . . . . . . . . . . 18 (((𝑀 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ 𝐾 ∈ ℤ) ∧ 𝑀 ∈ ℕ0) → ((𝐾𝑀) ∈ ℝ ∧ 𝐾 ∈ ℝ ∧ 𝑁 ∈ ℝ))
2524adantr 270 . . . . . . . . . . . . . . . . 17 ((((𝑀 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ 𝐾 ∈ ℤ) ∧ 𝑀 ∈ ℕ0) ∧ 𝐾𝑁) → ((𝐾𝑀) ∈ ℝ ∧ 𝐾 ∈ ℝ ∧ 𝑁 ∈ ℝ))
26 nn0ge0 8668 . . . . . . . . . . . . . . . . . . . 20 (𝑀 ∈ ℕ0 → 0 ≤ 𝑀)
2726adantl 271 . . . . . . . . . . . . . . . . . . 19 (((𝑀 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ 𝐾 ∈ ℤ) ∧ 𝑀 ∈ ℕ0) → 0 ≤ 𝑀)
28 nn0re 8652 . . . . . . . . . . . . . . . . . . . 20 (𝑀 ∈ ℕ0𝑀 ∈ ℝ)
29 subge02 7935 . . . . . . . . . . . . . . . . . . . 20 ((𝐾 ∈ ℝ ∧ 𝑀 ∈ ℝ) → (0 ≤ 𝑀 ↔ (𝐾𝑀) ≤ 𝐾))
3020, 28, 29syl2an 283 . . . . . . . . . . . . . . . . . . 19 (((𝑀 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ 𝐾 ∈ ℤ) ∧ 𝑀 ∈ ℕ0) → (0 ≤ 𝑀 ↔ (𝐾𝑀) ≤ 𝐾))
3127, 30mpbid 145 . . . . . . . . . . . . . . . . . 18 (((𝑀 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ 𝐾 ∈ ℤ) ∧ 𝑀 ∈ ℕ0) → (𝐾𝑀) ≤ 𝐾)
3231anim1i 333 . . . . . . . . . . . . . . . . 17 ((((𝑀 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ 𝐾 ∈ ℤ) ∧ 𝑀 ∈ ℕ0) ∧ 𝐾𝑁) → ((𝐾𝑀) ≤ 𝐾𝐾𝑁))
33 letr 7547 . . . . . . . . . . . . . . . . 17 (((𝐾𝑀) ∈ ℝ ∧ 𝐾 ∈ ℝ ∧ 𝑁 ∈ ℝ) → (((𝐾𝑀) ≤ 𝐾𝐾𝑁) → (𝐾𝑀) ≤ 𝑁))
3425, 32, 33sylc 61 . . . . . . . . . . . . . . . 16 ((((𝑀 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ 𝐾 ∈ ℤ) ∧ 𝑀 ∈ ℕ0) ∧ 𝐾𝑁) → (𝐾𝑀) ≤ 𝑁)
3534exp31 356 . . . . . . . . . . . . . . 15 ((𝑀 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ 𝐾 ∈ ℤ) → (𝑀 ∈ ℕ0 → (𝐾𝑁 → (𝐾𝑀) ≤ 𝑁)))
3635a1i 9 . . . . . . . . . . . . . 14 (𝑁 ∈ ℕ0 → ((𝑀 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ 𝐾 ∈ ℤ) → (𝑀 ∈ ℕ0 → (𝐾𝑁 → (𝐾𝑀) ≤ 𝑁))))
3736com14 87 . . . . . . . . . . . . 13 (𝐾𝑁 → ((𝑀 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ 𝐾 ∈ ℤ) → (𝑀 ∈ ℕ0 → (𝑁 ∈ ℕ0 → (𝐾𝑀) ≤ 𝑁))))
3837adantl 271 . . . . . . . . . . . 12 ((𝑀𝐾𝐾𝑁) → ((𝑀 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ 𝐾 ∈ ℤ) → (𝑀 ∈ ℕ0 → (𝑁 ∈ ℕ0 → (𝐾𝑀) ≤ 𝑁))))
3938impcom 123 . . . . . . . . . . 11 (((𝑀 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ 𝐾 ∈ ℤ) ∧ (𝑀𝐾𝐾𝑁)) → (𝑀 ∈ ℕ0 → (𝑁 ∈ ℕ0 → (𝐾𝑀) ≤ 𝑁)))
4014, 39sylbi 119 . . . . . . . . . 10 (𝐾 ∈ (𝑀...𝑁) → (𝑀 ∈ ℕ0 → (𝑁 ∈ ℕ0 → (𝐾𝑀) ≤ 𝑁)))
4140com13 79 . . . . . . . . 9 (𝑁 ∈ ℕ0 → (𝑀 ∈ ℕ0 → (𝐾 ∈ (𝑀...𝑁) → (𝐾𝑀) ≤ 𝑁)))
4241impcom 123 . . . . . . . 8 ((𝑀 ∈ ℕ0𝑁 ∈ ℕ0) → (𝐾 ∈ (𝑀...𝑁) → (𝐾𝑀) ≤ 𝑁))
43423adant3 963 . . . . . . 7 ((𝑀 ∈ ℕ0𝑁 ∈ ℕ0𝑀𝑁) → (𝐾 ∈ (𝑀...𝑁) → (𝐾𝑀) ≤ 𝑁))
4413, 43sylbi 119 . . . . . 6 (𝑀 ∈ (0...𝑁) → (𝐾 ∈ (𝑀...𝑁) → (𝐾𝑀) ≤ 𝑁))
4544imp 122 . . . . 5 ((𝑀 ∈ (0...𝑁) ∧ 𝐾 ∈ (𝑀...𝑁)) → (𝐾𝑀) ≤ 𝑁)
4645adantl 271 . . . 4 ((𝐾 ∈ (0...𝑁) ∧ (𝑀 ∈ (0...𝑁) ∧ 𝐾 ∈ (𝑀...𝑁))) → (𝐾𝑀) ≤ 𝑁)
4710, 12, 463jca 1123 . . 3 ((𝐾 ∈ (0...𝑁) ∧ (𝑀 ∈ (0...𝑁) ∧ 𝐾 ∈ (𝑀...𝑁))) → ((𝐾𝑀) ∈ ℕ0𝑁 ∈ ℕ0 ∧ (𝐾𝑀) ≤ 𝑁))
481, 47mpancom 413 . 2 ((𝑀 ∈ (0...𝑁) ∧ 𝐾 ∈ (𝑀...𝑁)) → ((𝐾𝑀) ∈ ℕ0𝑁 ∈ ℕ0 ∧ (𝐾𝑀) ≤ 𝑁))
49 elfz2nn0 9493 . 2 ((𝐾𝑀) ∈ (0...𝑁) ↔ ((𝐾𝑀) ∈ ℕ0𝑁 ∈ ℕ0 ∧ (𝐾𝑀) ≤ 𝑁))
5048, 49sylibr 132 1 ((𝑀 ∈ (0...𝑁) ∧ 𝐾 ∈ (𝑀...𝑁)) → (𝐾𝑀) ∈ (0...𝑁))
Colors of variables: wff set class
Syntax hints:  wi 4  wa 102  wb 103  w3a 924  wcel 1438   class class class wbr 3837  (class class class)co 5634  cr 7328  0cc0 7329  cle 7502  cmin 7632  0cn0 8643  cz 8720  ...cfz 9393
This theorem was proved from axioms:  ax-1 5  ax-2 6  ax-mp 7  ax-ia1 104  ax-ia2 105  ax-ia3 106  ax-in1 579  ax-in2 580  ax-io 665  ax-5 1381  ax-7 1382  ax-gen 1383  ax-ie1 1427  ax-ie2 1428  ax-8 1440  ax-10 1441  ax-11 1442  ax-i12 1443  ax-bndl 1444  ax-4 1445  ax-13 1449  ax-14 1450  ax-17 1464  ax-i9 1468  ax-ial 1472  ax-i5r 1473  ax-ext 2070  ax-sep 3949  ax-pow 4001  ax-pr 4027  ax-un 4251  ax-setind 4343  ax-cnex 7415  ax-resscn 7416  ax-1cn 7417  ax-1re 7418  ax-icn 7419  ax-addcl 7420  ax-addrcl 7421  ax-mulcl 7422  ax-addcom 7424  ax-addass 7426  ax-distr 7428  ax-i2m1 7429  ax-0lt1 7430  ax-0id 7432  ax-rnegex 7433  ax-cnre 7435  ax-pre-ltirr 7436  ax-pre-ltwlin 7437  ax-pre-lttrn 7438  ax-pre-ltadd 7440
This theorem depends on definitions:  df-bi 115  df-3or 925  df-3an 926  df-tru 1292  df-fal 1295  df-nf 1395  df-sb 1693  df-eu 1951  df-mo 1952  df-clab 2075  df-cleq 2081  df-clel 2084  df-nfc 2217  df-ne 2256  df-nel 2351  df-ral 2364  df-rex 2365  df-reu 2366  df-rab 2368  df-v 2621  df-sbc 2839  df-dif 2999  df-un 3001  df-in 3003  df-ss 3010  df-pw 3427  df-sn 3447  df-pr 3448  df-op 3450  df-uni 3649  df-int 3684  df-br 3838  df-opab 3892  df-mpt 3893  df-id 4111  df-xp 4434  df-rel 4435  df-cnv 4436  df-co 4437  df-dm 4438  df-rn 4439  df-res 4440  df-ima 4441  df-iota 4967  df-fun 5004  df-fn 5005  df-f 5006  df-fv 5010  df-riota 5590  df-ov 5637  df-oprab 5638  df-mpt2 5639  df-pnf 7503  df-mnf 7504  df-xr 7505  df-ltxr 7506  df-le 7507  df-sub 7634  df-neg 7635  df-inn 8395  df-n0 8644  df-z 8721  df-uz 8989  df-fz 9394
This theorem is referenced by: (None)
  Copyright terms: Public domain W3C validator