Source: http://www.mathforu.com/pdf/Primitives-TS.pdf