arraylib — Library for array computing in Python#
Namespace functions#
- bind(xp, /, **aliases)#
Return a namespace with arraylib functions bound to xp.
New in version 0.0.0.
Array functions#
- abs(z: float | complex, /) float | complex #
Absolute value |z|.
New in version 0.0.0.
- all(x: bool, /) bool #
Returns true if all entries in x are true.
New in version 0.1.0.
- asinh(z: float | complex, /) float | complex #
Inverse function of hyperbolic sine.
New in version 0.0.0.
- asarray(obj: bool | int | float | complex, /, *, dtype: dtype | None = None) bool | int | float | complex #
Create an array from the input.
New in version 0.0.0.
- astype(x: array, dtype: dtype, /, *, copy=True) array #
Copy the array x as dtype dtype.
New in version 0.0.0.
- ceil(z: float | complex, /) float | complex #
Ceiling function ⌈z⌉.
New in version 0.0.0.
- choose(a: int, x: list[bool | int | float | complex], /) bool | int | float | complex #
Choose array entries from index array a and choices x.
New in version 0.0.0.
- cos(z: float | complex, /) float | complex #
Cosine function cos(z).
New in version 0.0.0.
- cosh(z: float | complex, /) float | complex #
Hyperbolic cosine function cosh(z).
New in version 0.1.0.
- divmod(x1: float | complex, x2: float | complex, /) tuple[float | complex, float | complex] #
Compute quotient and remainder of x1 and x2 simultaneously.
New in version 0.1.0.
- exp(z: float | complex, /) float | complex #
Exponential function exp(z).
New in version 0.0.0.
- finfo(obj: dtype | float | complex, /) finfo_type #
Return information about floating point types.
New in version 0.0.0.
- floor(z: float | complex, /) float | complex #
Floor function ⌊z⌋.
New in version 0.0.0.
- frexp(x: float, /) tuple[float, int] #
Decompose floating point numbers x into factor and exponent.
New in version 0.0.0.
- invsinpi(z: float | complex, /) float | complex #
Inverse sine function 1/sin(πz).
New in version 0.0.0.
- iscomplexobj(a: object, /) bool #
Return whether the input array a is of complex numeric type.
New in version 0.1.0.
- isfinite(z: float | complex, /) bool #
Return where the input array z is finite.
New in version 0.0.0.
- isinf(z: float | complex, /) bool #
Return where the input array z is infinite.
New in version 0.0.0.
- isnan(z: float | complex, /) bool #
Return where the input array z is not a number.
New in version 0.0.0.
- ldexp(x1: float, x2: int, /) float #
Load exponent x2 of the floating points numbers x1.
New in version 0.0.0.
- log(z: float | complex, /) float | complex #
Natural logarithm ln(z).
New in version 0.0.0.
- log2(z: float | complex, /) float | complex #
Logarithm in base 2 log2(z).
New in version 0.0.0.
- loggamma(z, /)#
Log-gamma function ln Γ(z).
New in version 0.0.0.
- logsinpi(z, /)#
Log-sine function ln sin(πz).
New in version 0.0.0.
- max(x: bool | int | float, /, *, axis: int | tuple[int, ...] | None = None, keepdims: bool = False) bool | int | float #
Maximum element function max(x).
New in version 0.0.0.
- min(x: bool | int | float, /, *, axis: int | tuple[int, ...] | None = None, keepdims: bool = False) bool | int | float #
Minimum element function min(x).
New in version 0.0.0.
- modf(z: float | complex) float | complex #
Return the fractional and integer parts of z.
New in version 0.1.0.
- PI(dtype: dtype, /) float #
Return the constant π in the given dtype.
Changed in version 0.1.0.
- pi: float = 3.141592653589793#
Constant π in float precision.
New in version 0.0.0.
- round(z: float | complex, /) float | complex #
Round to nearest integer.
New in version 0.0.0.
- sign(z: float | complex, /) float | complex #
Sign function sign(z).
New in version 0.1.0.
- sin(z: float | complex, /) float | complex #
Sine function sin(z).
New in version 0.0.0.
- sinh(z: float | complex, /) float | complex #
Hyperbolic sine function sinh(z).
New in version 0.1.0.
- sinpi(z: float | complex, /) float | complex #
Sine function sin(πz).
New in version 0.0.0.
- sqrt(z: float | complex, /) float | complex #
Square root √z.
New in version 0.0.0.
- sum(x: bool | int | float | complex, /, *, axis: int | tuple[int, ...] | None = None, dtype: dtype = None, keepdims: bool = False) bool | int | float | complex #
Sum the input array.
New in version 0.0.0.
- ulp(z: float | complex, /) float #
Unit in the last place of input.
New in version 0.0.0.
- where(cond: bool, x1: bool | int | float | complex, x2: bool | int | float | complex, /) bool | int | float | complex #
Return entries from x1 where cond is true, and from x2 otherwise.
New in version 0.0.0.