If $f(xy) = f(x)+f(y)+xy-x-y$ and $f'(1)=4$, evaluate $f$

Let a differentiable function 'f' satisfy the functional rule $$f(xy) = f(x)+f(y)+xy-x-y\quad \forall x,y >0 \text{ and } f'(1)=4.$$

Evaluate 'f'

So for this I was taught to start by differentiating with respect to y , keeping x constant. This yields : $$f'(xy)x = f'(y)+x-1$$ Now we put $$y =1$$ , so

$$f'(x)=f'(1)+x-1$$ And the we solve by integrating it.

But the main problem I have is why did we differentiated only with respect to y. I mean both are changing parameters. Even if we consider x as constant and y as changing parameter, in the next step itself, we do the opposite by fixing y as 1 and making x as changing parameter. What exactly is going on here ??

I was only taught this algorithm and not the reason/theory behind it. Please help

Also as @LuisFelipe points out that this is valid as it's symmetric , I would also like to inquired about what would happen if it's not symmetric ?? Does this way break down ?? Is there some limitations to it ?? When can it not be used ??

• Related: Solve this calculus questions Commented Aug 2, 2019 at 18:26
• Is your question about why the logic is valid, or why you should follow this particular procedure to solve the problem? Commented Aug 2, 2019 at 18:49
• since the equation is symetric, you can differentiate respect y or x, the functions will be the same but in different variable
– L F
Commented Aug 2, 2019 at 21:35
• @EricWofsey I would say both... I really don't get the idea of differentiating it by taking x const and then in the next step making it a variable Commented Aug 3, 2019 at 6:51
• @LuisFelipe what would happen if it's not symmetric ?? Does this way break down ?? Is there some limitations to it ?? When can it not be used ?? Commented Aug 3, 2019 at 6:52

With the differentiation for $$y$$ you establish a functional equation connecting the scalar functions $$f'$$ and $$f$$. This equation is valid for all pairs $$(x,y)$$, you can choose to restrict them to the subset of pairs $$(x,1)$$. This you then recognize as ODE for the scalar function $$f$$, that is, there is only one variable in the differential equation.
Alternatively you can solve this functional equation without differential calculus by considering the obvious grouping of terms related to the substitution $$g(x)=f(x)-x$$. Then $$g(xy)=g(x)+g(y)$$ is one of the fundamental Cauchy functional equations and has the logarithms as non-trivial continuous solutions, $$g(x)=\log_b|x|$$, $$x\ne 0$$, $$b>0$$. The trivial solution $$g(x)=0$$ also exists.