Foundations for binary and spherical code bounds #
Elementary coding-theory definitions, projection certificates, and the finite Johnson bound.
The ambient used in the metric-code argument.
Equations
- MetricCodes.Ambient n = EuclideanSpace ℝ (Fin n)
Instances For
The binary word used in the metric-code argument.
Equations
- MetricCodes.BinaryWord n = (Fin n → Bool)
Instances For
The hamming dist used in the metric-code argument.
Equations
- MetricCodes.hammingDist x y = hammingDist x y
Instances For
The binary weight used in the metric-code argument.
Instances For
The predicate asserting binary code.
Equations
- MetricCodes.IsBinaryCode d C = ∀ ⦃x : MetricCodes.BinaryWord n⦄, x ∈ C → ∀ ⦃y : MetricCodes.BinaryWord n⦄, y ∈ C → x ≠ y → d ≤ MetricCodes.hammingDist x y
Instances For
The johnson sphere used in the Johnson-code argument.
Equations
- MetricCodes.JohnsonSphere n w = { x : MetricCodes.BinaryWord n // MetricCodes.binaryWeight x = w }
Instances For
The hamming correlation used in the metric-code argument.
Equations
- MetricCodes.hammingCorrelation x y = 1 - 2 * ↑(MetricCodes.hammingDist x y) / ↑n
Instances For
The boolean harmonic dimension used in the metric-code argument.
Equations
- MetricCodes.booleanHarmonicDimension n 0 = 1
- MetricCodes.booleanHarmonicDimension n k.succ = n.choose (k + 1) - n.choose k
Instances For
The hamming fibre dimension used in the metric-code argument.
Equations
Instances For
The johnson fibre dimension used in the metric-code argument.
Equations
Instances For
The hamming jacobi matrix used in the metric-code argument.
Equations
Instances For
The johnson j1 used in the metric-code argument.
Equations
- MetricCodes.johnsonJ1 w p = ↑w / 2 - ↑p
Instances For
The johnson j2 used in the metric-code argument.
Equations
- MetricCodes.johnsonJ2 n w q = ↑(n - w) / 2 - ↑q
Instances For
The johnson j used in the metric-code argument.
Equations
- MetricCodes.johnsonJ n j = ↑n / 2 - ↑j
Instances For
The johnson m used in the metric-code argument.
Equations
- MetricCodes.johnsonM n w = ↑n / 2 - ↑w
Instances For
The johnson sigma used in the metric-code argument.
Equations
- MetricCodes.johnsonSigma n w p q = MetricCodes.johnsonJ1 w p + MetricCodes.johnsonJ2 n w q
Instances For
The johnson delta used in the metric-code argument.
Equations
- MetricCodes.johnsonDelta n w p q = MetricCodes.johnsonJ2 n w q - MetricCodes.johnsonJ1 w p
Instances For
The johnson mu used in the metric-code argument.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The johnson nu used in the metric-code argument.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The johnson diagonal used in the metric-code argument.
Equations
- MetricCodes.johnsonDiagonal n w p q j = (↑n * MetricCodes.johnsonMu n w p q j - MetricCodes.johnsonM n w ^ 2) / (↑w * ↑(n - w))
Instances For
The johnson edge used in the metric-code argument.
Equations
- MetricCodes.johnsonEdge n w p q j = ↑n * MetricCodes.johnsonNu n w p q j / (↑w * ↑(n - w))
Instances For
The johnson zonal diagonal used in the metric-code argument.
Equations
- MetricCodes.johnsonZonalDiagonal n w j = MetricCodes.johnsonDiagonal n w 0 0 j
Instances For
The johnson zonal edge used in the metric-code argument.
Equations
- MetricCodes.johnsonZonalEdge n w j = MetricCodes.johnsonEdge n w 0 0 j
Instances For
The johnson hatted diagonal used in the metric-code argument.
Equations
- MetricCodes.johnsonHattedDiagonal n w p q j = if j = 0 then 0 else MetricCodes.johnsonDiagonal n w p q j ^ 2 / MetricCodes.johnsonZonalDiagonal n w j
Instances For
The johnson hatted edge used in the metric-code argument.
Equations
- MetricCodes.johnsonHattedEdge n w p q j = MetricCodes.johnsonEdge n w p q j ^ 2 / MetricCodes.johnsonZonalEdge n w j
Instances For
The function used in the binary-code argument.
Equations
- MetricCodes.Boolean.Function n = (Finset (Fin n) → ℝ)
Instances For
The raise used in the binary-code argument.
Equations
- MetricCodes.Boolean.raise f S = ∑ a : Fin n, MetricCodes.Boolean.raiseAt a f S
Instances For
The lower used in the binary-code argument.
Equations
- MetricCodes.Boolean.lower f S = ∑ a : Fin n, MetricCodes.Boolean.lowerAt a f S
Instances For
The predicate asserting harmonic.
Equations
- MetricCodes.Boolean.IsHarmonic k f = (MetricCodes.Boolean.IsLevel k f ∧ ∀ (S : Finset (Fin n)), MetricCodes.Boolean.lower f S = 0)
Instances For
The raise linear used in the binary-code argument.
Equations
- MetricCodes.Boolean.raiseLinear n = { toFun := MetricCodes.Boolean.raise, map_add' := ⋯, map_smul' := ⋯ }
Instances For
The lower linear used in the binary-code argument.
Equations
- MetricCodes.Boolean.lowerLinear n = { toFun := MetricCodes.Boolean.lower, map_add' := ⋯, map_smul' := ⋯ }
Instances For
The raised used in the binary-code argument.
Equations
Instances For
The dot used in the binary-code argument.
Equations
- MetricCodes.Boolean.dot f g = ∑ S : Finset (Fin n), f S * g S
Instances For
Data encoding the projection family construction.
The projection component.
Instances For
The overlap used in the metric-code argument.
Equations
- P.overlap x y = (P.projection x * P.projection y).trace
Instances For
The coordinate function used in the binary-code argument.
Equations
Instances For
The coordinate dot used in the binary-code argument.
Equations
- MetricCodes.Boolean.coordinateDot f g = ∑ a : Fin n, MetricCodes.Boolean.dot (f a) (g a)
Instances For
The delete channel used in the binary-code argument.
Equations
- MetricCodes.Boolean.deleteChannel i f a = (√↑i)⁻¹ • MetricCodes.Boolean.lowerAt a f
Instances For
The layer function used in the binary-code argument.
Equations
- MetricCodes.Boolean.LayerFunction n k = (MetricCodes.Boolean.Level n k → ℝ)
Instances For
The layer extend used in the binary-code argument.
Instances For
The layer restrict used in the binary-code argument.
Equations
- MetricCodes.Boolean.layerRestrict k f S = f ↑S
Instances For
The layer dot used in the binary-code argument.
Equations
- MetricCodes.Boolean.layerDot f g = ∑ S : MetricCodes.Boolean.Level n k, f S * g S
Instances For
The harmonic layer used in the binary-code argument.
Equations
Instances For
The harmonic norm factor used in the binary-code argument.
Equations
- MetricCodes.Boolean.harmonicNormFactor n k r = ∏ j ∈ Finset.range r, MetricCodes.Boolean.harmonicCoefficient n k (j + 1)
Instances For
The harmonic embedding used in the binary-code argument.
Equations
Instances For
The euclidean layer used in the binary-code argument.
Equations
Instances For
The harmonic euclidean layer used in the binary-code argument.
Equations
Instances For
The harmonic orthonormal basis used in the binary-code argument.
Equations
Instances For
The harmonic basis function used in the binary-code argument.
Equations
Instances For
The hamming projection family used in the binary-code argument.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The hamming projection gram feature used in the binary-code argument.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The word support used in the metric-code argument.
Equations
- MetricCodes.wordSupport x = {i : Fin n | x i = true}
Instances For
The johnson dist used in the metric-code argument.
Equations
Instances For
The preceding binomial used in the metric-code argument.
Equations
- MetricCodes.precedingBinomial n 0 = 0
- MetricCodes.precedingBinomial n k.succ = n.choose k
Instances For
The johnson ambient dimension used in the metric-code argument.
Equations
- MetricCodes.johnsonAmbientDimension n a L = ∑ j ∈ Finset.Icc a L, MetricCodes.booleanHarmonicDimension n j
Instances For
The euclidean used in the spherical-code argument.
Equations
Instances For
The code number used in the binary-code argument.
Equations
- MetricCodes.Hamming.codeNumber n d = (MetricCodes.Hamming.validCodes✝ n d).sup fun (C : Finset (MetricCodes.BinaryWord n)) => C.card
Instances For
The ambient dimension used in the binary-code argument.
Equations
- MetricCodes.Hamming.ambientDimension n k L = ∑ j ∈ Finset.range (L - k + 1), n.choose (k + j)
Instances For
The threshold used in the binary-code argument.
Equations
- MetricCodes.Hamming.threshold n d = 1 - 2 * ↑d / ↑n
Instances For
The index used in the binary-code argument.
Equations
- MetricCodes.Hamming.Index k L = Fin (L - k + 1)
Instances For
The space used in the binary-code argument.
Equations
Instances For
The matrix used in the binary-code argument.
Equations
Instances For
The operator used in the binary-code argument.
Equations
Instances For
The continuous operator used in the binary-code argument.
Equations
Instances For
The rayleigh used in the binary-code argument.
Equations
- MetricCodes.Hamming.rayleigh n k L x = (MetricCodes.Hamming.continuousOperator n k L).rayleighQuotient x
Instances For
The top eigenvalue used in the binary-code argument.
Equations
- MetricCodes.Hamming.topEigenvalue n k L = ⨆ (x : { x : MetricCodes.Hamming.Space k L // x ≠ 0 }), MetricCodes.Hamming.rayleigh n k L ↑x
Instances For
The coordinate abs used in the binary-code argument.
Equations
Instances For
The rate set used in the binary-code argument.
Equations
- MetricCodes.Hamming.rateSet δ = {r : ℝ | ∃ (a : ℝ) (b : ℝ), MetricCodes.Hamming.Feasible δ a b ∧ r = MetricCodes.binaryEntropy a - MetricCodes.binaryEntropy b}
Instances For
The variational rate used in the binary-code argument.
Equations
Instances For
The classical parameter used in the binary-code argument.
Instances For
The classical rate used in the binary-code argument.
Equations
Instances For
The longitudinal degree used in the binary-code argument.
Equations
- MetricCodes.Hamming.longitudinalDegree a n = ⌊a * ↑n⌋₊
Instances For
The transverse degree used in the binary-code argument.
Equations
- MetricCodes.Hamming.transverseDegree b n = ⌊b * ↑n⌋₊
Instances For
The terminal vector used in the binary-code argument.
Equations
- MetricCodes.Hamming.terminalVector k L m = WithLp.toLp 2 fun (p : Fin (L - k + 1)) => MetricCodes.Hamming.terminalIndicator (L - k) m ↑p
Instances For
The terminal edge rayleigh used in the binary-code argument.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The binary rate used in the binary-code argument.
Equations
- MetricCodes.Hamming.binaryRate δ = Filter.limsup (fun (n : ℕ) => Real.logb 2 ↑(MetricCodes.Hamming.codeNumber n ⌈δ * ↑n⌉₊) / ↑n) Filter.atTop
Instances For
The window fibre quotient used in the binary-code argument.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The spectral gap used in the binary-code argument.
Equations
- MetricCodes.Hamming.spectralGap δ a b = (MetricCodes.hammingGamma a b - (1 - 2 * δ)) / 4
Instances For
The spectral prefactor used in the binary-code argument.
Equations
Instances For
The binary code number used in the Johnson-code argument.
Equations
- MetricCodes.Johnson.binaryCodeNumber n d = (MetricCodes.Johnson.binaryCodeFamily✝ n d).sup fun (C : Finset (MetricCodes.BinaryWord n)) => C.card
Instances For
The correlation used in the Johnson-code argument.
Equations
- MetricCodes.Johnson.correlation x y = 1 - ↑n * ↑(MetricCodes.johnsonDist x y) / (↑w * ↑(n - w))
Instances For
The coordinate indicator used in the Johnson-code argument.
Equations
Instances For
The geometric axis used in the Johnson-code argument.
Equations
- MetricCodes.Johnson.geometricAxis x = WithLp.toLp 2 fun (i : Fin n) => √(↑n / (↑w * ↑(n - w))) * (MetricCodes.Johnson.coordinateIndicator (↑x) i - ↑w / ↑n)
Instances For
The support coordinates used in the Johnson-code argument.
Equations
Instances For
The complement coordinates used in the Johnson-code argument.
Equations
Instances For
The support coordinate equiv used in the Johnson-code argument.
Instances For
The complement coordinate equiv used in the Johnson-code argument.
Instances For
The harmonic fibre index used in the Johnson-code argument.
Equations
- MetricCodes.Johnson.HarmonicFibreIndex n w p q = (Fin (MetricCodes.hammingFibreDimension w p) × Fin (MetricCodes.hammingFibreDimension (n - w) q))
Instances For
The harmonic fibre index equiv used in the Johnson-code argument.
Equations
Instances For
The shell window index used in the Johnson-code argument.
Equations
- MetricCodes.Johnson.ShellWindowIndex n p q L = ((i : Fin (L - (p + q) + 1)) × Fin (MetricCodes.booleanHarmonicDimension n (p + q + ↑i)))
Instances For
The shell window index equiv used in the Johnson-code argument.
Equations
- MetricCodes.Johnson.shellWindowIndexEquiv n p q L hfirst = Fintype.equivOfCardEq ⋯
Instances For
The index used in the Johnson-code argument.
Instances For
The space used in the Johnson-code argument.
Equations
- MetricCodes.Johnson.Space p q L = EuclideanSpace ℝ (MetricCodes.Johnson.Index p q L)
Instances For
The matrix used in the Johnson-code argument.
Equations
- MetricCodes.Johnson.matrix n w p q L = MetricCodes.johnsonJacobiMatrix n w p q L
Instances For
The operator used in the Johnson-code argument.
Equations
- MetricCodes.Johnson.operator n w p q L = Matrix.toEuclideanLin (MetricCodes.Johnson.matrix n w p q L)
Instances For
The continuous operator used in the Johnson-code argument.
Equations
- MetricCodes.Johnson.continuousOperator n w p q L = LinearMap.toContinuousLinearMap (MetricCodes.Johnson.operator n w p q L)
Instances For
The rayleigh used in the Johnson-code argument.
Equations
- MetricCodes.Johnson.rayleigh n w p q L x = (MetricCodes.Johnson.continuousOperator n w p q L).rayleighQuotient x
Instances For
The top eigenvalue used in the Johnson-code argument.
Equations
- MetricCodes.Johnson.topEigenvalue n w p q L = ⨆ (x : { x : MetricCodes.Johnson.Space p q L // x ≠ 0 }), MetricCodes.Johnson.rayleigh n w p q L ↑x
Instances For
Data encoding the admissible degrees construction.
Instances For
The coordinate abs used in the Johnson-code argument.
Equations
Instances For
The johnson recurrence weight used in the Johnson-code argument.
Equations
- MetricCodes.Johnson.johnsonRecurrenceWeight n x✝ p q L v i = √↑(MetricCodes.booleanHarmonicDimension n (p + q + ↑i)) * v.ofLp i
Instances For
The johnson source channel coefficient used in the Johnson-code argument.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The johnson adjacent block coefficient used in the Johnson-code argument.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The johnson fibre amplitude used in the Johnson-code argument.
Equations
- MetricCodes.Johnson.johnsonFibreAmplitude n w p q L v i = √(MetricCodes.Johnson.johnsonRecurrenceWeight n w p q L v i / MetricCodes.Johnson.johnsonRecurrenceNormalization✝ n w p q L v)
Instances For
Data encoding the projection gram construction.
- projections : ProjectionFamily (JohnsonSphere n w) (johnsonAmbientDimension n (p + q) L) (johnsonFibreDimension n w p q)
The projections component.
- feature : JohnsonSphere n w → EuclideanSpace ℝ (Fin (n * johnsonAmbientDimension n (p + q) L * johnsonAmbientDimension n (p + q) L))
The feature component.
- gram (x y : JohnsonSphere n w) : inner ℝ (self.feature x) (self.feature y) = (correlation x y - topEigenvalue n w p q L) * self.projections.overlap x y
Instances For
The spectral limit used in the Johnson-code argument.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The rank penalty used in the Johnson-code argument.
Equations
- MetricCodes.Johnson.rankPenalty α β γ = α * MetricCodes.binaryEntropy (β / α) + (1 - α) * MetricCodes.binaryEntropy (γ / (1 - α))
Instances For
The shell rate used in the Johnson-code argument.
Equations
Instances For
Data encoding the asymptotic parameters construction.
Instances For
The predicate asserting spectrally feasible.
Equations
Instances For
The feasible used in the Johnson-code argument.
Equations
- MetricCodes.Johnson.Feasible δ α β γ u = (MetricCodes.Johnson.AsymptoticParameters δ α β γ u ∧ MetricCodes.Johnson.IsSpectrallyFeasible δ α β γ u)
Instances For
The rate set used in the Johnson-code argument.
Equations
- MetricCodes.Johnson.rateSet δ = {r : ℝ | ∃ (α : ℝ) (β : ℝ) (γ : ℝ) (u : ℝ), MetricCodes.Johnson.Feasible δ α β γ u ∧ r = MetricCodes.Johnson.shellRate α β γ u}
Instances For
The variational rate used in the Johnson-code argument.
Equations
Instances For
The mrrw g used in the Johnson-code argument.
Equations
- MetricCodes.Johnson.mrrwG v = MetricCodes.binaryEntropy ((1 - √(1 - v)) / 2)
Instances For
The mrrw objective used in the Johnson-code argument.
Equations
- MetricCodes.Johnson.mrrwObjective δ r = 1 + MetricCodes.Johnson.mrrwG (r ^ 2) - MetricCodes.Johnson.mrrwG (r ^ 2 + 2 * δ * r + 2 * δ)
Instances For
The mrrw rate used in the Johnson-code argument.
Equations
Instances For
The combined variational rate used in the Johnson-code argument.