Environmental sizing of smartphone batteries