# HG changeset patch # User jwe # Date 1150309131 0 # Node ID ba0bea22167b49268248e66adf8b6bdbdda62f75 # Parent 6bd94066d360a39daed6a5740fa775587ad98913 [project @ 2006-06-14 18:18:51 by jwe] diff -r 6bd94066d360 -r ba0bea22167b scripts/ChangeLog --- a/scripts/ChangeLog Tue Jun 13 18:55:53 2006 +0000 +++ b/scripts/ChangeLog Wed Jun 14 18:18:51 2006 +0000 @@ -1,3 +1,7 @@ +2006-06-14 John W. Eaton + + * time/datevec.m: Attempt to account for precision of datenum format. + 2006-06-01 Quentin H. Spencer * audio/wavread.m: Fix file range error and add read support for diff -r 6bd94066d360 -r ba0bea22167b scripts/time/datevec.m --- a/scripts/time/datevec.m Tue Jun 13 18:55:53 2006 +0000 +++ b/scripts/time/datevec.m Wed Jun 14 18:18:51 2006 +0000 @@ -152,8 +152,12 @@ ++y(m > 12); m(m > 12) -= 12; - ## Convert hour-minute-seconds - s = 86400 * (date - floor (date)); + ## Convert hour-minute-seconds. Attempt to account for precision of + ## datenum format. + + fracd = date - floor (date); + srnd = 10 .^ floor (log10 (365.25*y)); + s = round (86400*fracd.*srnd) ./ srnd; h = floor (s / 3600); s = s - 3600 * h; mi = floor (s / 60); diff -r 6bd94066d360 -r ba0bea22167b src/DLD-FUNCTIONS/fsolve.cc --- a/src/DLD-FUNCTIONS/fsolve.cc Tue Jun 13 18:55:53 2006 +0000 +++ b/src/DLD-FUNCTIONS/fsolve.cc Wed Jun 14 18:18:51 2006 +0000 @@ -62,7 +62,6 @@ octave_idx_type hybrd_info_to_fsolve_info (octave_idx_type info) { - info = -1000; switch (info) { case -1: