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

Theorem rebtwn2z 10044
Description: A real number can be bounded by integers above and below which are two apart.

The proof starts by finding two integers which are less than and greater than the given real number. 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 weak linearity, and iterating until the range consists of integers which are two apart. (Contributed by Jim Kingdon, 13-Oct-2021.)

Assertion
Ref Expression
rebtwn2z  |-  ( A  e.  RR  ->  E. x  e.  ZZ  ( x  < 
A  /\  A  <  ( x  +  2 ) ) )
Distinct variable group:    x, A

Proof of Theorem rebtwn2z
Dummy variables  m  n  y are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 btwnz 9182 . . 3  |-  ( A  e.  RR  ->  ( E. m  e.  ZZ  m  <  A  /\  E. n  e.  ZZ  A  <  n ) )
2 reeanv 2600 . . 3  |-  ( E. m  e.  ZZ  E. n  e.  ZZ  (
m  <  A  /\  A  <  n )  <->  ( E. m  e.  ZZ  m  <  A  /\  E. n  e.  ZZ  A  <  n
) )
31, 2sylibr 133 . 2  |-  ( A  e.  RR  ->  E. m  e.  ZZ  E. n  e.  ZZ  ( m  < 
A  /\  A  <  n ) )
4 simpll 518 . . . . 5  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  ->  A  e.  RR )
5 simplrl 524 . . . . . . . . 9  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  ->  m  e.  ZZ )
65zred 9185 . . . . . . . 8  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  ->  m  e.  RR )
7 simplrr 525 . . . . . . . . 9  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  ->  n  e.  ZZ )
87zred 9185 . . . . . . . 8  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  ->  n  e.  RR )
9 simprl 520 . . . . . . . 8  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  ->  m  <  A )
10 simprr 521 . . . . . . . 8  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  ->  A  <  n )
116, 4, 8, 9, 10lttrd 7900 . . . . . . 7  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  ->  m  <  n )
12 znnsub 9117 . . . . . . . 8  |-  ( ( m  e.  ZZ  /\  n  e.  ZZ )  ->  ( m  <  n  <->  ( n  -  m )  e.  NN ) )
1312ad2antlr 480 . . . . . . 7  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  -> 
( m  <  n  <->  ( n  -  m )  e.  NN ) )
1411, 13mpbid 146 . . . . . 6  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  -> 
( n  -  m
)  e.  NN )
15 elnnuz 9374 . . . . . . . 8  |-  ( ( n  -  m )  e.  NN  <->  ( n  -  m )  e.  (
ZZ>= `  1 ) )
16 eluzp1p1 9363 . . . . . . . 8  |-  ( ( n  -  m )  e.  ( ZZ>= `  1
)  ->  ( (
n  -  m )  +  1 )  e.  ( ZZ>= `  ( 1  +  1 ) ) )
1715, 16sylbi 120 . . . . . . 7  |-  ( ( n  -  m )  e.  NN  ->  (
( n  -  m
)  +  1 )  e.  ( ZZ>= `  (
1  +  1 ) ) )
18 df-2 8791 . . . . . . . 8  |-  2  =  ( 1  +  1 )
1918fveq2i 5424 . . . . . . 7  |-  ( ZZ>= ` 
2 )  =  (
ZZ>= `  ( 1  +  1 ) )
2017, 19eleqtrrdi 2233 . . . . . 6  |-  ( ( n  -  m )  e.  NN  ->  (
( n  -  m
)  +  1 )  e.  ( ZZ>= `  2
) )
2114, 20syl 14 . . . . 5  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  -> 
( ( n  -  m )  +  1 )  e.  ( ZZ>= ` 
2 ) )
225zcnd 9186 . . . . . . . . 9  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  ->  m  e.  CC )
237zcnd 9186 . . . . . . . . 9  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  ->  n  e.  CC )
2422, 23pncan3d 8088 . . . . . . . 8  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  -> 
( m  +  ( n  -  m ) )  =  n )
2524, 8eqeltrd 2216 . . . . . . 7  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  -> 
( m  +  ( n  -  m ) )  e.  RR )
268, 6resubcld 8155 . . . . . . . . 9  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  -> 
( n  -  m
)  e.  RR )
27 1red 7793 . . . . . . . . 9  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  -> 
1  e.  RR )
2826, 27readdcld 7807 . . . . . . . 8  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  -> 
( ( n  -  m )  +  1 )  e.  RR )
296, 28readdcld 7807 . . . . . . 7  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  -> 
( m  +  ( ( n  -  m
)  +  1 ) )  e.  RR )
3010, 24breqtrrd 3956 . . . . . . 7  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  ->  A  <  ( m  +  ( n  -  m
) ) )
3126ltp1d 8700 . . . . . . . 8  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  -> 
( n  -  m
)  <  ( (
n  -  m )  +  1 ) )
3226, 28, 6, 31ltadd2dd 8196 . . . . . . 7  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  -> 
( m  +  ( n  -  m ) )  <  ( m  +  ( ( n  -  m )  +  1 ) ) )
334, 25, 29, 30, 32lttrd 7900 . . . . . 6  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  ->  A  <  ( m  +  ( ( n  -  m )  +  1 ) ) )
34 breq1 3932 . . . . . . . 8  |-  ( y  =  m  ->  (
y  <  A  <->  m  <  A ) )
35 oveq1 5781 . . . . . . . . 9  |-  ( y  =  m  ->  (
y  +  ( ( n  -  m )  +  1 ) )  =  ( m  +  ( ( n  -  m )  +  1 ) ) )
3635breq2d 3941 . . . . . . . 8  |-  ( y  =  m  ->  ( A  <  ( y  +  ( ( n  -  m )  +  1 ) )  <->  A  <  ( m  +  ( ( n  -  m )  +  1 ) ) ) )
3734, 36anbi12d 464 . . . . . . 7  |-  ( y  =  m  ->  (
( y  <  A  /\  A  <  ( y  +  ( ( n  -  m )  +  1 ) ) )  <-> 
( m  <  A  /\  A  <  ( m  +  ( ( n  -  m )  +  1 ) ) ) ) )
3837rspcev 2789 . . . . . 6  |-  ( ( m  e.  ZZ  /\  ( m  <  A  /\  A  <  ( m  +  ( ( n  -  m )  +  1 ) ) ) )  ->  E. y  e.  ZZ  ( y  <  A  /\  A  <  ( y  +  ( ( n  -  m )  +  1 ) ) ) )
395, 9, 33, 38syl12anc 1214 . . . . 5  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  ->  E. y  e.  ZZ  ( y  <  A  /\  A  <  ( y  +  ( ( n  -  m )  +  1 ) ) ) )
40 rebtwn2zlemshrink 10043 . . . . 5  |-  ( ( A  e.  RR  /\  ( ( n  -  m )  +  1 )  e.  ( ZZ>= ` 
2 )  /\  E. y  e.  ZZ  (
y  <  A  /\  A  <  ( y  +  ( ( n  -  m )  +  1 ) ) ) )  ->  E. x  e.  ZZ  ( x  <  A  /\  A  <  ( x  + 
2 ) ) )
414, 21, 39, 40syl3anc 1216 . . . 4  |-  ( ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  /\  ( m  <  A  /\  A  <  n ) )  ->  E. x  e.  ZZ  ( x  <  A  /\  A  <  ( x  + 
2 ) ) )
4241ex 114 . . 3  |-  ( ( A  e.  RR  /\  ( m  e.  ZZ  /\  n  e.  ZZ ) )  ->  ( (
m  <  A  /\  A  <  n )  ->  E. x  e.  ZZ  ( x  <  A  /\  A  <  ( x  + 
2 ) ) ) )
4342rexlimdvva 2557 . 2  |-  ( A  e.  RR  ->  ( E. m  e.  ZZ  E. n  e.  ZZ  (
m  <  A  /\  A  <  n )  ->  E. x  e.  ZZ  ( x  <  A  /\  A  <  ( x  + 
2 ) ) ) )
443, 43mpd 13 1  |-  ( A  e.  RR  ->  E. x  e.  ZZ  ( x  < 
A  /\  A  <  ( x  +  2 ) ) )
Colors of variables: wff set class
Syntax hints:    -> wi 4    /\ wa 103    <-> wb 104    e. wcel 1480   E.wrex 2417   class class class wbr 3929   ` cfv 5123  (class class class)co 5774   RRcr 7631   1c1 7633    + caddc 7635    < clt 7812    - cmin 7945   NNcn 8732   2c2 8783   ZZcz 9066   ZZ>=cuz 9338
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-ia1 105  ax-ia2 106  ax-ia3 107  ax-in1 603  ax-in2 604  ax-io 698  ax-5 1423  ax-7 1424  ax-gen 1425  ax-ie1 1469  ax-ie2 1470  ax-8 1482  ax-10 1483  ax-11 1484  ax-i12 1485  ax-bndl 1486  ax-4 1487  ax-13 1491  ax-14 1492  ax-17 1506  ax-i9 1510  ax-ial 1514  ax-i5r 1515  ax-ext 2121  ax-sep 4046  ax-pow 4098  ax-pr 4131  ax-un 4355  ax-setind 4452  ax-cnex 7723  ax-resscn 7724  ax-1cn 7725  ax-1re 7726  ax-icn 7727  ax-addcl 7728  ax-addrcl 7729  ax-mulcl 7730  ax-addcom 7732  ax-addass 7734  ax-distr 7736  ax-i2m1 7737  ax-0lt1 7738  ax-0id 7740  ax-rnegex 7741  ax-cnre 7743  ax-pre-ltirr 7744  ax-pre-ltwlin 7745  ax-pre-lttrn 7746  ax-pre-ltadd 7748  ax-arch 7751
This theorem depends on definitions:  df-bi 116  df-3or 963  df-3an 964  df-tru 1334  df-fal 1337  df-nf 1437  df-sb 1736  df-eu 2002  df-mo 2003  df-clab 2126  df-cleq 2132  df-clel 2135  df-nfc 2270  df-ne 2309  df-nel 2404  df-ral 2421  df-rex 2422  df-reu 2423  df-rab 2425  df-v 2688  df-sbc 2910  df-dif 3073  df-un 3075  df-in 3077  df-ss 3084  df-pw 3512  df-sn 3533  df-pr 3534  df-op 3536  df-uni 3737  df-int 3772  df-br 3930  df-opab 3990  df-mpt 3991  df-id 4215  df-xp 4545  df-rel 4546  df-cnv 4547  df-co 4548  df-dm 4549  df-rn 4550  df-res 4551  df-ima 4552  df-iota 5088  df-fun 5125  df-fn 5126  df-f 5127  df-fv 5131  df-riota 5730  df-ov 5777  df-oprab 5778  df-mpo 5779  df-pnf 7814  df-mnf 7815  df-xr 7816  df-ltxr 7817  df-le 7818  df-sub 7947  df-neg 7948  df-inn 8733  df-2 8791  df-n0 8990  df-z 9067  df-uz 9339
This theorem is referenced by:  qbtwnre  10046
  Copyright terms: Public domain W3C validator