Christoph Pohl <[email protected]> writes: > Dear fellow PETSc users, > > I've been trying to subtract one matrix from another, i.e. Y = Y - X, using > `call MatAXPY(Y, minus_one, X, SAME_NONZERO_PATTERN, ierr)`.
You can only use SAME_NONZERO_PATTERN pattern if the matrices have the same nonzero pattern. These matrices don't even have the same number of nonzeros and there are quite a few entries in different places (neither is a subset of the other). Use DIFFERENT_NONZERO_PATTERN in cases like this.
signature.asc
Description: PGP signature
