:: Real Normed Space
:: by Jan Popio{\l}ek
::
:: Copyright (c) 1990-2021 Association of Mizar Users

definition end;

registration
cluster non empty strict for NORMSTR ;
existence
ex b1 being NORMSTR st
( not b1 is empty & b1 is strict )
proof end;
end;

deffunc H1( NORMSTR ) -> Element of the carrier of $1 = 0.$1;

set V = the RealLinearSpace;

Lm1: the carrier of () = {()}
by RLSUB_1:def 3;

reconsider niltonil = the carrier of () --> (In (0,REAL)) as Function of the carrier of (),REAL ;

0. the RealLinearSpace is VECTOR of ()
by ;

then Lm2: niltonil . () = 0
by FUNCOP_1:7;

Lm3: for u being VECTOR of ()
for a being Real holds niltonil . (a * u) = |.a.| * (niltonil . u)

proof end;

Lm4: for u, v being VECTOR of () holds niltonil . (u + v) <= (niltonil . u) + (niltonil . v)
proof end;

reconsider X = NORMSTR(# the carrier of (),(0. ()), the addF of (), the Mult of (),niltonil #) as non empty NORMSTR ;

Lm5: now :: thesis: for x, y being Point of X
for a being Real holds
( ( = 0 implies x = H1(X) ) & ( x = H1(X) implies = 0 ) & ||.(a * x).|| = |.a.| * & ||.(x + y).|| <= + )
let x, y be Point of X; :: thesis: for a being Real holds
( ( = 0 implies x = H1(X) ) & ( x = H1(X) implies = 0 ) & ||.(a * x).|| = |.a.| * & ||.(x + y).|| <= + )

let a be Real; :: thesis: ( ( = 0 implies x = H1(X) ) & ( x = H1(X) implies = 0 ) & ||.(a * x).|| = |.a.| * & ||.(x + y).|| <= + )
reconsider u = x, w = y as VECTOR of () ;
H1(X) = 0. the RealLinearSpace by RLSUB_1:11;
hence ( = 0 iff x = H1(X) ) by ; :: thesis: ( ||.(a * x).|| = |.a.| * & ||.(x + y).|| <= + )
a * x = a * u ;
hence ||.(a * x).|| = |.a.| * by Lm3; :: thesis: ||.(x + y).|| <= +
x + y = u + w ;
hence ||.(x + y).|| <= + by Lm4; :: thesis: verum
end;

definition
let IT be non empty NORMSTR ;
attr IT is RealNormSpace-like means :Def1: :: NORMSP_1:def 1
for x, y being Point of IT
for a being Real holds
( ||.(a * x).|| = |.a.| * & ||.(x + y).|| <= + );
end;

:: deftheorem Def1 defines RealNormSpace-like NORMSP_1:def 1 :
for IT being non empty NORMSTR holds
( IT is RealNormSpace-like iff for x, y being Point of IT
for a being Real holds
( ||.(a * x).|| = |.a.| * & ||.(x + y).|| <= + ) );

registration
existence
ex b1 being non empty NORMSTR st
( b1 is reflexive & b1 is discerning & b1 is RealNormSpace-like & b1 is vector-distributive & b1 is scalar-distributive & b1 is scalar-associative & b1 is scalar-unital & b1 is Abelian & b1 is add-associative & b1 is right_zeroed & b1 is right_complementable & b1 is strict )
proof end;
end;

definition end;

theorem :: NORMSP_1:1
for RNS being RealNormSpace holds ||.(0. RNS).|| = 0 ;

theorem Th2: :: NORMSP_1:2
for RNS being RealNormSpace
for x being Point of RNS holds ||.(- x).|| =
proof end;

theorem Th3: :: NORMSP_1:3
for RNS being RealNormSpace
for x, y being Point of RNS holds ||.(x - y).|| <= +
proof end;

theorem Th4: :: NORMSP_1:4
for RNS being RealNormSpace
for x being Point of RNS holds 0 <=
proof end;

registration
let RNS be RealNormSpace;
let x be Point of RNS;
cluster -> non negative ;
coherence
not is negative
by Th4;
end;

theorem :: NORMSP_1:5
for a, b being Real
for RNS being RealNormSpace
for x, y being Point of RNS holds ||.((a * x) + (b * y)).|| <= () + ()
proof end;

theorem Th6: :: NORMSP_1:6
for RNS being RealNormSpace
for x, y being Point of RNS holds
( ||.(x - y).|| = 0 iff x = y )
proof end;

theorem Th7: :: NORMSP_1:7
for RNS being RealNormSpace
for x, y being Point of RNS holds ||.(x - y).|| = ||.(y - x).||
proof end;

theorem Th8: :: NORMSP_1:8
for RNS being RealNormSpace
for x, y being Point of RNS holds - <= ||.(x - y).||
proof end;

theorem Th9: :: NORMSP_1:9
for RNS being RealNormSpace
for x, y being Point of RNS holds |.().| <= ||.(x - y).||
proof end;

theorem Th10: :: NORMSP_1:10
for RNS being RealNormSpace
for x, y, z being Point of RNS holds ||.(x - z).|| <= ||.(x - y).|| + ||.(y - z).||
proof end;

theorem :: NORMSP_1:11
for RNS being RealNormSpace
for x, y being Point of RNS st x <> y holds
||.(x - y).|| <> 0 by Th6;

theorem :: NORMSP_1:12
for f being Function
for RNS being non empty 1-sorted
for x being Element of RNS holds
( f is sequence of RNS iff ( dom f = NAT & ( for d being set st d in NAT holds
f . d is Element of RNS ) ) )
proof end;

theorem :: NORMSP_1:13
for RNS being non empty 1-sorted
for x being Element of RNS ex S being sequence of RNS st rng S = {x}
proof end;

theorem :: NORMSP_1:14
for RNS being non empty 1-sorted
for S being sequence of RNS st ex x being Element of RNS st
for n being Nat holds S . n = x holds
ex x being Element of RNS st rng S = {x}
proof end;

theorem :: NORMSP_1:15
for RNS being non empty 1-sorted
for S being sequence of RNS st ex x being Element of RNS st rng S = {x} holds
for n being Nat holds S . n = S . (n + 1)
proof end;

theorem :: NORMSP_1:16
for RNS being non empty 1-sorted
for S being sequence of RNS st ( for n being Nat holds S . n = S . (n + 1) ) holds
for n, k being Nat holds S . n = S . (n + k)
proof end;

theorem :: NORMSP_1:17
for RNS being non empty 1-sorted
for S being sequence of RNS st ( for n, k being Nat holds S . n = S . (n + k) ) holds
for n, m being Nat holds S . n = S . m
proof end;

theorem :: NORMSP_1:18
for RNS being non empty 1-sorted
for S being sequence of RNS st ( for n, m being Nat holds S . n = S . m ) holds
ex x being Element of RNS st
for n being Nat holds S . n = x
proof end;

definition
let RNS be non empty addLoopStr ;
let S1, S2 be sequence of RNS;
func S1 + S2 -> sequence of RNS means :Def2: :: NORMSP_1:def 2
for n being Nat holds it . n = (S1 . n) + (S2 . n);
existence
ex b1 being sequence of RNS st
for n being Nat holds b1 . n = (S1 . n) + (S2 . n)
proof end;
uniqueness
for b1, b2 being sequence of RNS st ( for n being Nat holds b1 . n = (S1 . n) + (S2 . n) ) & ( for n being Nat holds b2 . n = (S1 . n) + (S2 . n) ) holds
b1 = b2
proof end;
end;

:: deftheorem Def2 defines + NORMSP_1:def 2 :
for RNS being non empty addLoopStr
for S1, S2, b4 being sequence of RNS holds
( b4 = S1 + S2 iff for n being Nat holds b4 . n = (S1 . n) + (S2 . n) );

definition
let RNS be non empty addLoopStr ;
let S1, S2 be sequence of RNS;
func S1 - S2 -> sequence of RNS means :Def3: :: NORMSP_1:def 3
for n being Nat holds it . n = (S1 . n) - (S2 . n);
existence
ex b1 being sequence of RNS st
for n being Nat holds b1 . n = (S1 . n) - (S2 . n)
proof end;
uniqueness
for b1, b2 being sequence of RNS st ( for n being Nat holds b1 . n = (S1 . n) - (S2 . n) ) & ( for n being Nat holds b2 . n = (S1 . n) - (S2 . n) ) holds
b1 = b2
proof end;
end;

:: deftheorem Def3 defines - NORMSP_1:def 3 :
for RNS being non empty addLoopStr
for S1, S2, b4 being sequence of RNS holds
( b4 = S1 - S2 iff for n being Nat holds b4 . n = (S1 . n) - (S2 . n) );

definition
let RNS be non empty addLoopStr ;
let S be sequence of RNS;
let x be Element of RNS;
func S - x -> sequence of RNS means :Def4: :: NORMSP_1:def 4
for n being Nat holds it . n = (S . n) - x;
existence
ex b1 being sequence of RNS st
for n being Nat holds b1 . n = (S . n) - x
proof end;
uniqueness
for b1, b2 being sequence of RNS st ( for n being Nat holds b1 . n = (S . n) - x ) & ( for n being Nat holds b2 . n = (S . n) - x ) holds
b1 = b2
proof end;
end;

:: deftheorem Def4 defines - NORMSP_1:def 4 :
for RNS being non empty addLoopStr
for S being sequence of RNS
for x being Element of RNS
for b4 being sequence of RNS holds
( b4 = S - x iff for n being Nat holds b4 . n = (S . n) - x );

definition
let RNS be non empty RLSStruct ;
let S be sequence of RNS;
let a be Real;
func a * S -> sequence of RNS means :Def5: :: NORMSP_1:def 5
for n being Nat holds it . n = a * (S . n);
existence
ex b1 being sequence of RNS st
for n being Nat holds b1 . n = a * (S . n)
proof end;
uniqueness
for b1, b2 being sequence of RNS st ( for n being Nat holds b1 . n = a * (S . n) ) & ( for n being Nat holds b2 . n = a * (S . n) ) holds
b1 = b2
proof end;
end;

:: deftheorem Def5 defines * NORMSP_1:def 5 :
for RNS being non empty RLSStruct
for S being sequence of RNS
for a being Real
for b4 being sequence of RNS holds
( b4 = a * S iff for n being Nat holds b4 . n = a * (S . n) );

definition
let RNS be RealNormSpace;
let S be sequence of RNS;
attr S is convergent means :: NORMSP_1:def 6
ex g being Point of RNS st
for r being Real st 0 < r holds
ex m being Nat st
for n being Nat st m <= n holds
||.((S . n) - g).|| < r;
end;

:: deftheorem defines convergent NORMSP_1:def 6 :
for RNS being RealNormSpace
for S being sequence of RNS holds
( S is convergent iff ex g being Point of RNS st
for r being Real st 0 < r holds
ex m being Nat st
for n being Nat st m <= n holds
||.((S . n) - g).|| < r );

theorem Th19: :: NORMSP_1:19
for RNS being RealNormSpace
for S1, S2 being sequence of RNS st S1 is convergent & S2 is convergent holds
S1 + S2 is convergent
proof end;

theorem Th20: :: NORMSP_1:20
for RNS being RealNormSpace
for S1, S2 being sequence of RNS st S1 is convergent & S2 is convergent holds
S1 - S2 is convergent
proof end;

theorem Th21: :: NORMSP_1:21
for RNS being RealNormSpace
for x being Point of RNS
for S being sequence of RNS st S is convergent holds
S - x is convergent
proof end;

theorem Th22: :: NORMSP_1:22
for a being Real
for RNS being RealNormSpace
for S being sequence of RNS st S is convergent holds
a * S is convergent
proof end;

theorem Th23: :: NORMSP_1:23
for RNS being RealNormSpace
for S being sequence of RNS st S is convergent holds
is convergent
proof end;

definition
let RNS be RealNormSpace;
let S be sequence of RNS;
assume A1: S is convergent ;
func lim S -> Point of RNS means :Def7: :: NORMSP_1:def 7
for r being Real st 0 < r holds
ex m being Nat st
for n being Nat st m <= n holds
||.((S . n) - it).|| < r;
existence
ex b1 being Point of RNS st
for r being Real st 0 < r holds
ex m being Nat st
for n being Nat st m <= n holds
||.((S . n) - b1).|| < r
by A1;
uniqueness
for b1, b2 being Point of RNS st ( for r being Real st 0 < r holds
ex m being Nat st
for n being Nat st m <= n holds
||.((S . n) - b1).|| < r ) & ( for r being Real st 0 < r holds
ex m being Nat st
for n being Nat st m <= n holds
||.((S . n) - b2).|| < r ) holds
b1 = b2
proof end;
end;

:: deftheorem Def7 defines lim NORMSP_1:def 7 :
for RNS being RealNormSpace
for S being sequence of RNS st S is convergent holds
for b3 being Point of RNS holds
( b3 = lim S iff for r being Real st 0 < r holds
ex m being Nat st
for n being Nat st m <= n holds
||.((S . n) - b3).|| < r );

theorem :: NORMSP_1:24
for RNS being RealNormSpace
for g being Point of RNS
for S being sequence of RNS st S is convergent & lim S = g holds
( ||.(S - g).|| is convergent & lim ||.(S - g).|| = 0 )
proof end;

theorem :: NORMSP_1:25
for RNS being RealNormSpace
for S1, S2 being sequence of RNS st S1 is convergent & S2 is convergent holds
lim (S1 + S2) = (lim S1) + (lim S2)
proof end;

theorem :: NORMSP_1:26
for RNS being RealNormSpace
for S1, S2 being sequence of RNS st S1 is convergent & S2 is convergent holds
lim (S1 - S2) = (lim S1) - (lim S2)
proof end;

theorem :: NORMSP_1:27
for RNS being RealNormSpace
for x being Point of RNS
for S being sequence of RNS st S is convergent holds
lim (S - x) = (lim S) - x
proof end;

theorem :: NORMSP_1:28
for a being Real
for RNS being RealNormSpace
for S being sequence of RNS st S is convergent holds
lim (a * S) = a * (lim S)
proof end;