petsc

Convert a list of Vector to a matrix with petsc4py

Convert a list of Vector to a matrix with petsc4py Question: I have a list of vectors that I want to gather in a single matrix Z. Here is the code I tried to use : import sys, slepc4py slepc4py.init(sys.argv) from petsc4py import PETSc from slepc4py import SLEPc n = 5 d = 10 l …

Total answers: 2