MCPcopy Create free account
hub / github.com/FEniCS/dolfinx / norm

Function norm

python/dolfinx/la/__init__.py:383–393  ·  view source on GitHub ↗

Compute a norm of the vector. Args: x: Vector to measure. type: Norm type to compute. Returns: Computed norm.

(x: Vector[_T], type: _cpp.la.Norm = _cpp.la.Norm.l2)

Source from the content-addressed store, hash-verified

381
382
383def norm(x: Vector[_T], type: _cpp.la.Norm = _cpp.la.Norm.l2) -> np.floating:
384 """Compute a norm of the vector.
385
386 Args:
387 x: Vector to measure.
388 type: Norm type to compute.
389
390 Returns:
391 Computed norm.
392 """
393 return _cpp.la.norm(x._cpp_object, type)

Callers 1

declare_la_functionsFunction · 0.50

Calls 1

normMethod · 0.80

Tested by

no test coverage detected