public Geometrical(FileGws gws, double threshold, double iXmin, double iXmax, double iYmin, double iYmax, int iXcells, int iYcells, double totalH, int numOfL)
            {
                slabs= numOfL;

                firstCellHeightMap = MyMath.interpolatedMap(iXmin, iXmax, iYmin, iYmax, iXcells, iYcells, MyMath.SmoothedMap(HFirstCell(gws.Map(FileGws.MapType.Rough)), threshold));
                GroundHeightMap = MyMath.interpolatedMap(iXmin, iXmax, iYmin, iYmax, iXcells, iYcells, gws.Map(FileGws.MapType.Height));

                xmin = iXmin;
                xmax = iXmax;
                ymin = iYmin;
                ymax = iYmax;

                int x,y;
                x = firstCellHeightMap.data.GetLength(0);
                y = firstCellHeightMap.data.GetLength(1);

                data = new GeometricalColumn[x, y];
                for (int i = 0; i < x; i++)
                {
                    for (int j = 0; j < y; j++)
                    {
                        GeometricalColumn column = new GeometricalColumn(firstCellHeightMap.data[i, j][2], totalH, numOfL, firstCellHeightMap.data[i, j][0], firstCellHeightMap.data[i, j][1], GroundHeightMap.data[i,j][2]);
                        data[i, j] = column;
                    }
                }
            }