In that case, you should use a factorization that can handle singular matrices. 
PETSc's native LU does not, but you can install an external direct solvers that 
is robust for this case, such as MUMPS (see section 3.4.1 of SLEPc users 
manual). With this, you should get the eigenvalues correctly, but the 
eigenvectors will likely be corrupted by components in the nullspace. If you 
want to avoid this, compute a basis of the common nullspace and pass it with 
EPSSetDeflationSpace() before EPSSolve().

Jose


> El 17 ago 2020, a las 2:50, Nidish <n...@rice.edu> escribió:
> 
> Thank you for the example, it is indeed useful!
> 
> In my application, an additional complication is that the stiffness matrix 
> "K" is also singular. So when I run my code with the suggested runtime flags, 
> I persistently get a zero pivot error for the LU calculation (for the st_pc 
> probably). I'm not sure what factorization or solver I should use in this 
> case.
> 
> TLDR: I have K.v=lam*M.v where BOTH K and M are singular. The nullspace of M 
> is a subset of the nullspace of K.
> 
> Thank you,
> Nidish
> 
> On 8/16/20 1:50 AM, Jose E. Roman wrote:
>> Nothing special is required for solving a GHEP with singular M, except for 
>> setting the problem type as GHEP, see 
>> https://slepc.upv.es/documentation/current/src/eps/tutorials/ex13.c.html
>> Jose
>> 
>> 
>>> El 16 ago 2020, a las 1:09, Nidish <n...@rice.edu> escribió:
>>> 
>>> Hello,
>>> 
>>> I'm presently working with a large finite element model with several RBE3 
>>> constraints with "virtual" 6DOF nodes in the model.
>>> 
>>> I have about ~36000 3DOF nodes making up my model and about ~10 RBE3 
>>> virtual nodes (which have zero intrinsic mass and stiffness). I've 
>>> extracted the matrices from Abaqus.
>>> 
>>> The way these constraints are implemented is by introducing static linear 
>>> constraints (populating the stiffness matrix) and padding the mass matrix 
>>> with zero rows and columns in the rows corresponding to the virtual nodes. 
>>> So this leaves me with an eigenproblem of the form,
>>> 
>>> K.v = lam*M.v
>>> 
>>> where M is singular but the eigenproblem is well defined. Abaqus seems to 
>>> solve this perfectly well, but after exporting the matrices, I'm struggling 
>>> to get slepc to solve this. The manual talks about deflation, etc., but I 
>>> couldn't really understand too much.
>>> 
>>> Is there any example code for such a case with a singular matrix where 
>>> these procedures are carried out? Or could you provide references/guidances 
>>> for approaching the problem?
>>> 
>>> Thank you,
>>> Nidish
> -- 
> Nidish

Reply via email to