next up previous contents
Next: shiftRight Up: リファレンスマニュアル Previous: shiftDown

  
shiftLeft

【目的】
shiftLeft - 全ての列を左方向へシフトする
【形式】
Y = shiftLeft(X)               Y = shiftLeft(X,k)
   (Matrix|Array|Index) Y;        (Matrix|Array|Index) Y;
   (Matrix|Array|Index) X;        (Matrix|Array|Index) X;
                                  Integer k;
【詳細】
shiftLeft(X)は,行列型(行列|配列|指数) X の全ての列を左方向へ 1 列シフトした行列を作る。一番右の列は,ゼロになる。 shiftLeft(X,k)は,左方向へ k 行シフトする。
【例題】
>> Y = shiftLeft([[1 2 3][4 5 6]])
=== [Y] : (  2,  3) ===
           (  1)           (  2)           (  3)     
(  1)  2.00000000E+00  3.00000000E+00  0.00000000E+00
(  2)  5.00000000E+00  6.00000000E+00  0.00000000E+00
【参照】
rotateLeft(2.185), shiftUp(2.210), shiftRight(2.209), shiftDown(2.207)


Masanobu KOGA 平成11年10月2日