Flux of a charged ball through its boundary sphere is
OpenCoulombGauss.sphereFlux_electricField_ballLet , , , and let be integrable and bounded on the open ball . Let be the field generated by the charge density restricted to . Then its outward flux through the boundary sphere equals the enclosed charge divided by :
In the source this is the sentence "The RHS is the electric flux generated by a charged sphere, and so ".
Formalization Note Boundedness of on the ball guarantees that the field is well defined and integrable on the sphere, where the charges touch it; in the source is continuous on an open set containing the closed ball, which implies it.
import Mathlib import Definitions.Def_CoulombGauss_basic open MeasureTheory Filter Topology Metric
namespace CoulombGauss
theorem sphereFlux_electricField_ball (ε₀ : ℝ) (hε₀ : 0 < ε₀)
(ρ : Vec3 → ℝ) (c : Vec3) (R : ℝ) (hR : 0 < R) (hρ : IntegrableOn ρ (ball c R))
(hbdd : ∃ M : ℝ, ∀ x ∈ ball c R, |ρ x| ≤ M) :
sphereFlux (electricField ε₀ ρ (ball c R)) c R = (1 / ε₀) * ∫ x in ball c R, ρ x := by sorry
end CoulombGaussRead-back
What the Lean code literally says, in plain math · Aristotle (Harmonic)
NON-BLIND READ-BACK — NOT INDEPENDENT TESTIMONY. This read-back was written by the same agent that drafted the Lean statements of this proposal (at the explicit direction of the proposal owner), with full knowledge of the source text and of the intended meaning. It is therefore not a blind audit and must not be mistaken for independent testimony. Reviewers should compare the Lean code against the source directly.
Let be real, any function, , and real. Assume is integrable on the open ball , and that there is a real with for all . Let (kernel read as at ). Conclusion:
with the cone (surface) measure of total mass on the unit sphere and the convention that a non-integrable integrand integrates to . The hypotheses are satisfiable (e.g. constant); no continuity of is assumed.