Users' Mathboxes Mathbox for Jim Kingdon < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  ILE Home  >  Th. List  >   Mathboxes  >  dceqnconst Unicode version

Theorem dceqnconst 13571
Description: Decidability of real number equality implies the existence of a certain non-constant function from real numbers to integers. Variation of Exercise 11.6(i) of [HoTT], p. (varies). See redcwlpo 13567 for more discussion of decidability of real number equality. (Contributed by BJ and Jim Kingdon, 24-Jun-2024.) (Revised by Jim Kingdon, 23-Jul-2024.)
Assertion
Ref Expression
dceqnconst  |-  ( A. x  e.  RR DECID  x  =  0  ->  E. f ( f : RR --> ZZ  /\  ( f `  0
)  =  0  /\ 
A. x  e.  RR+  ( f `  x
)  =/=  0 ) )
Distinct variable group:    x, f

Proof of Theorem dceqnconst
Dummy variables  y  z are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 reex 7845 . . . 4  |-  RR  e.  _V
21mptex 5686 . . 3  |-  ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) )  e.  _V
32a1i 9 . 2  |-  ( A. x  e.  RR DECID  x  =  0  ->  ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) )  e.  _V )
4 0zd 9158 . . . . 5  |-  ( ( A. x  e.  RR DECID  x  =  0  /\  y  e.  RR )  ->  0  e.  ZZ )
5 1zzd 9173 . . . . 5  |-  ( ( A. x  e.  RR DECID  x  =  0  /\  y  e.  RR )  ->  1  e.  ZZ )
6 eqeq1 2161 . . . . . . 7  |-  ( x  =  y  ->  (
x  =  0  <->  y  =  0 ) )
76dcbid 824 . . . . . 6  |-  ( x  =  y  ->  (DECID  x  =  0  <-> DECID  y  =  0
) )
87rspccva 2812 . . . . 5  |-  ( ( A. x  e.  RR DECID  x  =  0  /\  y  e.  RR )  -> DECID  y  =  0
)
94, 5, 8ifcldcd 3536 . . . 4  |-  ( ( A. x  e.  RR DECID  x  =  0  /\  y  e.  RR )  ->  if ( y  =  0 ,  0 ,  1 )  e.  ZZ )
109fmpttd 5615 . . 3  |-  ( A. x  e.  RR DECID  x  =  0  ->  ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) : RR --> ZZ )
11 0re 7857 . . . . . 6  |-  0  e.  RR
12 0zd 9158 . . . . . . . 8  |-  ( T. 
->  0  e.  ZZ )
13 1zzd 9173 . . . . . . . 8  |-  ( T. 
->  1  e.  ZZ )
14 eqid 2154 . . . . . . . . . . 11  |-  0  =  0
1514orci 721 . . . . . . . . . 10  |-  ( 0  =  0  \/  -.  0  =  0 )
16 df-dc 821 . . . . . . . . . 10  |-  (DECID  0  =  0  <->  ( 0  =  0  \/  -.  0  =  0 ) )
1715, 16mpbir 145 . . . . . . . . 9  |- DECID  0  =  0
1817a1i 9 . . . . . . . 8  |-  ( T. 
-> DECID  0  =  0 )
1912, 13, 18ifcldcd 3536 . . . . . . 7  |-  ( T. 
->  if ( 0  =  0 ,  0 ,  1 )  e.  ZZ )
2019mptru 1341 . . . . . 6  |-  if ( 0  =  0 ,  0 ,  1 )  e.  ZZ
21 eqeq1 2161 . . . . . . . 8  |-  ( y  =  0  ->  (
y  =  0  <->  0  =  0 ) )
2221ifbid 3522 . . . . . . 7  |-  ( y  =  0  ->  if ( y  =  0 ,  0 ,  1 )  =  if ( 0  =  0 ,  0 ,  1 ) )
23 eqid 2154 . . . . . . 7  |-  ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) )  =  ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) )
2422, 23fvmptg 5537 . . . . . 6  |-  ( ( 0  e.  RR  /\  if ( 0  =  0 ,  0 ,  1 )  e.  ZZ )  ->  ( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `  0 )  =  if ( 0  =  0 ,  0 ,  1 ) )
2511, 20, 24mp2an 423 . . . . 5  |-  ( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `  0
)  =  if ( 0  =  0 ,  0 ,  1 )
2614iftruei 3507 . . . . 5  |-  if ( 0  =  0 ,  0 ,  1 )  =  0
2725, 26eqtri 2175 . . . 4  |-  ( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `  0
)  =  0
2827a1i 9 . . 3  |-  ( A. x  e.  RR DECID  x  =  0  ->  ( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `
 0 )  =  0 )
29 1ne0 8880 . . . . . 6  |-  1  =/=  0
30 eqeq1 2161 . . . . . . . . . 10  |-  ( y  =  z  ->  (
y  =  0  <->  z  =  0 ) )
3130ifbid 3522 . . . . . . . . 9  |-  ( y  =  z  ->  if ( y  =  0 ,  0 ,  1 )  =  if ( z  =  0 ,  0 ,  1 ) )
32 rpre 9545 . . . . . . . . . 10  |-  ( z  e.  RR+  ->  z  e.  RR )
3332adantl 275 . . . . . . . . 9  |-  ( ( A. x  e.  RR DECID  x  =  0  /\  z  e.  RR+ )  ->  z  e.  RR )
34 0zd 9158 . . . . . . . . . 10  |-  ( ( A. x  e.  RR DECID  x  =  0  /\  z  e.  RR+ )  ->  0  e.  ZZ )
35 1zzd 9173 . . . . . . . . . 10  |-  ( ( A. x  e.  RR DECID  x  =  0  /\  z  e.  RR+ )  ->  1  e.  ZZ )
36 eqeq1 2161 . . . . . . . . . . . 12  |-  ( x  =  z  ->  (
x  =  0  <->  z  =  0 ) )
3736dcbid 824 . . . . . . . . . . 11  |-  ( x  =  z  ->  (DECID  x  =  0  <-> DECID  z  =  0
) )
38 simpl 108 . . . . . . . . . . 11  |-  ( ( A. x  e.  RR DECID  x  =  0  /\  z  e.  RR+ )  ->  A. x  e.  RR DECID  x  =  0 )
3937, 38, 33rspcdva 2818 . . . . . . . . . 10  |-  ( ( A. x  e.  RR DECID  x  =  0  /\  z  e.  RR+ )  -> DECID  z  =  0
)
4034, 35, 39ifcldcd 3536 . . . . . . . . 9  |-  ( ( A. x  e.  RR DECID  x  =  0  /\  z  e.  RR+ )  ->  if ( z  =  0 ,  0 ,  1 )  e.  ZZ )
4123, 31, 33, 40fvmptd3 5554 . . . . . . . 8  |-  ( ( A. x  e.  RR DECID  x  =  0  /\  z  e.  RR+ )  ->  (
( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `  z
)  =  if ( z  =  0 ,  0 ,  1 ) )
42 rpne0 9554 . . . . . . . . . . 11  |-  ( z  e.  RR+  ->  z  =/=  0 )
4342neneqd 2345 . . . . . . . . . 10  |-  ( z  e.  RR+  ->  -.  z  =  0 )
4443iffalsed 3511 . . . . . . . . 9  |-  ( z  e.  RR+  ->  if ( z  =  0 ,  0 ,  1 )  =  1 )
4544adantl 275 . . . . . . . 8  |-  ( ( A. x  e.  RR DECID  x  =  0  /\  z  e.  RR+ )  ->  if ( z  =  0 ,  0 ,  1 )  =  1 )
4641, 45eqtrd 2187 . . . . . . 7  |-  ( ( A. x  e.  RR DECID  x  =  0  /\  z  e.  RR+ )  ->  (
( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `  z
)  =  1 )
4746neeq1d 2342 . . . . . 6  |-  ( ( A. x  e.  RR DECID  x  =  0  /\  z  e.  RR+ )  ->  (
( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `
 z )  =/=  0  <->  1  =/=  0
) )
4829, 47mpbiri 167 . . . . 5  |-  ( ( A. x  e.  RR DECID  x  =  0  /\  z  e.  RR+ )  ->  (
( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `  z
)  =/=  0 )
4948ralrimiva 2527 . . . 4  |-  ( A. x  e.  RR DECID  x  =  0  ->  A. z  e.  RR+  ( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `
 z )  =/=  0 )
50 fveq2 5461 . . . . . 6  |-  ( z  =  x  ->  (
( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `  z
)  =  ( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `  x
) )
5150neeq1d 2342 . . . . 5  |-  ( z  =  x  ->  (
( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `
 z )  =/=  0  <->  ( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `  x )  =/=  0 ) )
5251cbvralv 2677 . . . 4  |-  ( A. z  e.  RR+  ( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `  z
)  =/=  0  <->  A. x  e.  RR+  ( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `  x
)  =/=  0 )
5349, 52sylib 121 . . 3  |-  ( A. x  e.  RR DECID  x  =  0  ->  A. x  e.  RR+  ( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `
 x )  =/=  0 )
5410, 28, 533jca 1162 . 2  |-  ( A. x  e.  RR DECID  x  =  0  ->  ( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) : RR --> ZZ  /\  ( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `
 0 )  =  0  /\  A. x  e.  RR+  ( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `  x )  =/=  0 ) )
55 feq1 5295 . . 3  |-  ( f  =  ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) )  ->  ( f : RR --> ZZ  <->  ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) : RR --> ZZ ) )
56 fveq1 5460 . . . 4  |-  ( f  =  ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) )  ->  ( f ` 
0 )  =  ( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `  0
) )
5756eqeq1d 2163 . . 3  |-  ( f  =  ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) )  ->  ( ( f `
 0 )  =  0  <->  ( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `  0 )  =  0 ) )
58 fveq1 5460 . . . . 5  |-  ( f  =  ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) )  ->  ( f `  x )  =  ( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `  x
) )
5958neeq1d 2342 . . . 4  |-  ( f  =  ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) )  ->  ( ( f `
 x )  =/=  0  <->  ( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `  x )  =/=  0 ) )
6059ralbidv 2454 . . 3  |-  ( f  =  ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) )  ->  ( A. x  e.  RR+  ( f `  x )  =/=  0  <->  A. x  e.  RR+  (
( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `  x
)  =/=  0 ) )
6155, 57, 603anbi123d 1291 . 2  |-  ( f  =  ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) )  ->  ( ( f : RR --> ZZ  /\  ( f `  0
)  =  0  /\ 
A. x  e.  RR+  ( f `  x
)  =/=  0 )  <-> 
( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) : RR --> ZZ  /\  ( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `
 0 )  =  0  /\  A. x  e.  RR+  ( ( y  e.  RR  |->  if ( y  =  0 ,  0 ,  1 ) ) `  x )  =/=  0 ) ) )
623, 54, 61elabd 2853 1  |-  ( A. x  e.  RR DECID  x  =  0  ->  E. f ( f : RR --> ZZ  /\  ( f `  0
)  =  0  /\ 
A. x  e.  RR+  ( f `  x
)  =/=  0 ) )
Colors of variables: wff set class
Syntax hints:   -. wn 3    -> wi 4    /\ wa 103    \/ wo 698  DECID wdc 820    /\ w3a 963    = wceq 1332   T. wtru 1333   E.wex 1469    e. wcel 2125    =/= wne 2324   A.wral 2432   _Vcvv 2709   ifcif 3501    |-> cmpt 4021   -->wf 5159   ` cfv 5163   RRcr 7710   0cc0 7711   1c1 7712   ZZcz 9146   RR+crp 9538
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 604  ax-in2 605  ax-io 699  ax-5 1424  ax-7 1425  ax-gen 1426  ax-ie1 1470  ax-ie2 1471  ax-8 1481  ax-10 1482  ax-11 1483  ax-i12 1484  ax-bndl 1486  ax-4 1487  ax-17 1503  ax-i9 1507  ax-ial 1511  ax-i5r 1512  ax-13 2127  ax-14 2128  ax-ext 2136  ax-coll 4075  ax-sep 4078  ax-pow 4130  ax-pr 4164  ax-un 4388  ax-setind 4490  ax-cnex 7802  ax-resscn 7803  ax-1cn 7804  ax-1re 7805  ax-icn 7806  ax-addcl 7807  ax-addrcl 7808  ax-mulcl 7809  ax-addcom 7811  ax-addass 7813  ax-distr 7815  ax-i2m1 7816  ax-0lt1 7817  ax-0id 7819  ax-rnegex 7820  ax-cnre 7822  ax-pre-ltirr 7823  ax-pre-ltwlin 7824  ax-pre-lttrn 7825  ax-pre-ltadd 7827
This theorem depends on definitions:  df-bi 116  df-dc 821  df-3or 964  df-3an 965  df-tru 1335  df-fal 1338  df-nf 1438  df-sb 1740  df-eu 2006  df-mo 2007  df-clab 2141  df-cleq 2147  df-clel 2150  df-nfc 2285  df-ne 2325  df-nel 2420  df-ral 2437  df-rex 2438  df-reu 2439  df-rab 2441  df-v 2711  df-sbc 2934  df-csb 3028  df-dif 3100  df-un 3102  df-in 3104  df-ss 3111  df-if 3502  df-pw 3541  df-sn 3562  df-pr 3563  df-op 3565  df-uni 3769  df-int 3804  df-iun 3847  df-br 3962  df-opab 4022  df-mpt 4023  df-id 4248  df-xp 4585  df-rel 4586  df-cnv 4587  df-co 4588  df-dm 4589  df-rn 4590  df-res 4591  df-ima 4592  df-iota 5128  df-fun 5165  df-fn 5166  df-f 5167  df-f1 5168  df-fo 5169  df-f1o 5170  df-fv 5171  df-riota 5770  df-ov 5817  df-oprab 5818  df-mpo 5819  df-pnf 7893  df-mnf 7894  df-xr 7895  df-ltxr 7896  df-le 7897  df-sub 8027  df-neg 8028  df-inn 8813  df-z 9147  df-rp 9539
This theorem is referenced by:  dcapnconstALT  13573
  Copyright terms: Public domain W3C validator