You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Tests each element ``x_i`` of the input array ``x`` to determine if finite (i.e., not ``NaN`` and not equal to positive or negative infinity).
1029
+
Tests each element ``x_i`` of the input array ``x`` to determine if finite.
1030
+
1031
+
**Special Cases**
1032
+
1033
+
For real-valued floating-point operands,
1034
+
1035
+
- If ``x_i`` is either ``+infinity`` or ``-infinity``, the result is ``False``.
1036
+
- If ``x_i`` is ``NaN``, the result is ``False``.
1037
+
- If ``x_i`` is a finite number, the result is ``True``.
1038
+
1039
+
For complex floating-point operands, let ``a = real(x_i)``, ``b = imag(x_i)``, and
1040
+
1041
+
- If ``a`` is ``NaN`` or ``b`` is ``NaN``, the result is ``False``.
1042
+
- If ``a`` is either ``+infinity`` or ``-infinity`` and ``b`` is any value, the result is ``False``.
1043
+
- If ``a`` is any value and ``b`` is either ``+infinity`` or ``-infinity``, the result is ``False``.
1044
+
- If ``a`` is a finite number and ``b`` is a finite number, the result is ``True``.
1030
1045
1031
1046
Parameters
1032
1047
----------
1033
1048
x: array
1034
-
input array. Should have a real-valued data type.
1049
+
input array. Should have a numeric data type.
1035
1050
1036
1051
Returns
1037
1052
-------
1038
1053
out: array
1039
-
an array containing test results. An element ``out_i`` is ``True`` if ``x_i`` is finite and ``False`` otherwise. The returned array must have a data type of ``bool``.
1054
+
an array containing test results. The returned array must have a data type of ``bool``.
0 commit comments