On 14 Dec, Daniel Silverstone wrote in message <20101214115541.gb3...@digital-scurf.org>:
> On Tue, Dec 14, 2010 at 09:52:45AM +0000, David H Wild wrote: > > The time remaining is always calculated as if the current downloading > > speed would remain constant at the present value. This is unlikely to be > > true as speeds tend to vary considerably and so the time remaining > > figure is not really useful at all. Either the time should be calculated > > by using the time already passed and the fraction of the file downloaded > > so far, or the time should be dropped from the display with only the > > fraction shown. > > Patches gratefully received. > > If you're not a programmer, then consider contacting Steve Fryatt and > persuading him of your correctness. Not much persuasion necessary: this has niggled me for ages, too. :-) r11081 tries to use a "modified moving average", which if I remember my maths correctly, comes up with an average value weighted to the more recent samples. There are probably all manner of holes that can be picked regarding the fact that the sample points aren't equally spaced, but the result looks fairly sane on the downloads I've tried and it has the advantage of not needing to store and process loads of data on each update. -- Steve Fryatt - Leeds, England Wakefield Acorn & RISC OS Show Saturday 16 April 2011 http://www.stevefryatt.org.uk/ http://www.wakefieldshow.org.uk/