Skip to content

Commit 0903e03

Browse files
committed
increased the precision of the exported results
1 parent 398b46e commit 0903e03

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

modules/cli/src/handlers/solve.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ void print_matrix(DlsMat mat, FILE *output_file, char *name)
154154
{
155155
for (int j = 0; j < SM_COLUMNS_D(mat); j++)
156156
{
157-
fprintf(output_file, "%lf ", SM_ELEMENT_D(mat, i, j));
157+
fprintf(output_file, "%.8lf ", SM_ELEMENT_D(mat, i, j));
158158
}
159159
fprintf(output_file, "\n");
160160
}
@@ -166,7 +166,7 @@ void print_vector(N_Vector vec, FILE *output_file, char *name)
166166
fprintf(output_file, "%ld\n", NV_LENGTH_S(vec));
167167
for (int i = 0; i < NV_LENGTH_S(vec); i++)
168168
{
169-
fprintf(output_file, "%lf ", NV_Ith_S(vec, i));
169+
fprintf(output_file, "%.8lf ", NV_Ith_S(vec, i));
170170
}
171171
fprintf(output_file, "\n");
172172
}

0 commit comments

Comments
 (0)