Returns recursive sum of digits of a number formed by repeating a number X number of times until sum become single digit .
function repeatedNumberSum ( $ n , $ x ) { $ sum = $ x * digSum ( $ n ) ; return digSum ( $ sum ) ; }