Metamath Proof Explorer


Theorem dvferm1

Description: One-sided version of dvferm . A point U which is the local maximum of its right neighborhood has derivative at most zero. (Contributed by Mario Carneiro, 24-Feb-2015) (Proof shortened by Mario Carneiro, 28-Dec-2016)

Ref Expression
Hypotheses dvferm.a
|- ( ph -> F : X --> RR )
dvferm.b
|- ( ph -> X C_ RR )
dvferm.u
|- ( ph -> U e. ( A (,) B ) )
dvferm.s
|- ( ph -> ( A (,) B ) C_ X )
dvferm.d
|- ( ph -> U e. dom ( RR _D F ) )
dvferm1.r
|- ( ph -> A. y e. ( U (,) B ) ( F ` y ) <_ ( F ` U ) )
Assertion dvferm1
|- ( ph -> ( ( RR _D F ) ` U ) <_ 0 )

Proof

Step Hyp Ref Expression
1 dvferm.a
 |-  ( ph -> F : X --> RR )
2 dvferm.b
 |-  ( ph -> X C_ RR )
3 dvferm.u
 |-  ( ph -> U e. ( A (,) B ) )
4 dvferm.s
 |-  ( ph -> ( A (,) B ) C_ X )
5 dvferm.d
 |-  ( ph -> U e. dom ( RR _D F ) )
6 dvferm1.r
 |-  ( ph -> A. y e. ( U (,) B ) ( F ` y ) <_ ( F ` U ) )
7 fveq2
 |-  ( x = z -> ( F ` x ) = ( F ` z ) )
8 7 oveq1d
 |-  ( x = z -> ( ( F ` x ) - ( F ` U ) ) = ( ( F ` z ) - ( F ` U ) ) )
9 oveq1
 |-  ( x = z -> ( x - U ) = ( z - U ) )
10 8 9 oveq12d
 |-  ( x = z -> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) = ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) )
11 eqid
 |-  ( x e. ( X \ { U } ) |-> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) ) = ( x e. ( X \ { U } ) |-> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) )
12 ovex
 |-  ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) e. _V
13 10 11 12 fvmpt
 |-  ( z e. ( X \ { U } ) -> ( ( x e. ( X \ { U } ) |-> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) ) ` z ) = ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) )
14 13 fvoveq1d
 |-  ( z e. ( X \ { U } ) -> ( abs ` ( ( ( x e. ( X \ { U } ) |-> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) ) ` z ) - ( ( RR _D F ) ` U ) ) ) = ( abs ` ( ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) - ( ( RR _D F ) ` U ) ) ) )
15 id
 |-  ( y = ( ( RR _D F ) ` U ) -> y = ( ( RR _D F ) ` U ) )
16 14 15 breqan12rd
 |-  ( ( y = ( ( RR _D F ) ` U ) /\ z e. ( X \ { U } ) ) -> ( ( abs ` ( ( ( x e. ( X \ { U } ) |-> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) ) ` z ) - ( ( RR _D F ) ` U ) ) ) < y <-> ( abs ` ( ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) - ( ( RR _D F ) ` U ) ) ) < ( ( RR _D F ) ` U ) ) )
17 16 imbi2d
 |-  ( ( y = ( ( RR _D F ) ` U ) /\ z e. ( X \ { U } ) ) -> ( ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( x e. ( X \ { U } ) |-> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) ) ` z ) - ( ( RR _D F ) ` U ) ) ) < y ) <-> ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) - ( ( RR _D F ) ` U ) ) ) < ( ( RR _D F ) ` U ) ) ) )
18 17 ralbidva
 |-  ( y = ( ( RR _D F ) ` U ) -> ( A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( x e. ( X \ { U } ) |-> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) ) ` z ) - ( ( RR _D F ) ` U ) ) ) < y ) <-> A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) - ( ( RR _D F ) ` U ) ) ) < ( ( RR _D F ) ` U ) ) ) )
19 18 rexbidv
 |-  ( y = ( ( RR _D F ) ` U ) -> ( E. u e. RR+ A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( x e. ( X \ { U } ) |-> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) ) ` z ) - ( ( RR _D F ) ` U ) ) ) < y ) <-> E. u e. RR+ A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) - ( ( RR _D F ) ` U ) ) ) < ( ( RR _D F ) ` U ) ) ) )
20 dvf
 |-  ( RR _D F ) : dom ( RR _D F ) --> CC
21 ffun
 |-  ( ( RR _D F ) : dom ( RR _D F ) --> CC -> Fun ( RR _D F ) )
22 funfvbrb
 |-  ( Fun ( RR _D F ) -> ( U e. dom ( RR _D F ) <-> U ( RR _D F ) ( ( RR _D F ) ` U ) ) )
23 20 21 22 mp2b
 |-  ( U e. dom ( RR _D F ) <-> U ( RR _D F ) ( ( RR _D F ) ` U ) )
24 5 23 sylib
 |-  ( ph -> U ( RR _D F ) ( ( RR _D F ) ` U ) )
25 eqid
 |-  ( ( TopOpen ` CCfld ) |`t RR ) = ( ( TopOpen ` CCfld ) |`t RR )
26 eqid
 |-  ( TopOpen ` CCfld ) = ( TopOpen ` CCfld )
27 ax-resscn
 |-  RR C_ CC
28 27 a1i
 |-  ( ph -> RR C_ CC )
29 fss
 |-  ( ( F : X --> RR /\ RR C_ CC ) -> F : X --> CC )
30 1 27 29 sylancl
 |-  ( ph -> F : X --> CC )
31 25 26 11 28 30 2 eldv
 |-  ( ph -> ( U ( RR _D F ) ( ( RR _D F ) ` U ) <-> ( U e. ( ( int ` ( ( TopOpen ` CCfld ) |`t RR ) ) ` X ) /\ ( ( RR _D F ) ` U ) e. ( ( x e. ( X \ { U } ) |-> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) ) limCC U ) ) ) )
32 24 31 mpbid
 |-  ( ph -> ( U e. ( ( int ` ( ( TopOpen ` CCfld ) |`t RR ) ) ` X ) /\ ( ( RR _D F ) ` U ) e. ( ( x e. ( X \ { U } ) |-> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) ) limCC U ) ) )
33 32 simprd
 |-  ( ph -> ( ( RR _D F ) ` U ) e. ( ( x e. ( X \ { U } ) |-> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) ) limCC U ) )
34 33 adantr
 |-  ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) -> ( ( RR _D F ) ` U ) e. ( ( x e. ( X \ { U } ) |-> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) ) limCC U ) )
35 2 27 sstrdi
 |-  ( ph -> X C_ CC )
36 4 3 sseldd
 |-  ( ph -> U e. X )
37 30 35 36 dvlem
 |-  ( ( ph /\ x e. ( X \ { U } ) ) -> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) e. CC )
38 37 fmpttd
 |-  ( ph -> ( x e. ( X \ { U } ) |-> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) ) : ( X \ { U } ) --> CC )
39 38 adantr
 |-  ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) -> ( x e. ( X \ { U } ) |-> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) ) : ( X \ { U } ) --> CC )
40 35 adantr
 |-  ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) -> X C_ CC )
41 40 ssdifssd
 |-  ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) -> ( X \ { U } ) C_ CC )
42 35 36 sseldd
 |-  ( ph -> U e. CC )
43 42 adantr
 |-  ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) -> U e. CC )
44 39 41 43 ellimc3
 |-  ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) -> ( ( ( RR _D F ) ` U ) e. ( ( x e. ( X \ { U } ) |-> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) ) limCC U ) <-> ( ( ( RR _D F ) ` U ) e. CC /\ A. y e. RR+ E. u e. RR+ A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( x e. ( X \ { U } ) |-> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) ) ` z ) - ( ( RR _D F ) ` U ) ) ) < y ) ) ) )
45 34 44 mpbid
 |-  ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) -> ( ( ( RR _D F ) ` U ) e. CC /\ A. y e. RR+ E. u e. RR+ A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( x e. ( X \ { U } ) |-> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) ) ` z ) - ( ( RR _D F ) ` U ) ) ) < y ) ) )
46 45 simprd
 |-  ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) -> A. y e. RR+ E. u e. RR+ A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( x e. ( X \ { U } ) |-> ( ( ( F ` x ) - ( F ` U ) ) / ( x - U ) ) ) ` z ) - ( ( RR _D F ) ` U ) ) ) < y ) )
47 dvfre
 |-  ( ( F : X --> RR /\ X C_ RR ) -> ( RR _D F ) : dom ( RR _D F ) --> RR )
48 1 2 47 syl2anc
 |-  ( ph -> ( RR _D F ) : dom ( RR _D F ) --> RR )
49 48 5 ffvelrnd
 |-  ( ph -> ( ( RR _D F ) ` U ) e. RR )
50 49 anim1i
 |-  ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) -> ( ( ( RR _D F ) ` U ) e. RR /\ 0 < ( ( RR _D F ) ` U ) ) )
51 elrp
 |-  ( ( ( RR _D F ) ` U ) e. RR+ <-> ( ( ( RR _D F ) ` U ) e. RR /\ 0 < ( ( RR _D F ) ` U ) ) )
52 50 51 sylibr
 |-  ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) -> ( ( RR _D F ) ` U ) e. RR+ )
53 19 46 52 rspcdva
 |-  ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) -> E. u e. RR+ A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) - ( ( RR _D F ) ` U ) ) ) < ( ( RR _D F ) ` U ) ) )
54 1 ad3antrrr
 |-  ( ( ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) /\ u e. RR+ ) /\ A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) - ( ( RR _D F ) ` U ) ) ) < ( ( RR _D F ) ` U ) ) ) -> F : X --> RR )
55 2 ad3antrrr
 |-  ( ( ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) /\ u e. RR+ ) /\ A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) - ( ( RR _D F ) ` U ) ) ) < ( ( RR _D F ) ` U ) ) ) -> X C_ RR )
56 3 ad3antrrr
 |-  ( ( ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) /\ u e. RR+ ) /\ A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) - ( ( RR _D F ) ` U ) ) ) < ( ( RR _D F ) ` U ) ) ) -> U e. ( A (,) B ) )
57 4 ad3antrrr
 |-  ( ( ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) /\ u e. RR+ ) /\ A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) - ( ( RR _D F ) ` U ) ) ) < ( ( RR _D F ) ` U ) ) ) -> ( A (,) B ) C_ X )
58 5 ad3antrrr
 |-  ( ( ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) /\ u e. RR+ ) /\ A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) - ( ( RR _D F ) ` U ) ) ) < ( ( RR _D F ) ` U ) ) ) -> U e. dom ( RR _D F ) )
59 6 ad3antrrr
 |-  ( ( ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) /\ u e. RR+ ) /\ A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) - ( ( RR _D F ) ` U ) ) ) < ( ( RR _D F ) ` U ) ) ) -> A. y e. ( U (,) B ) ( F ` y ) <_ ( F ` U ) )
60 simpllr
 |-  ( ( ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) /\ u e. RR+ ) /\ A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) - ( ( RR _D F ) ` U ) ) ) < ( ( RR _D F ) ` U ) ) ) -> 0 < ( ( RR _D F ) ` U ) )
61 simplr
 |-  ( ( ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) /\ u e. RR+ ) /\ A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) - ( ( RR _D F ) ` U ) ) ) < ( ( RR _D F ) ` U ) ) ) -> u e. RR+ )
62 simpr
 |-  ( ( ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) /\ u e. RR+ ) /\ A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) - ( ( RR _D F ) ` U ) ) ) < ( ( RR _D F ) ` U ) ) ) -> A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) - ( ( RR _D F ) ` U ) ) ) < ( ( RR _D F ) ` U ) ) )
63 eqid
 |-  ( ( U + if ( B <_ ( U + u ) , B , ( U + u ) ) ) / 2 ) = ( ( U + if ( B <_ ( U + u ) , B , ( U + u ) ) ) / 2 )
64 54 55 56 57 58 59 60 61 62 63 dvferm1lem
 |-  -. ( ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) /\ u e. RR+ ) /\ A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) - ( ( RR _D F ) ` U ) ) ) < ( ( RR _D F ) ` U ) ) )
65 64 imnani
 |-  ( ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) /\ u e. RR+ ) -> -. A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) - ( ( RR _D F ) ` U ) ) ) < ( ( RR _D F ) ` U ) ) )
66 65 nrexdv
 |-  ( ( ph /\ 0 < ( ( RR _D F ) ` U ) ) -> -. E. u e. RR+ A. z e. ( X \ { U } ) ( ( z =/= U /\ ( abs ` ( z - U ) ) < u ) -> ( abs ` ( ( ( ( F ` z ) - ( F ` U ) ) / ( z - U ) ) - ( ( RR _D F ) ` U ) ) ) < ( ( RR _D F ) ` U ) ) )
67 53 66 pm2.65da
 |-  ( ph -> -. 0 < ( ( RR _D F ) ` U ) )
68 0re
 |-  0 e. RR
69 lenlt
 |-  ( ( ( ( RR _D F ) ` U ) e. RR /\ 0 e. RR ) -> ( ( ( RR _D F ) ` U ) <_ 0 <-> -. 0 < ( ( RR _D F ) ` U ) ) )
70 49 68 69 sylancl
 |-  ( ph -> ( ( ( RR _D F ) ` U ) <_ 0 <-> -. 0 < ( ( RR _D F ) ` U ) ) )
71 67 70 mpbird
 |-  ( ph -> ( ( RR _D F ) ` U ) <_ 0 )