Is it better to use a laptop on battery or on AC power?
It won't make all that much difference. What will shorten battery life is temperature: If it gets hot, it will shorten the battery life. Best thing to do, if you are able, is to remove the battery while you're at home and keep it somewhere cool.
If it's a Li-ion battery, then they don't like to be completely discharged, so make sure you charge them regularly. Wikipedia:
Lithium-ion batteries should not be frequently discharged fully and recharged ("deep-cycled"), but this may be necessary after about every 30th recharge to recalibrate any electronic charge monitor (e.g. a battery meter). This allows the monitoring electronics to more accurately estimate battery charge.[26] This has nothing to do with the memory effect.
More tips can be found here:
- http://batteryuniversity.com/learn/article/do_and_dont_battery_table
- http://web.archive.org/web/20090811004517/http://www.friedbeef.com/top-15-ways-to-extend-your-laptop-battery-life/
- http://en.wikipedia.org/wiki/Lithium-ion_battery#Guidelines_for_prolonging_Li-ion_battery_life
- http://ask-leo.com/how_do_i_maximize_my_battery_life.html
Apple has a good page on lithium ion batteries which should apply across the board to other manufacturers, not just Apple. Basically, keep your device (laptop, phone, etc) plugged in whenever possible. When the battery is discharged to around 70-80%, recharging will be another cycle, and batteries only have so many cycles before they need to be replaced.
It is good for the battery to be completely discharged every so often, about once a month.
A lot of people seem to be still giving information about old technologies. for the last few years more or less every device with a (semi) integrated battery will be using li-ion. Devices like hand drills use Ni-MH (usually) as they can provide high current, but they are prone to 'memory effect' this is basically the cells not losing the full capacity and is caused by charging the battery here and there, a bit at a time. These USED to be used for laptops as well, so it would have been better to fully discharge your laptop, then let it fully charge up.
A non-utter crap laptop would then notice that the battery was fully charged, and stop trying to charge it and just run of the mains anyway.
Like I said, Li-ion is the technology that is used today, better in more or less every way except it can't provide high current like other batteries (think car lead acid batteries) but this is not an issue for laptops. A basic Li-ion CELL (cell being the key) is a bit dodgy, if you short them or try to draw too much current they can over heat and explode. if they get too hot, they can explode. if they get discharged too much, they can stop working and you will not be able to charge them.
NOTE THAT I AM TALKING ABOUT CELLS THERE!
In your laptop you have a smart battery. It manages the power for you. It stops charging the cells when they are full, and stops giving power when they are too low. Prevents them getting shorted or having too much current drawn from them. The best thing about Li-ion cells though is that you can just top them up here and there, giving them a bit of power every so often, a full charge. They do how ever have a life time of about two or three years (last I checked anyway) and thus eventually lose their max charge (read time you can run of the battery for).
One key thing to consider (depending on where you live) is power cuts, if you computer suddenly lose AC power, it is not healthy. The same for your laptop, if you have removed the battery. The battery works like a UPS (uninterruptable power supply) so you can still use your laptop and turn it off safely.
erm.. hope that helps, bit long winded :P