Covariance in Banach spaces #
We define the covariance of a finite measure in a Banach space E
,
as a continuous bilinear form on Dual ℝ E
.
Main definitions #
Let μ
be a finite measure on a normed space E
with the Borel σ-algebra. We then define
Dual.toLp
: the functionMemLp.toLp
as a continuous linear map fromDual 𝕜 E
(forRCLike 𝕜
) into the spaceLp 𝕜 p μ
forp ≥ 1
. This needs a hypothesisMemLp id p μ
(we set it to the junk value 0 if that's not the case).covarianceBilin
: covariance of a measureμ
with∫ x, ‖x‖^2 ∂μ < ∞
on a Banach space, as a continuous bilinear formDual ℝ E →L[ℝ] Dual ℝ E →L[ℝ] ℝ
. If the second moment ofμ
is not finite, we setcovarianceBilin μ = 0
.
Main statements #
covarianceBilin_apply
: the covariance ofμ
onL₁, L₂ : Dual ℝ E
is equal to∫ x, (L₁ x - μ[L₁]) * (L₂ x - μ[L₂]) ∂μ
.covarianceBilin_same_eq_variance
:covarianceBilin μ L L = Var[L; μ]
.
Implementation notes #
The hypothesis that μ
has a second moment is written as MemLp id 2 μ
in the code.
Linear map from the dual to Lp
equal to MemLp.toLp
if MemLp id p μ
and to 0 otherwise.
Equations
- StrongDual.toLpₗ μ p = if h_Lp : MeasureTheory.MemLp id p μ then { toFun := fun (L : StrongDual 𝕜 E) => MeasureTheory.MemLp.toLp ⇑L ⋯, map_add' := ⋯, map_smul' := ⋯ } else 0
Instances For
Continuous linear map from the dual to Lp
equal to MemLp.toLp
if MemLp id p μ
and to 0 otherwise.
Equations
- StrongDual.toLp μ p = { toLinearMap := StrongDual.toLpₗ μ p, cont := ⋯ }
Instances For
Continuous bilinear form with value ∫ x, L₁ x * L₂ x ∂μ
on (L₁, L₂)
.
This is equal to the covariance only if μ
is centered.
Equations
Instances For
Continuous bilinear form with value ∫ x, (L₁ x - μ[L₁]) * (L₂ x - μ[L₂]) ∂μ
on (L₁, L₂)
if MemLp id 2 μ
. If not, we set it to zero.
Equations
- ProbabilityTheory.covarianceBilin μ = ProbabilityTheory.uncenteredCovarianceBilin (MeasureTheory.Measure.map (fun (x : E) => x - ∫ (x : E), x ∂μ) μ)
Instances For
Alias of ProbabilityTheory.covarianceBilin_self_eq_variance
.