ge - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

MTM

 ge
 elementwise greater than or equal to comparison

 Calling Sequence ge(M1,M2)

Parameters

 M1 - matrix, vector, array or scalar M2 - matrix, vector, array or scalar

Description

 • The command ge(M1,M2) performs an elementwise comparison of M1 and M2.
 • For matrices M1 and M2, the result R is a matrix where  R[i,j] = 1, if M1[i,j] >= M2[i,j], and R[i,j] = 0 otherwise.
 • For matrix M1 and scalar M2, the result R is a matrix where  R[i,j] = 1, if M1[i,j] >= M2, and R[i,j] = 0 otherwise.
 • For scalar M1 and matrix M2, the result R is a matrix where  R[i,j] = 1, if M1>= M2[i,j], and R[i,j] = 0 otherwise.
 • For scalars M1 and M2, the result R = 1, if M1 >= M2, and R = 0 otherwise.
 • M1 and M2 must be the same size, or scalars.

Examples

 > $\mathrm{with}\left(\mathrm{MTM}\right):$
 > $\mathrm{M1}≔\mathrm{Matrix}\left(\left[\left[1,2\right],\left[4,4\right]\right]\right):$
 > $\mathrm{M2}≔\mathrm{Matrix}\left(\left[\left[1,2\right],\left[3,5\right]\right]\right):$
 > $\mathrm{ge}\left(\mathrm{M1},\mathrm{M2}\right)$
 $\left[\begin{array}{cc}{1}& {1}\\ {1}& {0}\end{array}\right]$ (1)
 > $\mathrm{M1}≔\mathrm{Matrix}\left(\left[\left[1,2\right],\left[4,4\right]\right]\right):$
 > $\mathrm{ge}\left(\mathrm{M1},2\right)$
 $\left[\begin{array}{cc}{0}& {1}\\ {1}& {1}\end{array}\right]$ (2)