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.


Type representing variables

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.


testtype(obj, Type::Unknown)


Type::Unknown represents identifiers and indexed identifiers.

The call testtype(obj, Type::Unknown) checks, whether obj is an identifier or an indexed identifier with an integer index. If it is, the call returns TRUE, otherwise FALSE.

An identifier has the domain type DOM_IDENT. An indexed identifier is an expression with type_index and two operands, the first of which is an identifier and the second one is an integer. A local variable is not of type Type::Unknown.

This type does not represent a property.


Example 1

Type::Unknown accepts identifiers:

testtype(x, Type::Unknown)

x[0] is an indexed identifier accepted by Type::Unknown:

testtype(x[0], Type::Unknown)

The index must be an integer:

testtype(x[-1], Type::Unknown),
testtype(x[1.0], Type::Unknown)



Any MuPAD® object

Return Values

See testtype

See Also

MuPAD Functions

Was this topic helpful?