Array1D class, similar support to Array2D.