triu#

swordfish.function.triu()#

If k is not specified: return the upper triangular portion of matrix X.

If k is specified: return the elements on and above the k-th diagonal of X.

Parameters:
  • X (Constant) – A matrix.

  • k (Constant, optional) – An integer, by default DFLT