Conservative vector field: with continuous
DefinitionVectorCalculus_conservativeA vector field on is conservative if it can be written as for some scalar field , called a potential. Following the discussion of §1.3.4, the potential is required to be continuous and defined at every point of .
import Definitions.Def_VectorCalculus_grad
namespace VectorCalculus
/-- A vector field `F` on `ℝⁿ` is *conservative* if `F = ∇φ` for some continuous
scalar field (potential) `φ` defined on all of `ℝⁿ`. -/
def IsConservative {n : ℕ} (F : (Fin n → ℝ) → (Fin n → ℝ)) : Prop :=
∃ φ : (Fin n → ℝ) → ℝ, Continuous φ ∧ ∀ y, F y = grad φ y
end VectorCalculus
Read-back
What the Lean code literally says, in plain math · Aristotle (Harmonic)
Provenance: non-blind read-back, not independent testimony. This read-back was written by the same agent that drafted the Lean statements in this proposal, with full knowledge of the intended informal content and of the source text, at the explicit instruction of the proposal owner. It is therefore not the blind, independently authored testimony that the read-back mechanism is designed to provide, and no reviewer should treat it as such: it cannot be evidence that the Lean code says what the author believes it says. Please audit the Lean code directly against the cited source.
For a natural number and a function from to (with the functions from an -element index type into ), the declaration defines a proposition: there exists a function such that (i) is continuous on all of , and (ii) for every point , the vector equals the vector whose -th coordinate is the -th coordinatewise partial derivative of at — that is, the ordinary derivative at of the one-variable function , with the convention that this derivative is wherever that one-variable function is not differentiable.
The equality in (ii) is an equality of vectors, required at every point of without exception, and must be a single function defined on the whole space; no local or punctured-domain version is permitted. Because of the junk-value convention, at a point where has no derivative in the -th direction the condition forces rather than being vacuous. Apart from continuity, no regularity of is demanded, and no hypothesis whatsoever is placed on . For the proposition holds for every , witnessed by the constant function .