Interface ScalarField<V>
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Represents a scalar field: f: â„Ââ¿ → â„Â
A scalar field assigns a scalar value to each point in space.
Examples in physics: - Temperature distribution: T(x,y,z) - Potential energy: U(x,y,z) - Pressure: P(x,y,z) - Density: ÃÂ(x,y,z) - Electric potential: Æ(x,y,z)
- Since:
- 1.0
- Author:
- Silvere Martin-Michiellot, Gemini AI (Google DeepMind)
-
Method Summary
Modifier and TypeMethodDescriptiondefault intReturns the dimension of the domain.Evaluates the scalar field at a given point.static <V> ScalarField<V> Creates a scalar field from a lambda expression.static <V> ScalarField<V> Creates a scalar field with known dimension.Methods inherited from interface Function
andThen, apply, compose, contains, evaluate, getBackend, isContinuous, isDifferentiable, setBackendMethods inherited from interface Relation
getCodomain, getDomain
-
Method Details
-
evaluate
-
dimension
default int dimension()Returns the dimension of the domain.Default implementation returns -1 (unknown). Implementations should override this if dimension is known.
- Returns:
- the dimension, or -1 if unknown
-
of
Creates a scalar field from a lambda expression.- Type Parameters:
V- the point type- Parameters:
evaluator- the evaluation function- Returns:
- the scalar field
-
of
Creates a scalar field with known dimension.- Type Parameters:
V- the point type- Parameters:
evaluator- the evaluation functiondimension- the dimension- Returns:
- the scalar field
-