How to melt sugar evenly? I tried melting some sugar for a sesame caramel bar, but I could't manage to melt it evenly, and I have no idea why.

What I did was: 


I turned the heat on the hot-plate at 2 (out of 4) and put a thick pan on.
I put the sugar in - the layer was about 1/2 to 1cm.
It started melting alright but there was unmelted sugar left on the top, so I tried swirling it (as I've read I should do in that case) but it didn't seem to do anything. I was afraid it might start burning so I tried putting the melted sugar on the top of the unmelted sugar (again according to the instructions) with a spoon, but that didn't work well - it started hardening in lumps.
I managed to melt it somehow and removed it from the heat when it started turning brownish, even though there were still some small lumps left.


The bar I was making turned out quite well despite of this, but I'd still like to know how to melt sugar properly.
Some people/recipe suggest adding a little bit of water at the start to help dissolve the sugar.

Have a lookskie at "wet caramel"