There is a relatively easy way to calculate distance using an accelerometer: Program it to track steps just like a pedometer, and then multiply the number of steps by the runner's stride length to get your distance total. Voila! Distance calculated. Well, sort of. That's how many apps handle treadmill running, but the problem with this approach is that there's a potential for a huge margin of error.
First, there needs to be input from the runner. That means you'll need to tell your app your height and weight so it can estimate your stride length -- but what if your legs are proportionally longer than another person whose height is close to your own? Some apps will also ask you to run or walk a distance you know is accurate -- say a mile (1.6 kilometers) or so -- while running the app, then tell the app how far you ran so it can adjust those estimates to be more customized to you. The "Nike+ GPS" app for iPhone, for example, lets you update your settings by using its "calibrate run" option to enter your distance after your run, and it will recalculate your stride length for future outings.
But what if you use run/walk intervals for your training? Your walking stride is unlikely to be the same length as your running stride. What if your calibration run was faster or slower than your normal pace? What if your gait is a little uneven, and every stride isn't the same length? As Alex Macmillan told us, "If the stride length measurement is wrong by even a small amount, the total estimated distance can be wrong by a long way." If you've ever used a running app while working out on a treadmill, you've probably noticed a disparity between the distance the app says you run and the treadmill says you run -- evidence of this problem. That's not really ideal if you're trying to train for a long-distance run like a half marathon.
Macmillan's app, "Zombies, Run!" doesn't currently offer accelerometer distance tracking, but his team is working on it, using treadmill research and a different approach to distance calculations. "By only needing to measure the relative change in a person's speed, rather than attempting to accurately estimate the runner's actual speed, we believe we can create a model that works for a very wide range of runners. In this way we hope that the runner's stride length, height and weight will not be important when we make our calculations." Will this approach work? Only time will tell.
Why not just use your treadmill to track your mileage? After all, most treadmills have digital readouts that show you how far you've run based on the movement of the belt passing under your feet. But do a quick Google search for "treadmill distance accuracy" and you'll see that many people feel that the number on your display isn't necessarily correct, either. Even a small miscalculation in belt length can create a big error over the course of the thousands of revolutions it makes around its rollers in the course of 5k training run.
So what can you, as a runner, do to track your treadmill time as accurately as possible?