Matrices can be reduced in size when there are dry cells to potentially reduce memory and solve time.
Currently, if there is a dry cell, a placeholder value is placed in the diagonal of the matrix so that the matrix can be inverted. However, a more elegant solution would be to remove dry (unnecessary) rows/columns from the matrix entirely. We would need to assign the matrix row and column indices to their corresponding cell indices in the mesh and reassign the solved concentration values to the proper cells after solving.
Furthermore, if a cell is dry over the entire simulation horizon, we could potentially remove it from the simulation entirely and free up memory (both in the matrix and in the model mesh itself) to help with #61.
Matrices can be reduced in size when there are dry cells to potentially reduce memory and solve time.
Currently, if there is a dry cell, a placeholder value is placed in the diagonal of the matrix so that the matrix can be inverted. However, a more elegant solution would be to remove dry (unnecessary) rows/columns from the matrix entirely. We would need to assign the matrix row and column indices to their corresponding cell indices in the mesh and reassign the solved concentration values to the proper cells after solving.
Furthermore, if a cell is dry over the entire simulation horizon, we could potentially remove it from the simulation entirely and free up memory (both in the matrix and in the model mesh itself) to help with #61.