JEE MainMathematicsFunctions
Let f, g: N N be functions defined by f(n) = sum of the digits of n , and g(n) = n^2 . If h: N N is defined by h(n) = f(g(n)) , then the function h is
Options
- Aone-one but not onto
- Bneither one-one nor onto
- Conto but not one-one
- Dboth one-one and onto
Correct answer
B. neither one-one nor onto
Step-by-step solution
Given h(n) = f(g(n)) , where g(n) = n^2 and f(x) is the sum of the digits of x . Let us evaluate h(n) for some initial values of n : h(1) = f(1^2) = f(1) = 1 h(2) = f(2^2) = f(4) = 4 h(3) = f(3^2) = f(9) = 9 h(4) = f(4^2) = f(16) = 1 + 6 = 7 h(5) = f(5^2) = f(25) = 2 + 5 = 7 Since h(4) = h(5) = 7 , the function h is not one-one. To check if h is onto, we must determine if every natural number can be the sum of digits of a perfect square. We know that any number modulo 9 is congruent to the sum of its digits modulo