<< Pow SYMSCI Toolbox Set >>

SYMSCI Toolbox >> SYMSCI Toolbox > Reshape

Reshape

reshape symbolic matrix

Syntax

B = Reshape( A, r, c )

Arguments

A, B

symbolic matrix

r, c

non-negative integer

Description

Returns a (r,c)-matrix B, which is a reshaped version of matrix A. Please note, the number of elements must match, i.e. r*c == elems(A) must hold.

Examples

// create a (3,4)-matrix
A = Mat("a"(ones(3,4)))

// possible reshapes are ...
Reshape(A,1,12)
Reshape(A,2,6)
Reshape(A,4,3)
Reshape(A,6,2)
Reshape(A,12,1)

See Also

Authors

Bibliography

SymEngine: C++ library for fast symbolic manipulation.


Report an issue
<< Pow SYMSCI Toolbox Set >>