I have a tree traversal algorithm which generally operates in O(bm) where b is the branching factor and m is the max depth.
Using iterative deepening, this algorithm is run over and over again, m times at increasing depth:
O(bm) = b⁰ + b¹ + b² + ... + bm
Based on my limited understanding of time complexity, we take the largest element because that is the most significant one over time, and so that element would be bm, where m is the max depth reached.
So, with that knowledge I would conclude that the iterative deepening algorithm also runs in O(bm).
However I have trouble understanding, from a logical standpoint, how the tree traversal could have the exact same time complexity whether the algorithm is run once at depth m, or m times up until depth m.
bm is inherently less than Σk=0,..,mbk. Therefore shouldn't the time complexity on iterative deepening be higher?
Or is there something I don't understand?