Source: http://asimtot.files.wordpress.com/2010/06/onto-1-1-and-inverse.pdf