what is the formula used by lending institutions?

when you borrow money there is a formula to determine the amount of monthly payments for a period of time.is it the rule of 72?whatever it is what is it expressed as a formula.
or is it PRT=x?