Standard monadic or dyadic operators

+/-

The expressions +x and -x refer to monadic operators (the first does nothing, the second negates x).

The library syntax is gneg(x) for -x.




+

, -: The expression x + y is the sum and x - y is the difference of x and y. Among the prominent impossibilities are addition/subtraction between a scalar type and a vector or a matrix, between vector/matrices of incompatible sizes and between an intmod and a real number.

The library syntax is gadd(x,y) x + y, gsub(x,y) for x - y.




*

The expression x * y is the product of x and y. Among the prominent impossibilities are multiplication between vector/matrices of incompatible sizes, between an intmod and a real number. Note that because of vector and matrix operations, * is not necessarily commutative. Note also that since multiplication between two column or two row vectors is not allowed, to obtain the scalar product of two vectors of the same length, you must multiply a line vector by a column vector, if necessary by transposing one of the vectors (using the operator ~ or the function mattranspose, see Section [Label: se:linear_algebra]).

If x and y are binary quadratic forms, compose them. See also qfbnucomp and qfbnupow.

The library syntax is gmul(x,y) for x * y. Also available is