NFA to DFA convertion explanation
You've basically got it. The reason why the a loops is because whichever state you were in, you can end up in any one of them (if you were in 0, maybe you took the looping a and ended up in 0).

The way I think of it is, with the NFA, you are maintaining a list of states you are in at any one point. When you convert to DFA, we have a state for any set of states we can be in (the power set of all the states in the NFA). We can tidy this up if we want (removing inaccessible nodes etc.) but that is the basic principle.

So with yours, you state in state 0. Then we read an a and at this stage we could be in {0, 1}. Then we read in another a and now we could have done:


Been in state 0 and stayed in state 0
Been in state 0 and advanced to state 1
Been in state 1 and advanced to state 2


Therefore we could now be in any of {0, 1, 2} so that's the node we go to in the DFA.