I'm having a hard time understanding why the complexity of Dijkstra's Algorithm with a Heap is O( (m + n)*log(n) ) where m is the number of edges and n is the number of vertices.
My understanding is:
Now I know one has to do n remove mins. (Each remove min takes log(n) from a heap).
Then one has to do m update keys. (Each update key takes log(n)).
Hence the answer. Is my concept clear? Otherwise can you please explain how to get the time complexity of the Dijkstra's Algorithm.