I have a problem in a demonstration where I have to do a derivative $\frac{df}{dc}$ of
$f=(y-cx)(y-cx)^{*}$
where * denotes the complex conjugate.
In my demonstration the derivative $\frac{df}{dc}$is equal to 0. So I tried to solve it by applying the chain rule:
$x(y-cx)^{*}+x^{*}(y-cx)=0$
obtaining the result:
$c=\frac{xy^{*}+yx^{*}}{2xx^{*}}$
Unfortunately I should have obtained
$c=\frac{yx^{*}}{xx^{*}}$
Can you help me with this derivative of complex number? What am I doing wrongly?