diff options
| -rw-r--r-- | double-error.c | 2 | ||||
| -rw-r--r-- | ratio.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/double-error.c b/double-error.c index 591a820..06d27ae 100644 --- a/double-error.c +++ b/double-error.c @@ -22,7 +22,7 @@ double_error to_exptype(double d){ } bool to_string(char* s, double_error de){ - sprintf(s,"%f +/- %.16f",de.v,de.e); + sprintf(s,"%f +/- %6.1e",de.v,de.e); return true; } @@ -129,6 +129,6 @@ double to_double(rational r){ bool to_string(char* s,rational r){ double f = to_double(r); - sprintf(s,"%llu / %llu = %f +- %.24f",r.n,r.d,f,f*DBL_EPSILON); + sprintf(s,"%llu / %llu = %f +/- %6.1e",r.n,r.d,f,f*DBL_EPSILON); return true; } |
