Recursive Function Definition Math