code: def concatenate(*args):
      
      tmp = _np.array([[1] + [0] * (len(args) - 1)])
      result = kron(_vector.vector(tmp), args[0])
      for i in range(1, len(args)):
          result += kron(_vector.vector(_np.array([[0] * i +
                                                   [1] + [0] * (len(args) - i - 1)])), args[i])
      return result
docs: Concatenates given TT-vectors.
  
      For two tensors :math:`X(i_1,\\ldots,i_d),Y(i_1,\\ldots,i_d)` returns :math:`(d+1)`-dimensional
      tensor :math:`Z(i_0,i_1,\\ldots,i_d)`, :math:`i_0=\\overline{0,1}`, such that
  
      .. math::
         Z(0, i_1, \\ldots, i_d) = X(i_1, \\ldots, i_d),
  
         Z(1, i_1, \\ldots, i_d) = Y(i_1, \\ldots, i_d).