{ } Raw JSON

bundles / scipy 1.18.0 / scipy / linalg / _batched_linalg / _bandwidth

built-in

scipy.linalg._batched_linalg:_bandwidth

Signature

built-in_bandwidth(a, /)

Summary

Compute the lower and upper bandwidth of a 2D array.

Extended Summary

Scans the array for the outermost nonzero entries below and above the main diagonal. For C- or F-contiguous arrays an AVX2-accelerated path is used when available; non-contiguous arrays fall back to a strided scalar scan.

Parameters

a : (N, M) ndarray

Input array of type float32, float64, complex64, or complex128.

Returns

lower : int

Lower bandwidth. 0 means no subdiagonal entries, N-1 means full.

upper : int

Upper bandwidth. 0 means no superdiagonal entries, M-1 means full.

Aliases

  • scipy.linalg._batched_linalg._bandwidth