_exprseq -- expression
sequences
IntroductionThe function call _exprseq(object1,
object2...) is the internal representation of the
expression sequence object1, object2....
Call(s)
object1, object2, ... _exprseq(object1,
object2...)
Parametersobject1, object2, ... |
- | arbitrary MuPAD objects |
Returnsan expression of type "_exprseq" or the void object of
type DOM_NULL.
Related
Functions
Details_exprseq(object1, object2,
...). On the screen, sequences are printed as
object1, object2, ...._exprseq() and the equivalent call
null() yield the void
object of type DOM_NULL.DOM_NULL are removed
from it, automatically.$ operator is a
useful tool for generating sequences._exprseq is a function of the system kernel.
Example
1A sequence is generated by ``concatenating'' objects
with commas. The resulting object is of type
"_exprseq":
>> a, b, sin(x)
a, b, sin(x)
>> op(%, 0), type(%)
_exprseq, "_exprseq"
On the screen, _exprseq just returns its
argument sequence:
>> _exprseq(1, 2, x^2 + 5) = (1, 2, x^2 + 5)
2 2
(1, 2, x + 5) = (1, 2, x + 5)
Example
2The object of domain DOM_NULL (the ``empty
sequence'') is automatically removed from expression sequences:
>> 1, 2, null(), 3
1, 2, 3
Expression sequences are flattened. The following sequence does not have 2 operands, where the second operand is a sequence. Instead, it is flattened to a sequence with 3 operands:
>> x := 1: y := 2, 3: x, y
1, 2, 3
>> delete x, y:
Example
3Sequences are used to build sets and lists. Sequences can also be passed to functions that accept several arguments:
>> s := 1, 2, 3: {s}, [s], f(s)
{1, 2, 3}, [1, 2, 3], f(1, 2, 3)
>> delete s: