It's science! It has been proven that heaps of string or hair will inevitably tangle.
The 2008 Ig Nobel Physics prize went to Dorian M. Raymer and Douglas E. Smith for scientifically proving that if it can get tangled it will get tangled! Hair, rope, or string, plus a little agitation, causes a wide variety of knots to form. The conclusion I draw here is that you don't need to do anything and your hair will knot on it's own, provided there's a little agitation in the picture somewhere. And that's scientifically proven.
The actual paper, if you are so inclined...
http://www.ncbi.nlm.nih.gov/pmc/articles/PMC2034230/?tool=pmcentrez
updated by @lisasimpson: 01/13/15 08:55:03PM