Revision 303 trunk/src/df1b2separable/df1b2ludcmp.cpp
df1b2ludcmp.cpp (revision 303)  

154  154 
df1b2matrix & alpha = dcmp.get_L(); 
155  155  
156  156 
//check if invertable 
157 
df1b2variable det = 1.0;


157 
df1b2variable ln_det = 0.0;


158  158 
for (int i = lb; i <= ub; i++) 
159  159 
{ 
160 
det *= dcmp(i, i);


160 
ln_det += log(dcmp(i, i));


161  161 
} 
162 
if (value(det) == 0.0)


162 
if (exp(value(ln_det)) == 0.0)


163  163 
{ 
164  164 
cerr << 
165  165 
"Error in matrix inverse  matrix singular in solve(df1b2matrix)\n"; 
Also available in: Unified diff