CSHIFT intrinsic function

Standard: F77 F90 F95 F2003 F2008 F2018 Example program


<Syntax>

CSHIFT ( ARRAY, SHIFT [ , DIM ] )

ARRAY : array of rank N and any type;
SHIFT : INTEGER, scalar or an array of rank N-1;
DIM : INTEGER scalar, the dimension to shift;

Result: same type and shape as ARRAY.

<Semantics>

The result is obtained by performing a circular shift of dimension DIM of ARRAY; if DIM is absent, it is treated as if it had the value 1 (i.e. the first dimension is shifted). SHIFT specifies the amount to shift each row/column/etc.

<Related>

EOSHIFT intrinsic function, PACK intrinsic function, SPREAD intrinsic function, TRANSPOSE intrinsic function, UNPACK intrinsic function