Combines array along a dimension. More...

array join (int dim, const array &A, const array &B)
 Join two arrays along dimension dim. More...
 
array join (int dim, const array &A, const array &B, const array &C)
 
array join (int dim, const array &A, const array &B, const array &C, const array &D)
 

Detailed Description

Combines array along a dimension.

This function will combine or join a set of array along a given dimension.

Function Documentation

array af::join ( int  dim,
const array &  A,
const array &  B 
)

Join two arrays along dimension dim.

Parameters
[in]dimalong which to join
[in]A
[in]B
Returns
composite array
array a = constant(1,2,3), b = constant(0,2,3);
print(join(0,a,b));
print(join(1,a,b));
print(join(0, a, a, b, b)); // You can cascade up to four matrices
  join(0,a,b) =
          1.0000     1.0000     1.0000
          1.0000     1.0000     1.0000
          0.0000     0.0000     0.0000
          0.0000     0.0000     0.0000

  join(1,a,b) =
          1.0000     1.0000     1.0000     0.0000     0.0000     0.0000
          1.0000     1.0000     1.0000     0.0000     0.0000     0.0000
Examples:
examples/machine_learning/neuralnetwork.cpp.
array af::join ( int  dim,
const array &  A,
const array &  B,
const array &  C 
)
array af::join ( int  dim,
const array &  A,
const array &  B,
const array &  C,
const array &  D 
)