diff options
Diffstat (limited to 'src/get_current.c')
-rw-r--r-- | src/get_current.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/get_current.c b/src/get_current.c index bc786f9..8493370 100644 --- a/src/get_current.c +++ b/src/get_current.c @@ -8,9 +8,12 @@ double *get_voltage(const net_t *instance, cholmod_common *c) { cholmod_dense *x = CHOL_F(solve)(CHOLMOD_A, factor, b, c); if (((double *)x->x)[0] != ((double *)x->x)[0]) { - printf("ERROR: GET_VOLTAGE FAILED\n\n"); - CHOL_F(free_dense)(&x, c); - return NULL; + for (uint_t i = 0; i < instance->graph->ne; i++) { + printf("%d ", instance->fuses[i]); + } + printf("\n"); + printf("GET_VOLTAGE: value is NaN\n"); + exit(EXIT_FAILURE); } double *field = (double *)x->x; |