     
     init(_ elements: [[T]]) {
     
-        self.elements = elements.count == 0 ? [[]] : elements
+        self.elements = elements
     }
     
     
     required init(arrayLiteral elements: [T]...) {
         
-        self.elements = elements.count == 0 ? [[]] : elements
+        self.elements = elements
     }
     
     
     init(elementsList: [T], rows: Int) {
         
-        if (elementsList.count % rows != 0) {
+        if elementsList.count % rows != 0 {
             NSException(name: "Wrong number of elements", reason: "The number of elements in the given list is not a multiple of rows.", userInfo: nil).raise()
         }
         
-        self.elements = [[T]]()
-        let columns = elementsList.count / rows
-        
-        for r in 0 ..< rows {
+        self.dimensions = Dimensions(rows, elementsList.count / rows)
+        self.elementsList = elementsList
+    }
+    
+    
+    init(elementsList: [T], columns: Int) {
+        
+        if elementsList.count % columns != 0 {
+            NSException(name: "Wrong number of elements", reason: "The number of elements in the given list is not a multiple of columns.", userInfo: nil).raise()
+        }
+        
+        self.dimensions = Dimensions(elementsList.count / columns, columns)
+        self.elementsList = elementsList
+    }
+    
+    
+    init(elementsList: [T], dimensions: Dimensions) {
+        
+        if elementsList.count % dimensions.rows != 0 && elementsList.count / dimensions.rows != 0 {
+            NSException(name: "Wrong number of elements", reason: "The number of elements in the given list is not a multiple of columns.", userInfo: nil).raise()
+        }
+        
+        self.dimensions = dimensions
+        self.elementsList = elementsList
+    }
+    
+    
+    init(dimensions: Dimensions, generator: (Index) -> T) {
+        
+        self.elementsList = []
+        self.dimensions = dimensions
+        
+        for row in 0 ..< dimensions.rows {
+            for col in 0 ..< dimensions.columns {
+                self.elementsList.append(generator([row, col]))
+            }
+        }
+    }
+    
+    
+    convenience init(size: Int, generator: (Index) -> T) {
+        
+        self.init(dimensions: Dimensions(size, size), generator: generator)
+    }
+    
+    
+    convenience init(randomWithDimensions dimensions: Dimensions, generator: () -> T) {
+        
+        self.init(dimensions: dimensions, generator: { i in return generator() })
+    }
+    
+    
+    convenience init(randomWithSize size: Int, generator: () -> T) {
+        
+        self.init(randomWithDimensions: Dimensions(size, size), generator: generator)
+    }
+    
+    
+    convenience init(randomWithDimensions dimensions: Dimensions, generator: ([ClosedInterval<T.RandomIntervalType>]) -> T, intervals: ClosedInterval<T.RandomIntervalType>...) {
+        
+        self.init(dimensions: dimensions, generator: { i in return generator(intervals) })
+    }
+    
+    
+    convenience init(randomWithSize size: Int, generator: ([ClosedInterval<T.RandomIntervalType>]) -> T, intervals: ClosedInterval<T.RandomIntervalType>...) {
+        
+        self.init(dimensions: Dimensions(size, size), generator: { i in return generator(intervals) })
+    }
+    
+    
+    convenience init(symmetrical elements: [T]) {
+        
+        var matrixElements = [[T]]()
+        
+        let size = (elements.count + 1) / 2
+        
+        for row in 0 ..< size {
             
             var rowElements = [T]()
             
-            for c in 0 ..< columns {
-                
-                rowElements.append(elementsList[r * columns + c])
-            }
-            
-            elements.append(rowElements)
-        }
-    }
-    
-    
-    init(elementsList: [T], columns: Int) {
-        
-        if (elementsList.count % columns != 0) {
-            NSException(name: "Wrong number of elements", reason: "The number of elements in the given list is not a multiple of columns.", userInfo: nil).raise()
-        }
-        
-        self.elements = [[T]]()
-        let rows = elementsList.count / columns
-        
-        for r in 0 ..< rows {
-            
-            var rowElements = [T]()
-            
-            for c in 0 ..< columns {
-                
-                rowElements.append(elementsList[r * columns + c])
-            }
-            
-            elements.append(rowElements)
-        }
-    }
-    
-    
-    init(dimensions: Dimensions, generator: (Index) -> T) {
-        
-        self.elements = []
-        
-        for row in 0 ..< dimensions.rows {
-            
-            var rowElements = [T]()
-            
-            for column in 0 ..< dimensions.columns {
-                
-                rowElements.append(generator([row, column]))
-            }
-            
-            elements.append(rowElements)
-        }
-    }
-    
-    
-    convenience init(size: Int, generator: (Index) -> T) {
-        
-        self.init(dimensions: Dimensions(size, size), generator: generator)
-    }
-    
-    
-    convenience init(randomWithDimensions dimensions: Dimensions, generator: () -> T) {
-        
-        self.init(dimensions: dimensions, generator: { i in return generator() })
-    }
-    
-    
-    convenience init(randomWithSize size: Int, generator: () -> T) {
-        
-        self.init(randomWithDimensions: Dimensions(size, size), generator: generator)
-    }
-    
-    
-    convenience init(randomWithDimensions dimensions: Dimensions, generator: ([ClosedInterval<T.RandomIntervalType>]) -> T, intervals: ClosedInterval<T.RandomIntervalType>...) {
-        
-        self.init(dimensions: dimensions, generator: { i in return generator(intervals) })
-    }
-    
-    
-    convenience init(randomWithSize size: Int, generator: ([ClosedInterval<T.RandomIntervalType>]) -> T, intervals: ClosedInterval<T.RandomIntervalType>...) {
-        
-        self.init(dimensions: Dimensions(size, size), generator: { i in return generator(intervals) })
-    }
-    
-    
-    convenience init(symmetrical elements: [T]) {
-        
-        var matrixElements = [[T]]()
-        
-        let size = (elements.count + 1) / 2
-        
-        for row in 0 ..< size {
-            
-            var rowElements = [T]()
-            
             for column in 0 ..< size {
                 
                 rowElements.append(elements[row + column])

    convenience init(diagonal: [T]) {
        
        self.init(filledWith: 0, size: diagonal.count)
        
        self.diagonalElements = diagonal
    }
    

    var description: String {
        
        return self.elements.description
    }
    
    
