Weighted binary counter cost

ID: weighted-binary-counter-cost

For an initially zero -bit binary counter, suppose changing bit costs . It changes exactly times in increments. Consequently the total is for . The upper bound counts at most cost at each active position; the lower bound uses for . This shows why exponential position costs cancel the decreasing carry frequencies that make the ordinary binary counter have constant amortized cost.

New to topics? Read the docs here!