isequaln
Test symbolic objects for equality, treating NaN
values as
equal
Description
returns logical tf
= isequaln(A,B
)1
(true) if A
and B
are the same size and their contents are of equal value. Otherwise,
isequaln
returns logical 0
(false). All
NaN
(not a number) values are considered to be equal to each other.
isequaln
recursively compares the contents of symbolic data
structures and the properties of objects. If all contents in the respective locations are
equal, isequaln
returns logical 1
(true).
returns logical tf
= isequaln(A1,A2,...,An
)1
(true) if all the inputs are equal.
Examples
Input Arguments
Tips
isequaln(A,B)
checks ifA
andB
are the same size and their contents are equal (from coding perspective), treatingNaN
values as equal. To check whether the mathematical comparisonA == B
holds for all values of variables inA
andB
, useisAlways(A == B)
.If one of the input arguments is a symbolic type and the other input is a MATLAB® numeric type with the same value, then
isequaln
returns logical0
(false
) because the inputs are not equal (from coding perspective). For example,tf = isequaln(1,sym(1))
returns0
(false
).