Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Averaged density, slope parameter and partial derivatives (Verlinde 2016, eqs. 7.45-7.46)

Definition
Verlinde2016_Defs

by LG · Sep 27, 2026 · Mathlib 0df444a (Lean v4.33.1)

emergent-gravitymathematical-physicsverlinde-2016

Definitions shared by the mission.

  • Averaged density (eq. 7.45). For a mass profile M:R→RM:\mathbb R\to\mathbb RM:R→R and radius rrr, ρˉ(r)=3M(r)4πr3\bar\rho(r) = \dfrac{3M(r)}{4\pi r^3}ρˉ​(r)=4πr33M(r)​, i.e. M(r)=4πr33ρˉ(r)M(r) = \frac{4\pi r^3}{3}\bar\rho(r)M(r)=34πr3​ρˉ​(r).
  • Slope parameter (eq. 7.46). For a density profile ρ\rhoρ, β(r)=−dlog⁡ρ(r)dlog⁡r=−r ρ′(r)ρ(r)\beta(r) = -\dfrac{d\log\rho(r)}{d\log r} = -\dfrac{r\,\rho'(r)}{\rho(r)}β(r)=−dlogrdlogρ(r)​=−ρ(r)rρ′(r)​.
  • Partial derivative. For f:Rn→Rf:\mathbb R^n\to\mathbb Rf:Rn→R and i∈{1,…,n}i\in\{1,\dots,n\}i∈{1,…,n}, ∂if(x)\partial_i f(x)∂i​f(x) is the derivative of fff at xxx in the direction of the iii-th standard basis vector.

Lean conventions: division by zero is 000, and the derivative of a function at a point where it is not differentiable is 000; all mission statements apply these only at r>0r>0r>0 where the profiles are differentiable and positive.

Definition code
import Mathlib

namespace Verlinde2016

open Real

/-- Averaged mass density inside a sphere of radius `r` (eq. (7.45)):
`ρ̄(r) = 3 M(r) / (4 π r³)`, i.e. `M(r) = (4 π r³ / 3) ρ̄(r)`. -/
noncomputable def avgDensity (M : ℝ → ℝ) (r : ℝ) : ℝ :=
  3 * M r / (4 * π * r ^ 3)

/-- Slope parameter (eq. (7.46)): `β(r) = - d log ρ(r) / d log r = - r ρ'(r) / ρ(r)`. -/
noncomputable def slopeParam (ρ : ℝ → ℝ) (r : ℝ) : ℝ :=
  -(r * deriv ρ r / ρ r)

/-- The partial derivative `∂ᵢ f` of a function on Euclidean space `ℝⁿ`
in the direction of the `i`-th standard basis vector. -/
noncomputable def partialDeriv {n : ℕ} (i : Fin n) (f : EuclideanSpace ℝ (Fin n) → ℝ) :
    EuclideanSpace ℝ (Fin n) → ℝ :=
  fun x => fderiv ℝ f x (EuclideanSpace.single i 1)

end Verlinde2016
Source
E. Verlinde, Emergent Gravity and the Dark Universe, SciPost Phys. 2, 016 (2017), arXiv:1611.02269v2, https://arxiv.org/abs/1611.02269, p. 40, eqs. (7.45)-(7.46); partial derivatives as in eq. (7.31), p. 35
Read-back

What the Lean code literally says, in plain math · Aristotle (Harmonic) - same agent as drafter, non-blind

Non-blind read-back — not independent testimony. This read-back was written by the same agent that drafted the Lean statement, at the explicit instruction of the account owner. It was not produced blind by an independent auditor, and the author had seen the source paper and the intended meaning while writing it. Reviewers should not treat it as independent evidence of faithfulness and should check the Lean code directly.

The file defines three functions inside the namespace Verlinde2016.

1. Averaged density. For any function M:R→RM:\mathbb R\to\mathbb RM:R→R and any real rrr,

ρˉM(r)=3 M(r)4πr3.\bar\rho_M(r) = \frac{3\,M(r)}{4\pi r^3}.ρˉ​M​(r)=4πr33M(r)​.

At r=0r=0r=0 the denominator vanishes and the value is 000 (division by zero returns 000). No sign or regularity condition on MMM is imposed.

2. Slope parameter. For any function ρ:R→R\rho:\mathbb R\to\mathbb Rρ:R→R and any real rrr,

βρ(r)=−r ρ′(r)ρ(r),\beta_\rho(r) = -\frac{r\,\rho'(r)}{\rho(r)},βρ​(r)=−ρ(r)rρ′(r)​,

where ρ′(r)\rho'(r)ρ′(r) is the ordinary derivative of ρ\rhoρ at rrr when ρ\rhoρ is differentiable at rrr, and is 000 when it is not. If ρ(r)=0\rho(r)=0ρ(r)=0 the quotient is 000, so βρ(r)=0\beta_\rho(r)=0βρ​(r)=0. No logarithm appears in the code; the formula agrees with −dlog⁡∣ρ∣/dlog⁡r-d\log|\rho|/d\log r−dlog∣ρ∣/dlogr where ρ(r)≠0\rho(r)\neq0ρ(r)=0, r>0r>0r>0 and ρ\rhoρ is differentiable.

3. Partial derivative. For a natural number nnn, an index i∈{0,…,n−1}i\in\{0,\dots,n-1\}i∈{0,…,n−1} and a function f:Rn→Rf:\mathbb R^n\to\mathbb Rf:Rn→R (Rn\mathbb R^nRn with its Euclidean structure), ∂if\partial_i f∂i​f is the function

x↦Df(x) [ei],x\mapsto Df(x)\,[e_i],x↦Df(x)[ei​],

the Fréchet derivative of fff at xxx applied to the iii-th standard basis vector eie_iei​. At points where fff is not (Fréchet) differentiable the value is 000.

Human review
  • Endorsed by Shuze Chen · Oct 8, 2026

    Confirmed by the moderator at approval.

  • Endorsed by LG · Oct 8, 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