nurbsSurface.derivativesAt
The partial derivatives ∂S/∂u and ∂S/∂v at (u, v), with respect to knot units.
Usage
surface.derivativesAt(u: number, v: number): [Vector3, Vector3]Parameters
unumberKnot parameter along u, in domainU.
vnumberKnot parameter along v, in domainV.
Returns
[∂S/∂u, ∂S/∂v] in model units per knot unit; one of them is zero along a pole edge. Parameters outside the domains are clamped.
Use instead
nurbsSurface.normalAt: only the unit normal is wanted
Example
const s = NurbsSurface.create([[Point3.of(0, 0, 0), Point3.of(0, 2, 0)], [Point3.of(3, 0, 0), Point3.of(3, 2, 0)]], 1, 1).value
s.derivativesAt(0.5, 0.5) // → [{ x: 3, y: 0, z: 0 }, { x: 0, y: 2, z: 0 }]