setComplement(a,b)

Returns the set of elements that are in one set but not in the other.


Syntax

setComplement(a,b)
a: array any - input set
b: array any - input set
return: array 1D any - array that includes all elements that are part of A but not part of B

Usage

Use this to perform set operation "relative complement", which is analogous to a subtraction.

Location

menu: veeos ==> Math ==> Sets ==> setComplement

library: mathLib

Example

setComplement( [2   3  4  3  5  5  3  1] ,  [6  3  4  7  1] ) returns [2  5]

Notes

setComplement is equivalent to a subtraction of two sets, as in the area of a Venn diagram that is part of set A but not part of set B.

Reference

Dependencies

Supported On

VEE 7.0+, all platforms

See Also

isElement, setAND, setOR, unique


© 2015. All Rights Reserved.  Stan Bischof (stan@worldbadminton.com). Last updated 24 October 2015 19:36. © 2015.