Stride is now live! πŸš€ Check out our quick start guide to get started.
logo

Operations

Basic mathematical built-in operators and functions are available.

In addition to basic mathematical operators such as +, -, *, /, ^, and conditionals, Stride also supports the following functions:

Functions

FunctionDescription
abs(x)Absolute value
sqrt(x)Square root
max(x_1, x_2, ...)Maximum value
min(x_1, x_2, ...)Minimum value
sum(x_1, x_2, ...)Sum
prod(x_1, x_2, ...)Product
log(x)Natural log
log10(x)Base 10 log
log2(x)Base 2 log

Matrix Operations

ShortcutOperatorDescription
** or Β·Matrix multiplication (cross product for matrices, dot product for vectors)
.*βŠ™Element-wise multiplication
./⊘Element-wise division
.^Xα΅’ΚΈElement-wise exponentiation, where X is a matrix and y is a scalar

Matrix Functions

FunctionDescription
det(A)Determinant
inv(A)Inverse
transpose(A)Transpose
identity(n)Identity matrix of size n
diag(v)Matrix with vector v on the diagonal

Last updated on

On this page