(Deleted) How to make SLEPcEigenSolver converge?


58
views
0
8 weeks ago by
Hey, I'm computing the eigenvalues of the Laplacian and for more complicated meshes, the Eigensolver doesn't converge. What parameters should I set for the SLEPcEigenSolver? Right now it seems to use Krylov-Schur, is there an algorithm thats faster/more reliable for these kind of problems?

Would refining the mesh (adding more vertices) help?

V = FunctionSpace(mesh, "CG", 1)
bc = DirichletBC(V, 0.0, DomainBoundary())

u = TrialFunction(V)
v = TestFunction(V)

a = inner(grad(u), grad(v)) * dx
L = Constant(0.0) * v * dx
m = u * v * dx

A, _ = assemble_system(a, L, bc)
B = assemble(m)

eig = Function(V)
eig_vec = eig.vector()

solver = SLEPcEigenSolver(as_backend_type(A), as_backend_type(B))
solver.parameters['spectrum'] = "smallest magnitude"
solver.solve(10000)

print("Solved. Computed %d" % solver.get_number_converged() + " Eigenvalue(s).")​
Community: FEniCS Project
Have you read the SLEPc tutorial? http://slepc.upv.es/handson/
written 8 weeks ago by Nate  
Please login to add an answer/comment or follow this question.
The thread is closed. No new answer/comment may be added.

Similar posts:
Search »
  • Nothing matches yet.