lt

Contents

lt#

class saiunit.lax.lt(x, y)#

Elementwise less-than: \(x < y\).

Parameters:
  • x (saiunit.Quantity | Array | ndarray | bool | number | bool | int | float | complex) – First operand.

  • y (saiunit.Quantity | Array | ndarray | bool | number | bool | int | float | complex) – Second operand. Must have the same unit as x.

Returns:

result – Boolean array. Always unitless.

Return type:

bool | Array

Examples

>>> import saiunit as u
>>> import saiunit.lax as sulax
>>> import jax.numpy as jnp
>>> a = jnp.array([1.0, 3.0, 2.0]) * u.second
>>> b = jnp.array([2.0, 2.0, 2.0]) * u.second
>>> sulax.lt(a, b)
Array([ True, False, False], dtype=bool)