[ltp] Re: Re: help in troubleshooting ACPI drain with 2.6.10 please

Eben King linux-thinkpad@linux-thinkpad.org
Fri, 7 Jan 2005 09:54:37 -0500 (EST)


On Fri, 7 Jan 2005, Jan-Hendrik Benter wrote:

> > > before: 34280 mWh
> > > after: 33140 mWh
> > > diff: -1140 mWh
> > > seconds: 2242 sec
> > > result: -1830 mW
> >
> >            2242
> > 2242 sec = ---- h = 0.6227 h
> >            3600
> >
> > 1830 mWh
> > -------- = 2938 mW = 2.938 W
> > 0.6227 h
> >
> > So your laptop uses power at the rate of 2.9 watts when suspended to RAM.
> 
> No, it is _only_ 1.831 watts, but this is still _too_ much imho.
> 
> result already gives the final value:
> 
> result = (after - before) * 3600 / seconds
                            ^      ^

Those are where the error is.  You're computing "result = energy * 1/time"  
when power is "energy / time".  It needs to be "result = (after - before) /
(seconds / 3600)".

-- 
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?           [TOFU := text oben,
A: Top-posting.                                       followup unten]
Q: What is the most annoying thing on usenet?        -- Daniel Jensen