Source: http://www.eecs.umich.edu/vision/teaching/EECS442_2011/lectures/Bundle_Adjustment.pdf