verify[member] - verify the membership in a list or set
|
Calling Sequence
|
|
verify(expr1, expr2, member)
verify(expr1, expr2, 'member'(ver))
verify(expr1, expr2, 'member'(ver, p))
|
|
Parameters
|
|
expr1
|
-
|
anything
|
expr2
|
-
|
anything, assumed to be of type set or list
|
ver
|
-
|
verification for determining membership
|
p
|
-
|
(optional) name
|
|
|
|
|
Description
|
|
•
|
The verify(expr1, expr2, member), verify(expr1, expr2, 'member'(ver)), and verify(expr1, expr2, 'member'(ver, p)) calling sequences return true if it can be determined that the first argument expr1 is a member of the set or list expr2, where membership is determined either by testing for equality or by using the verification ver.
|
•
|
If a second parameter p is present and a relation is found, then the position of the first element which satisfies the relation of expr2 will be assigned to p.
|
•
|
If true is returned, then the first argument satisfied the relation with at least one of the operands of the second argument. If false is returned, then it did not satisfy the relation for all operands of the second argument. Otherwise, FAIL is returned, indicating that for at least one operand of the second argument it could not be determined whether or not they satisfied the relation (a result of type verify(FAIL)).
|
•
|
This verification is not symmetric.
|
•
|
Since member is a Maple function, it must be enclosed in single quotes to prevent evaluation.
|
•
|
If expr2 is not of type list or set, then false is returned.
|
|
|
Examples
|
|
>
|
|
| (1) |
>
|
|
| (2) |
>
|
|
| (3) |
>
|
|
| (4) |
|
|
Download Help Document
Was this information helpful?