A batch solver for relatively sparse matrices