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

Theorem exbtwnzlemex 10706
Description: Existence of an integer so that a given real number is between the integer and its successor. The real number must satisfy the 𝑛 ≤ 𝐴 ∨ 𝐴 < 𝑛 hypothesis. For example either a rational number or a number which is irrational (in the sense of being apart from any rational number) will meet this condition.

The proof starts by finding two integers which are less than and greater than 𝐴. Then this range can be shrunk by choosing an integer in between the endpoints of the range and then deciding which half of the range to keep based on the 𝑛 ≤ 𝐴 ∨ 𝐴 < 𝑛 hypothesis, and iterating until the range consists of two consecutive integers. (Contributed by Jim Kingdon, 8-Oct-2021.)

Hypotheses
Ref Expression
exbtwnzlemex.a (𝜑 → 𝐴 ∈ ℝ)
exbtwnzlemex.tri ((𝜑 ∧ 𝑛 ∈ ℤ) → (𝑛 ≤ 𝐴 ∨ 𝐴 < 𝑛))
Assertion
Ref Expression
exbtwnzlemex (𝜑 → ∃𝑥 ∈ ℤ (𝑥 ≤ 𝐴 ∧ 𝐴 < (𝑥 + 1)))
Distinct variable groups:   𝐴,𝑛   𝑥,𝐴   𝜑,𝑛
Allowed substitution hint:   𝜑(𝑥)

Proof of Theorem exbtwnzlemex
Dummy variables 𝑎 𝑗 𝑚 𝑦 are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 exbtwnzlemex.a . . . 4 (𝜑 → 𝐴 ∈ ℝ)
2 btwnz 9781 . . . 4 (𝐴 ∈ ℝ → (∃𝑚 ∈ ℤ 𝑚 < 𝐴 ∧ ∃𝑗 ∈ ℤ 𝐴 < 𝑗))
31, 2syl 14 . . 3 (𝜑 → (∃𝑚 ∈ ℤ 𝑚 < 𝐴 ∧ ∃𝑗 ∈ ℤ 𝐴 < 𝑗))
4 reeanv 2721 . . 3 (∃𝑚 ∈ ℤ ∃𝑗 ∈ ℤ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗) ↔ (∃𝑚 ∈ ℤ 𝑚 < 𝐴 ∧ ∃𝑗 ∈ ℤ 𝐴 < 𝑗))
53, 4sylibr 134 . 2 (𝜑 → ∃𝑚 ∈ ℤ ∃𝑗 ∈ ℤ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗))
6 simplrl 541 . . . . . 6 (((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) → 𝑚 ∈ ℤ)
76zred 9784 . . . . . . 7 (((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) → 𝑚 ∈ ℝ)
81ad2antrr 492 . . . . . . 7 (((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) → 𝐴 ∈ ℝ)
9 simprl 535 . . . . . . 7 (((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) → 𝑚 < 𝐴)
107, 8, 9ltled 8458 . . . . . 6 (((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) → 𝑚 ≤ 𝐴)
11 simprr 537 . . . . . . 7 (((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) → 𝐴 < 𝑗)
126zcnd 9785 . . . . . . . 8 (((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) → 𝑚 ∈ ℂ)
13 simplrr 542 . . . . . . . . 9 (((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) → 𝑗 ∈ ℤ)
1413zcnd 9785 . . . . . . . 8 (((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) → 𝑗 ∈ ℂ)
1512, 14pncan3d 8653 . . . . . . 7 (((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) → (𝑚 + (𝑗 − 𝑚)) = 𝑗)
1611, 15breqtrrd 4159 . . . . . 6 (((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) → 𝐴 < (𝑚 + (𝑗 − 𝑚)))
17 breq1 4134 . . . . . . . 8 (𝑦 = 𝑚 → (𝑦 ≤ 𝐴 ↔ 𝑚 ≤ 𝐴))
18 oveq1 6099 . . . . . . . . 9 (𝑦 = 𝑚 → (𝑦 + (𝑗 − 𝑚)) = (𝑚 + (𝑗 − 𝑚)))
1918breq2d 4143 . . . . . . . 8 (𝑦 = 𝑚 → (𝐴 < (𝑦 + (𝑗 − 𝑚)) ↔ 𝐴 < (𝑚 + (𝑗 − 𝑚))))
2017, 19anbi12d 477 . . . . . . 7 (𝑦 = 𝑚 → ((𝑦 ≤ 𝐴 ∧ 𝐴 < (𝑦 + (𝑗 − 𝑚))) ↔ (𝑚 ≤ 𝐴 ∧ 𝐴 < (𝑚 + (𝑗 − 𝑚)))))
2120rspcev 2929 . . . . . 6 ((𝑚 ∈ ℤ ∧ (𝑚 ≤ 𝐴 ∧ 𝐴 < (𝑚 + (𝑗 − 𝑚)))) → ∃𝑦 ∈ ℤ (𝑦 ≤ 𝐴 ∧ 𝐴 < (𝑦 + (𝑗 − 𝑚))))
226, 10, 16, 21syl12anc 1276 . . . . 5 (((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) → ∃𝑦 ∈ ℤ (𝑦 ≤ 𝐴 ∧ 𝐴 < (𝑦 + (𝑗 − 𝑚))))
2313zred 9784 . . . . . . . 8 (((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) → 𝑗 ∈ ℝ)
247, 8, 23, 9, 11lttrd 8465 . . . . . . 7 (((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) → 𝑚 < 𝑗)
25 znnsub 9711 . . . . . . . 8 ((𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ) → (𝑚 < 𝑗 ↔ (𝑗 − 𝑚) ∈ ℕ))
2625ad2antlr 493 . . . . . . 7 (((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) → (𝑚 < 𝑗 ↔ (𝑗 − 𝑚) ∈ ℕ))
2724, 26mpbid 147 . . . . . 6 (((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) → (𝑗 − 𝑚) ∈ ℕ)
28 exbtwnzlemex.tri . . . . . . . . . 10 ((𝜑 ∧ 𝑛 ∈ ℤ) → (𝑛 ≤ 𝐴 ∨ 𝐴 < 𝑛))
2928ralrimiva 2623 . . . . . . . . 9 (𝜑 → ∀𝑛 ∈ ℤ (𝑛 ≤ 𝐴 ∨ 𝐴 < 𝑛))
30 breq1 4134 . . . . . . . . . . 11 (𝑛 = 𝑎 → (𝑛 ≤ 𝐴 ↔ 𝑎 ≤ 𝐴))
31 breq2 4135 . . . . . . . . . . 11 (𝑛 = 𝑎 → (𝐴 < 𝑛 ↔ 𝐴 < 𝑎))
3230, 31orbi12d 805 . . . . . . . . . 10 (𝑛 = 𝑎 → ((𝑛 ≤ 𝐴 ∨ 𝐴 < 𝑛) ↔ (𝑎 ≤ 𝐴 ∨ 𝐴 < 𝑎)))
3332cbvralv 2786 . . . . . . . . 9 (∀𝑛 ∈ ℤ (𝑛 ≤ 𝐴 ∨ 𝐴 < 𝑛) ↔ ∀𝑎 ∈ ℤ (𝑎 ≤ 𝐴 ∨ 𝐴 < 𝑎))
3429, 33sylib 122 . . . . . . . 8 (𝜑 → ∀𝑎 ∈ ℤ (𝑎 ≤ 𝐴 ∨ 𝐴 < 𝑎))
3534ad2antrr 492 . . . . . . 7 (((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) → ∀𝑎 ∈ ℤ (𝑎 ≤ 𝐴 ∨ 𝐴 < 𝑎))
3635r19.21bi 2638 . . . . . 6 ((((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) ∧ 𝑎 ∈ ℤ) → (𝑎 ≤ 𝐴 ∨ 𝐴 < 𝑎))
3727, 8, 36exbtwnzlemshrink 10705 . . . . 5 ((((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) ∧ ∃𝑦 ∈ ℤ (𝑦 ≤ 𝐴 ∧ 𝐴 < (𝑦 + (𝑗 − 𝑚)))) → ∃𝑥 ∈ ℤ (𝑥 ≤ 𝐴 ∧ 𝐴 < (𝑥 + 1)))
3822, 37mpdan 425 . . . 4 (((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) ∧ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗)) → ∃𝑥 ∈ ℤ (𝑥 ≤ 𝐴 ∧ 𝐴 < (𝑥 + 1)))
3938ex 115 . . 3 ((𝜑 ∧ (𝑚 ∈ ℤ ∧ 𝑗 ∈ ℤ)) → ((𝑚 < 𝐴 ∧ 𝐴 < 𝑗) → ∃𝑥 ∈ ℤ (𝑥 ≤ 𝐴 ∧ 𝐴 < (𝑥 + 1))))
4039rexlimdvva 2676 . 2 (𝜑 → (∃𝑚 ∈ ℤ ∃𝑗 ∈ ℤ (𝑚 < 𝐴 ∧ 𝐴 < 𝑗) → ∃𝑥 ∈ ℤ (𝑥 ≤ 𝐴 ∧ 𝐴 < (𝑥 + 1))))
415, 40mpd 13 1 (𝜑 → ∃𝑥 ∈ ℤ (𝑥 ≤ 𝐴 ∧ 𝐴 < (𝑥 + 1)))
Colors of variables:    wff set class
This proof depends on syntax axioms:   → wi 4   ∧ wa 104   ↔ wb 105   ∨ wo 720   ∈ wcel 2209  ∀wral 2528  ∃wrex 2529   class class class wbr 4131  (class class class)co 6092  ℝcr 8190  1c1 8192   + caddc 8194   < clt 8372   ≤ cle 8373   − cmin 8510  ℕcn 9319  ℤcz 9659
This proof depends on axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-ia1 106  ax-ia2 107  ax-ia3 108  ax-in1 623  ax-in2 624  ax-io 721  ax-5 1500  ax-7 1501  ax-gen 1502  ax-ie1 1546  ax-ie2 1547  ax-8 1557  ax-10 1558  ax-11 1559  ax-i12 1560  ax-bndl 1562  ax-4 1563  ax-17 1579  ax-i9 1583  ax-ial 1587  ax-i5r 1588  ax-14 2212  ax-ext 2220  ax-sep 4251  ax-pow 4313  ax-pr 4348  ax-un 4580  ax-setind 4686  ax-cnex 8282  ax-resscn 8283  ax-1cn 8284  ax-1re 8285  ax-icn 8286  ax-addcl 8287  ax-addrcl 8288  ax-mulcl 8289  ax-addcom 8291  ax-addass 8293  ax-distr 8295  ax-i2m1 8296  ax-0lt1 8297  ax-0id 8299  ax-rnegex 8300  ax-cnre 8302  ax-pre-ltirr 8303  ax-pre-ltwlin 8304  ax-pre-lttrn 8305  ax-pre-ltadd 8307  ax-arch 8310
This proof depends on definitions:  df-bi 117  df-3or 1010  df-3an 1011  df-tru 1405  df-fal 1408  df-nf 1514  df-sb 1816  df-eu 2089  df-mo 2090  df-clab 2225  df-cleq 2231  df-clel 2234  df-nfc 2381  df-ne 2421  df-nel 2516  df-ral 2533  df-rex 2534  df-reu 2535  df-rab 2537  df-v 2823  df-sbc 3052  df-dif 3222  df-un 3224  df-in 3226  df-ss 3233  df-pw 3690  df-sn 3715  df-pr 3716  df-op 3718  df-uni 3936  df-int 3971  df-br 4132  df-opab 4194  df-id 4440  df-xp 4782  df-rel 4783  df-cnv 4784  df-co 4785  df-dm 4786  df-iota 5344  df-fun 5386  df-fv 5392  df-riota 6045  df-ov 6095  df-oprab 6096  df-mpo 6097  df-pnf 8374  df-mnf 8375  df-xr 8376  df-ltxr 8377  df-le 8378  df-sub 8512  df-neg 8513  df-inn 9320  df-n0 9581  df-z 9660
This theorem is used by:  qbtwnz  10708  apbtwnz  10731
  Copyright terms: Public domain W3C validator