--- imach/src/imach.c 2017/03/08 16:02:28 1.255 +++ imach/src/imach.c 2017/03/27 05:50:23 1.256 @@ -1,6 +1,9 @@ -/* $Id: imach.c,v 1.255 2017/03/08 16:02:28 brouard Exp $ +/* $Id: imach.c,v 1.256 2017/03/27 05:50:23 brouard Exp $ $State: Exp $ $Log: imach.c,v $ + Revision 1.256 2017/03/27 05:50:23 brouard + Summary: Temporary + Revision 1.255 2017/03/08 16:02:28 brouard Summary: IMaCh version 0.99r10 bugs in gnuplot fixed @@ -965,12 +968,12 @@ typedef struct { #define ODIRSEPARATOR '\\' #endif -/* $Id: imach.c,v 1.255 2017/03/08 16:02:28 brouard Exp $ */ +/* $Id: imach.c,v 1.256 2017/03/27 05:50:23 brouard Exp $ */ /* $State: Exp $ */ #include "version.h" char version[]=__IMACH_VERSION__; char copyright[]="February 2016,INED-EUROREVES-Institut de longevite-Japan Society for the Promotion of Science (Grant-in-Aid for Scientific Research 25293121), Intel Software 2015-2018"; -char fullversion[]="$Revision: 1.255 $ $Date: 2017/03/08 16:02:28 $"; +char fullversion[]="$Revision: 1.256 $ $Date: 2017/03/27 05:50:23 $"; char strstart[80]; char optionfilext[10], optionfilefiname[FILENAMELENGTH]; int erreur=0, nberr=0, nbwarn=0; /* Error number, number of errors number of warnings */ @@ -4132,7 +4135,16 @@ void ludcmp(double **a, int n, int *indx big=0.0; for (j=1;j<=n;j++) if ((temp=fabs(a[i][j])) > big) big=temp; - if (big == 0.0) nrerror("Singular matrix in routine ludcmp"); + if (big == 0.0){ + printf(" Singular Hessian matrix at row %d:\n",i); + for (j=1;j<=n;j++) { + printf(" a[%d][%d]=%f,",i,j,a[i][j]); + fprintf(ficlog," a[%d][%d]=%f,",i,j,a[i][j]); + } + fflush(ficlog); + fclose(ficlog); + nrerror("Singular matrix in routine ludcmp"); + } vv[i]=1.0/big; } for (j=1;j<=n;j++) {