Do You Need A New Battery?
If the battery does not charge, power the computer, or operate at all then the battery is the most likely cause. Faults in the charging circuitry are possible, but not common. Almost all charge/discharge issues are caused by the battery.
Laptops do not need a battery to operate. All laptops will run fine from the AC power adapter with the battery removed. If you suspect that your battery may be causing a problem other than a battery charging/discharging issue, remove the battery and try the computer with the battery removed. If the problem persists without a battery installed then replacing the battery will not solve the issue.
If your rundown is not as expected, if the battery cuts out before it reaches 0%, or the battery does not charge to 100% then calibration may help. These symptoms can be caused by an inaccurate battery meter. The battery meter function is run by a chip located inside of the battery. This chip records data at every full charge and full discharge to automatically calibrate the battery meter. Running through a few full charge-discharge cycles will allow the battery to adjust the battery meter to match the current condition of the battery. If the battery performance is still poor after cycling then the battery will likely need to be replaced.
Getting The Most Out Of A Battery
Batteries are consumable parts that will all eventually wear out an die. Their useful lifespan can vary greatly. The greatest impact on the battery's useful life is how it is taken care of.
A laptop battery is designed to be used on a regular basis; using the battery here and there for partial discharges, with occasional full discharges. This type of usage pattern will give you the most useful life and will automatically take care of all of the maintenance steps that are typically recommended.
Most people falsely believe that they can preserve their battery by not using it. These people plug into AC power all of the time and use their laptop like a desktop computer. In most cases, they find that their battery is not working when they try to use it for a trip after using as a desktop for many months or years. They are typically upset and often blame the battery because they only used it a couple of times.
Even the highest quality batteries can fall victim to this type of usage pattern. The chemicals inside of a battery begin to break down the moment that a battery is made. The two main factors that speed up this process are heat and charge level. Keeping the battery charged to 100% and in a hot environment can kill a battery in as little as a few months. Using a laptop all day long, every day, connected to AC power will create the 100% charge + hot environment that will degrade the battery quickly.
If you will use the computer from AC power most of the time, it is best to charge your battery to 50%, remove it from the computer, and store in a cool location.