This is machine translation

Translated by Microsoft
Mouse over text to see original. Click the button below to return to the English verison of the page.

subset, _subset, _notsubset

Relation "is a subset of"

MuPAD® notebooks are not recommended. Use MATLAB® live scripts instead.

MATLAB live scripts support most MuPAD functionality, though there are some differences. For more information, see Convert MuPAD Notebooks to MATLAB Live Scripts.


A subset B
_subset(A, B)
not A subset B
_notsubset(A, B)


A subset B represents the expression .

A is a subset of B if xAxB.

The function _notsubset exists for typesetting purposes. It is returned as the result of negating a subset expression. See Example 4.

If called with symbolic arguments (anything but sets), these functions return a symbolic expression of type _in or the unevaluated input.


Example 1

When called with two sets, these functions return a Boolean value:

{1} subset {1,2,3},
{} subset {1},
{1} subset {1},
{1} subset {}

Example 2

Note: identifiers in sets are not assumed to be place-holders. See ?= for details on syntactic equality.

{x} subset {1,2}

Example 3

If one of the arguments is not a set, these functions return an equivalent symbolic expression:

{1} subset A, A subset {1}

Example 4

For "pretty typesetting", the negation of subsetis implemented in a special function environment:

not A subset B



A, B

MuPAD® expressions

Return Values

TRUE, FALSE, or an expression.

Overloaded By

A, B

See Also

MuPAD Functions

Was this topic helpful?