Install pARMS library of parallel solvers

If you are using this binary, you can just replace:

matrix A;
set(A, solver = sparsesolver);
real[int] sol = A^-1 * rhs;

by:

load "PETSc"
matrix A;
Mat wrap(A);
set(wrap, sparams = "-pc_type hypre -ksp_converged_reason");
real[int] sol = wrap^-1 * rhs;

You do not have to install hypre yourself. It’s done for you and packaged inside the PETSc plugin.

4 Likes