LinAlgError: singular matrix

103 views
Skip to first unread message

Pu ZHANG

unread,
Aug 29, 2016, 1:46:30 AM8/29/16
to qu...@googlegroups.com
Dear all, 

When I simulate a typical emitter-cavity system, the LinAlgError: singular matrix occurs. It does not always occur. For example, it appears if I set truncation photon number N to 40, but doesn't if N = 30. 

What's possible cause of this error, and how can one circumvent it? 

Thanks! 

Best regards, Pu Zhang

--
Faculty at School of Physics, Huazhong University of Science and Technology
Room 819 (N.), Yifu Science and Technology Building
1037 Luoyu Road, Wuhan, China

Pu ZHANG

unread,
Oct 12, 2016, 9:36:18 AM10/12/16
to qu...@googlegroups.com
After some time's simulation, I'm almost sure the singularity error appears due to numerics. The error happens when truncation photon number N is large and excitation weak. Both situations imply essentially empty occupation of high rank Fock states, then I guess the too small occupation can't be distinguished by computer from exact zero and somehow leads to singularity. 

If the above reasoning makes sense, the appearance of the error simply means the truncation has been made at unnecessarily high photon numbers. Lowering N will solve the problem. 

Cheers! 

Best regards, Pu Zhang

--
Faculty at School of Physics, Huazhong University of Science and Technology
Room 819 (N.), Yifu Science and Technology Building
1037 Luoyu Road, Wuhan, China

Reply all
Reply to author
Forward
0 new messages