A brief summary of the math involved as well as a list of ways it is applied in UI design can be found here.