Replace lu_decompose() and lu_solve() by one method solve()

The new method first checks whether the class data has changed since the last solve. If it has, it recomputes the LU decomposition with the _lu_decompose() methods. It the solves using the _lu_solve() method.