Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

κ\kappaκ-exponential, κ\kappaκ-Gaussian, κ\kappaκ-objective function and influence function

Definition
Arxiv2405_15536_Basic

by Xeroth · Nov 25, 2026 · Mathlib 0df444a (Lean v4.33.1)

full-waveform-inversioninfluence-functionkaniadakis-statisticskappa-exponentialrobust-statistics

Objects of Sections 2.1 and 2.2 of da Silva and Kaniadakis (2024).

  1. κ-exponential (eq. 9). For κ≠0\kappa\neq0κ=0 and y∈Ry\in\mathbb{R}y∈R, exp⁡κ(y)=(1+κ2y2+κy)1/κ\exp_\kappa(y)=\big(\sqrt{1+\kappa^2y^2}+\kappa y\big)^{1/\kappa}expκ​(y)=(1+κ2y2​+κy)1/κ; the base is always positive. In the classical case exp⁡0=exp⁡\exp_0=\expexp0​=exp.
  2. κ-Gaussian (eqs. 6-8). pκ(ε)=exp⁡κ(−βκε2)/Zκp_\kappa(\varepsilon)=\exp_\kappa(-\beta_\kappa\varepsilon^2)/Z_\kappapκ​(ε)=expκ​(−βκ​ε2)/Zκ​, where, writing a=1/∣2κ∣a=1/|2\kappa|a=1/∣2κ∣,
βκ=∣2κ∣−12 1+12∣κ∣1+32∣κ∣ Γ(a−34) Γ(a+14)Γ(a+34) Γ(a−14),Zκ=πβκ ∣2κ∣−1/21+12∣κ∣ Γ(a−14)Γ(a+14)\beta_\kappa=\frac{|2\kappa|^{-1}}{2}\,\frac{1+\frac12|\kappa|}{1+\frac32|\kappa|}\,\frac{\Gamma(a-\frac34)\,\Gamma(a+\frac14)}{\Gamma(a+\frac34)\,\Gamma(a-\frac14)},\qquad Z_\kappa=\sqrt{\frac{\pi}{\beta_\kappa}}\,\frac{|2\kappa|^{-1/2}}{1+\frac12|\kappa|}\,\frac{\Gamma(a-\frac14)}{\Gamma(a+\frac14)}βκ​=2∣2κ∣−1​1+23​∣κ∣1+21​∣κ∣​Γ(a+43​)Γ(a−41​)Γ(a−43​)Γ(a+41​)​,Zκ​=βκ​π​​1+21​∣κ∣∣2κ∣−1/2​Γ(a+41​)Γ(a−41​)​

for 0<∣κ∣<2/30<|\kappa|<2/30<∣κ∣<2/3, and β0=1/2\beta_0=1/2β0​=1/2, Z0=2πZ_0=\sqrt{2\pi}Z0​=2π​, so that p0p_0p0​ is the standard Gaussian density of eq. (10). 3. κ-likelihood (eq. 11). For finitely many errors (εi)i∈I(\varepsilon_i)_{i\in I}(εi​)i∈I​, Lκ=∏i∈Ipκ(εi)\mathcal L_\kappa=\prod_{i\in I}p_\kappa(\varepsilon_i)Lκ​=∏i∈I​pκ​(εi​). 4. Objective functions (eqs. 1 and 12). For a single residual value, the κ-loss is −ln⁡exp⁡κ(−βκε2)-\ln\exp_\kappa(-\beta_\kappa\varepsilon^2)−lnexpκ​(−βκ​ε2). For residual traces εs,r(t)=Γs,rus(m,t)−ds,r(t)\varepsilon_{s,r}(t)=\Gamma_{s,r}u_s(m,t)-d_{s,r}(t)εs,r​(t)=Γs,r​us​(m,t)−ds,r​(t) over finitely many sources sss and receivers rrr and times t∈[0,T]t\in[0,T]t∈[0,T],

ϕκ=−∑s,r∫0Tln⁡[exp⁡κ(−βκεs,r(t)2)] dt,ϕ0=12∑s,r∫0Tεs,r(t)2 dt.\phi_\kappa=-\sum_{s,r}\int_0^T\ln\big[\exp_\kappa(-\beta_\kappa\varepsilon_{s,r}(t)^2)\big]\,dt,\qquad \phi_0=\frac12\sum_{s,r}\int_0^T\varepsilon_{s,r}(t)^2\,dt.ϕκ​=−s,r∑​∫0T​ln[expκ​(−βκ​εs,r​(t)2)]dt,ϕ0​=21​s,r∑​∫0T​εs,r​(t)2dt.
  1. Influence function (eq. 13). Υκ(ε)\Upsilon_\kappa(\varepsilon)Υκ​(ε) is the derivative with respect to ε\varepsilonε of the κ-loss of a single residual.
  2. Robustness (Hampel). An objective is robust if its influence function satisfies Υ(ε)→0\Upsilon(\varepsilon)\to0Υ(ε)→0 as ε→±∞\varepsilon\to\pm\inftyε→±∞, and non-robust if Υ(ε)→±∞\Upsilon(\varepsilon)\to\pm\inftyΥ(ε)→±∞ as ε→±∞\varepsilon\to\pm\inftyε→±∞.

Formalization Note At κ=0\kappa=0κ=0 the quantities exp⁡0\exp_0exp0​, β0\beta_0β0​, Z0Z_0Z0​ are set to the values the paper gives for the classical limit; all limit statements are taken over κ→0\kappa\to0κ→0 with κ≠0\kappa\neq0κ=0, so they concern the printed formulas. The residual traces are taken as given real functions of time; the acoustic wave equation (2) that produces them is not modelled, since no stated result depends on it. The integrals are Lebesgue integrals over [0,T][0,T][0,T]. "Non-robust" is read with matched signs: Υ→+∞\Upsilon\to+\inftyΥ→+∞ as ε→+∞\varepsilon\to+\inftyε→+∞ and Υ→−∞\Upsilon\to-\inftyΥ→−∞ as ε→−∞\varepsilon\to-\inftyε→−∞.

Definition code
import Mathlib

/-!
da Silva and Kaniadakis, *A graph-space optimal transport FWI approach based on
κ-generalized Gaussian distribution*, arXiv:2405.15536v1 (2024): the κ-exponential, the
κ-Gaussian distribution, the least-squares and κ-objective functions, the influence function
and Hampel's robustness criterion of Sections 2.1 and 2.2.

Conventions. At `κ = 0` the κ-quantities are given the values the paper assigns to them in its
classical limit (Sec. 2.2, text after eq. (10)): `exp_0 = exp`, `β_0 = 1/2`, `Z_0 = √(2π)`.
For `κ ≠ 0` they are the printed formulas (7)-(9), which the paper states for `|κ| < 2/3`.
Residual traces `ε_{s,r}(t) = Γ_{s,r} u_s(m,t) - d_{s,r}(t)` are taken as given real functions
of time, indexed by finite sets of sources and receivers.
-/

open MeasureTheory Filter

noncomputable section

namespace Arxiv2405_15536

/-- Eq. (9), Sec. 2.2, p. 3: the Kaniadakis κ-exponential
`exp_κ(y) = (√(1 + κ² y²) + κ y)^(1/κ)` for `κ ≠ 0` (the base is always positive), and
`exp_0 = exp` (Sec. 2.2, text after eq. (10)). -/
def expKappa (κ y : ℝ) : ℝ :=
  if κ = 0 then Real.exp y else (Real.sqrt (1 + κ ^ 2 * y ^ 2) + κ * y) ^ (1 / κ)

/-- Eq. (8), Sec. 2.2, p. 3: the factor
`β_κ = (|2κ|⁻¹/2) · (1 + |κ|/2)/(1 + 3|κ|/2) · Γ(1/|2κ| - 3/4) Γ(1/|2κ| + 1/4) /
(Γ(1/|2κ| + 3/4) Γ(1/|2κ| - 1/4))` for `κ ≠ 0` (stated for `|κ| < 2/3`), and `β_0 = 1/2`
(text after eq. (10)). -/
def betaKappa (κ : ℝ) : ℝ :=
  if κ = 0 then 1 / 2 else
    (|2 * κ|⁻¹ / 2) * ((1 + |κ| / 2) / (1 + 3 / 2 * |κ|)) *
      (Real.Gamma (1 / |2 * κ| - 3 / 4) * Real.Gamma (1 / |2 * κ| + 1 / 4)) /
      (Real.Gamma (1 / |2 * κ| + 3 / 4) * Real.Gamma (1 / |2 * κ| - 1 / 4))

/-- Eq. (7), Sec. 2.2, p. 3: the normalization constant
`Z_κ = √(π/β_κ) · |2κ|^(-1/2)/(1 + |κ|/2) · Γ(1/|2κ| - 1/4)/Γ(1/|2κ| + 1/4)` for `κ ≠ 0`
(stated for `|κ| < 2/3`), and `Z_0 = √(2π)` (text after eq. (10)). -/
def zKappa (κ : ℝ) : ℝ :=
  if κ = 0 then Real.sqrt (2 * Real.pi) else
    Real.sqrt (Real.pi / betaKappa κ) * (|2 * κ| ^ (-(1 / 2 : ℝ)) / (1 + |κ| / 2)) *
      (Real.Gamma (1 / |2 * κ| - 1 / 4) / Real.Gamma (1 / |2 * κ| + 1 / 4))

/-- Eq. (6), Sec. 2.2, p. 3: the κ-Gaussian density `p_κ(ε) = exp_κ(-β_κ ε²) / Z_κ`. -/
def kappaGaussian (κ ε : ℝ) : ℝ :=
  expKappa κ (-betaKappa κ * ε ^ 2) / zKappa κ

/-- Eq. (11), Sec. 2.2, p. 4: the κ-likelihood `L_κ = ∏_{i=1}^N p_κ(ε_i)` of a finite family of
independent errors `ε_i`, indexed by a finite type of samples. -/
def kappaLikelihood {I : Type*} [Fintype I] (κ : ℝ) (ε : I → ℝ) : ℝ :=
  ∏ i, kappaGaussian κ (ε i)

/-- Eq. (12), Sec. 2.2, p. 4: the κ-objective of a single residual value,
`-ln exp_κ(-β_κ ε²)` (the integrand of eq. (12), plotted in Fig. 1(c)). -/
def lossKappa (κ ε : ℝ) : ℝ :=
  -Real.log (expKappa κ (-betaKappa κ * ε ^ 2))

/-- Eq. (12), Sec. 2.2, p. 4: the κ-objective function
`φ_κ = -∑_{s,r} ∫_0^T ln[exp_κ(-β_κ ε_{s,r}(t)²)] dt` of residual traces `e s r t`
(`s` a source, `r` a receiver, `t ∈ [0, T]` time). -/
def phiKappa {S R : Type*} [Fintype S] [Fintype R] (κ T : ℝ) (e : S → R → ℝ → ℝ) : ℝ :=
  ∑ s, ∑ r, ∫ t in Set.Icc 0 T, lossKappa κ (e s r t)

/-- Eq. (1), Sec. 2.1, p. 2: the least-squares objective
`φ_0 = (1/2) ∑_{s,r} ∫_0^T ε_{s,r}(t)² dt` of residual traces
`ε_{s,r}(t) = Γ_{s,r} u_s(m,t) - d_{s,r}(t)`. -/
def phi0 {S R : Type*} [Fintype S] [Fintype R] (T : ℝ) (e : S → R → ℝ → ℝ) : ℝ :=
  (1 / 2) * ∑ s, ∑ r, ∫ t in Set.Icc 0 T, e s r t ^ 2

/-- Eq. (13), Sec. 2.2, p. 4: the influence function `Υ_κ(ε) = ∂φ_κ/∂ε` of the κ-objective
with respect to a single residual `ε` (for a fixed model), i.e. the derivative of
`ε ↦ -ln exp_κ(-β_κ ε²)`. -/
def influence (κ ε : ℝ) : ℝ :=
  deriv (lossKappa κ) ε

/-- Sec. 2.2, p. 4 (after eq. (13)), following Hampel et al.: an objective whose influence
function `Υ` satisfies `Υ(ε) → 0` as `ε → ±∞` is called robust. -/
def IsRobust (f : ℝ → ℝ) : Prop :=
  Tendsto f atTop (nhds 0) ∧ Tendsto f atBot (nhds 0)

/-- Sec. 2.2, p. 4 (after eq. (13)), following Hampel et al.: an objective whose influence
function `Υ` satisfies `Υ(ε) → ±∞` as `ε → ±∞` is called non-robust. -/
def IsNonRobust (f : ℝ → ℝ) : Prop :=
  Tendsto f atTop atTop ∧ Tendsto f atBot atBot

end Arxiv2405_15536
Source
da Silva and Kaniadakis, A graph-space optimal transport FWI approach based on kappa-generalized Gaussian distribution, arXiv:2405.15536v1 (2024), Sec. 2.1 eq. (1), Sec. 2.2 eqs. (6)-(13) and the robustness criterion after eq. (13), PDF pp. 2-4
Read-back

What the Lean code literally says, in plain math · claude-opus-5-5

exp⁡κ\exp_\kappaexpκ​ (the κ-exponential). For real numbers κ\kappaκ and yyy, with no restriction on either, the value exp⁡κ(y)\exp_\kappa(y)expκ​(y) is defined by cases:

exp⁡κ(y)  =  {ey,κ=0,(1+κ2y2+κy)1/κ,κ≠0.\exp_\kappa(y) \;=\; \begin{cases} e^{y}, & \kappa = 0,\\[4pt] \left(\sqrt{1+\kappa^2 y^2}+\kappa y\right)^{1/\kappa}, & \kappa \neq 0. \end{cases}expκ​(y)=⎩⎨⎧​ey,(1+κ2y2​+κy)1/κ,​κ=0,κ=0.​

The power is the real power xrx^{r}xr with real exponent r=1/κr = 1/\kappar=1/κ. The base 1+κ2y2+κy\sqrt{1+\kappa^2y^2}+\kappa y1+κ2y2​+κy is always strictly positive, because 1+κ2y2>∣κy∣\sqrt{1+\kappa^2y^2} > |\kappa y|1+κ2y2​>∣κy∣. So the power is the ordinary positive one, and exp⁡κ(y)>0\exp_\kappa(y) > 0expκ​(y)>0 for all κ,y\kappa, yκ,y. The case κ=0\kappa = 0κ=0 is a separate definition by fiat, not a limit taken inside the definition. Every nonzero real κ\kappaκ is allowed, including ∣κ∣≥2/3|\kappa| \ge 2/3∣κ∣≥2/3.

βκ\beta_\kappaβκ​ (the β-factor). For any real κ\kappaκ, set β0=12\beta_0 = \tfrac12β0​=21​ by definition. For κ≠0\kappa \ne 0κ=0, write a=1∣2κ∣a = \dfrac{1}{|2\kappa|}a=∣2κ∣1​ and define

βκ  =  ∣2κ∣−12⋅1+∣κ∣21+32∣κ∣⋅Γ ⁣(a−34) Γ ⁣(a+14)Γ ⁣(a+34) Γ ⁣(a−14).\beta_\kappa \;=\; \frac{|2\kappa|^{-1}}{2}\cdot\frac{1+\tfrac{|\kappa|}{2}}{1+\tfrac{3}{2}|\kappa|}\cdot\frac{\Gamma\!\left(a-\tfrac34\right)\,\Gamma\!\left(a+\tfrac14\right)}{\Gamma\!\left(a+\tfrac34\right)\,\Gamma\!\left(a-\tfrac14\right)}.βκ​=2∣2κ∣−1​⋅1+23​∣κ∣1+2∣κ∣​​⋅Γ(a+43​)Γ(a−41​)Γ(a−43​)Γ(a+41​)​.

Here Γ\GammaΓ is the real Gamma function extended to all real arguments. It takes the value 000 at its poles 0,−1,−2,…0, -1, -2, \dots0,−1,−2,…. Division by zero is taken to yield 000. The formula is applied to every nonzero κ\kappaκ with no restriction ∣κ∣<2/3|\kappa| < 2/3∣κ∣<2/3. When ∣κ∣≥2/3|\kappa| \ge 2/3∣κ∣≥2/3, the argument a−34a - \tfrac34a−43​ is ≤0\le 0≤0 and the Gamma function there is evaluated by this extension. In particular, βκ\beta_\kappaβκ​ may be 000 or negative for such κ\kappaκ.

ZκZ_\kappaZκ​ (the normalization constant). For any real κ\kappaκ, set Z0=2πZ_0 = \sqrt{2\pi}Z0​=2π​ by definition. For κ≠0\kappa \ne 0κ=0, again with a=1/∣2κ∣a = 1/|2\kappa|a=1/∣2κ∣, define

Zκ  =  πβκ⋅∣2κ∣−1/21+∣κ∣2⋅Γ ⁣(a−14)Γ ⁣(a+14).Z_\kappa \;=\; \sqrt{\frac{\pi}{\beta_\kappa}}\cdot\frac{|2\kappa|^{-1/2}}{1+\tfrac{|\kappa|}{2}}\cdot\frac{\Gamma\!\left(a-\tfrac14\right)}{\Gamma\!\left(a+\tfrac14\right)}.Zκ​=βκ​π​​⋅1+2∣κ∣​∣2κ∣−1/2​⋅Γ(a+41​)Γ(a−41​)​.

The same conventions apply: Gamma is extended with value 000 at poles, and x/0=0x/0 = 0x/0=0. The square root is the real square root, which returns 000 for negative inputs. Consequently, if βκ≤0\beta_\kappa \le 0βκ​≤0, the first factor is 000 and Zκ=0Z_\kappa = 0Zκ​=0. Nothing in the definition asserts that ZκZ_\kappaZκ​ normalizes anything.

pκp_\kappapκ​ (the κ-Gaussian). For real κ\kappaκ and ε\varepsilonε, define

pκ(ε)  =  exp⁡κ ⁣(−βκ ε2)Zκ,p_\kappa(\varepsilon) \;=\; \frac{\exp_\kappa\!\left(-\beta_\kappa\,\varepsilon^2\right)}{Z_\kappa},pκ​(ε)=Zκ​expκ​(−βκ​ε2)​,

with exp⁡κ\exp_\kappaexpκ​, βκ\beta_\kappaβκ​ and ZκZ_\kappaZκ​ as above. If Zκ=0Z_\kappa = 0Zκ​=0, this is 000 by the division-by-zero convention. This is only a real-valued function of ε\varepsilonε. No statement is made that it is nonnegative, integrable, or integrates to 111.

LκL_\kappaLκ​ (the κ-likelihood). Let III be any finite index set and ε=(εi)i∈I\varepsilon = (\varepsilon_i)_{i\in I}ε=(εi​)i∈I​ any real family. Define

Lκ(ε)  =  ∏i∈Ipκ(εi).L_\kappa(\varepsilon) \;=\; \prod_{i\in I} p_\kappa(\varepsilon_i).Lκ​(ε)=i∈I∏​pκ​(εi​).

If III is empty, the product is 111. No probabilistic independence or distributional assumption appears; this is just a finite product of the values pκ(εi)p_\kappa(\varepsilon_i)pκ​(εi​).

ℓκ\ell_\kappaℓκ​ (the pointwise κ-loss). For real κ\kappaκ and ε\varepsilonε, define

ℓκ(ε)  =  −ln⁡ ⁣(exp⁡κ ⁣(−βκ ε2)).\ell_\kappa(\varepsilon) \;=\; -\ln\!\Big(\exp_\kappa\!\left(-\beta_\kappa\,\varepsilon^2\right)\Big).ℓκ​(ε)=−ln(expκ​(−βκ​ε2)).

Since exp⁡κ\exp_\kappaexpκ​ is always positive, this is the ordinary natural logarithm. At κ=0\kappa = 0κ=0 it equals 12ε2\tfrac12\varepsilon^221​ε2, because β0=12\beta_0 = \tfrac12β0​=21​ and exp⁡0=exp⁡\exp_0 = \expexp0​=exp.

φκ\varphi_\kappaφκ​ (the κ-objective). Let SSS (sources) and RRR (receivers) be finite index sets, and let κ,T\kappa, Tκ,T be arbitrary reals. Let eee assign to each s∈Ss \in Ss∈S and r∈Rr \in Rr∈R an arbitrary function t↦es,r(t)t \mapsto e_{s,r}(t)t↦es,r​(t) from R\mathbb{R}R to R\mathbb{R}R. Define

φκ(e)  =  ∑s∈S∑r∈R∫[0,T]ℓκ(es,r(t)) dt.\varphi_\kappa(e) \;=\; \sum_{s\in S}\sum_{r\in R}\int_{[0,T]} \ell_\kappa\big(e_{s,r}(t)\big)\,dt.φκ​(e)=s∈S∑​r∈R∑​∫[0,T]​ℓκ​(es,r​(t))dt.

The integral is the Lebesgue integral over the closed interval [0,T][0,T][0,T]. The minus sign of the logarithm is already inside ℓκ\ell_\kappaℓκ​, and no further sign is applied. Degenerate cases:

  • No measurability or integrability is assumed. Any non-integrable term contributes 000 by convention.
  • If T<0T < 0T<0, the interval is empty and every integral is 000.
  • If SSS or RRR is empty, φκ=0\varphi_\kappa = 0φκ​=0.

φ0\varphi_0φ0​ (the least-squares objective). With SSS, RRR, TTT and eee as above, define

φ0(e)  =  12∑s∈S∑r∈R∫[0,T]es,r(t)2 dt.\varphi_0(e) \;=\; \frac12\sum_{s\in S}\sum_{r\in R}\int_{[0,T]} e_{s,r}(t)^2\,dt.φ0​(e)=21​s∈S∑​r∈R∑​∫[0,T]​es,r​(t)2dt.

The same conventions apply: non-integrable terms count as 000, the value is 000 for T<0T<0T<0, and it is 000 for empty SSS or RRR. This is a separate definition and is not defined as φκ\varphi_\kappaφκ​ at κ=0\kappa = 0κ=0.

Υκ\Upsilon_\kappaΥκ​ (the influence function). For real κ\kappaκ and ε\varepsilonε, define

Υκ(ε)  =  ddx ℓκ(x)∣x=ε.\Upsilon_\kappa(\varepsilon) \;=\; \frac{d}{dx}\,\ell_\kappa(x)\Big|_{x=\varepsilon}.Υκ​(ε)=dxd​ℓκ​(x)​x=ε​.

This is the ordinary derivative of the one-variable function x↦−ln⁡exp⁡κ(−βκx2)x \mapsto -\ln\exp_\kappa(-\beta_\kappa x^2)x↦−lnexpκ​(−βκ​x2) at the point ε\varepsilonε. If that function is not differentiable at ε\varepsilonε, the value is 000 by convention. It is a derivative with respect to a single real residual value. It is not a derivative of φκ\varphi_\kappaφκ​ with respect to the traces eee.

Robust. A function f:R→Rf:\mathbb{R}\to\mathbb{R}f:R→R (any function, not necessarily an influence function) is called robust when

lim⁡x→+∞f(x)=0andlim⁡x→−∞f(x)=0.\lim_{x\to+\infty} f(x) = 0 \quad\text{and}\quad \lim_{x\to-\infty} f(x) = 0.x→+∞lim​f(x)=0andx→−∞lim​f(x)=0.

Non-robust. A function f:R→Rf:\mathbb{R}\to\mathbb{R}f:R→R is called non-robust when

lim⁡x→+∞f(x)=+∞andlim⁡x→−∞f(x)=−∞.\lim_{x\to+\infty} f(x) = +\infty \quad\text{and}\quad \lim_{x\to-\infty} f(x) = -\infty.x→+∞lim​f(x)=+∞andx→−∞lim​f(x)=−∞.

That is, fff tends to +∞+\infty+∞ at +∞+\infty+∞ and to −∞-\infty−∞ at −∞-\infty−∞, with these specific signs. This is not the negation of "robust": a function can satisfy neither property, for example one tending to a nonzero constant, or one tending to +∞+\infty+∞ in both directions.

Human review
  • Endorsed by Shuze Chen · Nov 25, 2026

    Confirmed by the moderator at approval.

  • Endorsed by Xeroth · Nov 25, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me