Update cell_matrix.cpp