MATLAB: Checking whether a symbolic expression is an equality or inequality

equationsymbolic

I have the following code involving symbolic variables and symbolic equations:
a = sym;
eqn1 = a <= 10;
eqn2 = a == 10;
I would like to check (programmatically) that the symbolic object in eqn1 represents an inequality (less than) and eqn2 represents an equality. Is possible to do so?
Thanks!

Best Answer

char(feval(symengine, 'op', eqn1, 1))
The defined relationship operators are _equal, _unequal, _approx, _less, and _leequal . A>B is rewritten as _less(B,A) and A>=B is rewritten as _leequal(B,A)