Added Cell class, changed matrix to take Cell pointers