Difference between revisions of "Concat"
m (adding doc status category stub page) |
|||
Line 2: | Line 2: | ||
[[Category:Doc Status D]] <!-- For Lumina use, do not change --> | [[Category:Doc Status D]] <!-- For Lumina use, do not change --> | ||
− | + | = Concat(A,B'',I,J,K'') = | |
+ | |||
+ | Concatenates lists or arrays. | ||
+ | |||
+ | When A and B are 1-D arrays, | ||
+ | Concat(A,B) | ||
+ | returns a list consisting of their elements. This form is often used to concatentate two indexes to obtain the elements for a third index. | ||
+ | |||
+ | When A and B are arbitrary arrays, where A has index I and B has index J, then | ||
+ | Concat(A,B,I,J,K) | ||
+ | concatenates (i.e., joins) arrays A and B, with the new result indexed by K. You must provide an index K whose length is the sum of the lengths of I and J. Often the index K is obtained using the first form of concatenate. | ||
+ | |||
+ | (new to 4.1) You can omit the K parameter: | ||
+ | Concat(A,B,I,J) | ||
+ | when you do so, the function creates a new local index named K for the result. | ||
+ | |||
+ | = Library = | ||
+ | |||
+ | Array functions | ||
+ | |||
+ | = Examples = | ||
+ | |||
+ | Index In1 := ['a','b','c'] | ||
+ | |||
+ | Concat( In1, ['z'] ) &rarry ['a','b','c','z'] | ||
+ | |||
+ | = See Also = | ||
+ | |||
+ | * [[ConcatRows]] | ||
+ | * [[ConcatN]] |
Revision as of 23:22, 22 January 2008
Concat(A,B,I,J,K)
Concatenates lists or arrays.
When A and B are 1-D arrays,
Concat(A,B)
returns a list consisting of their elements. This form is often used to concatentate two indexes to obtain the elements for a third index.
When A and B are arbitrary arrays, where A has index I and B has index J, then
Concat(A,B,I,J,K)
concatenates (i.e., joins) arrays A and B, with the new result indexed by K. You must provide an index K whose length is the sum of the lengths of I and J. Often the index K is obtained using the first form of concatenate.
(new to 4.1) You can omit the K parameter:
Concat(A,B,I,J)
when you do so, the function creates a new local index named K for the result.
Library
Array functions
Examples
Index In1 := ['a','b','c']
Concat( In1, ['z'] ) &rarry ['a','b','c','z']
See Also
Comments
Enable comment auto-refresher