Find a complex-differentiable function $f$ with real part $u(x,y) = x^2(ay+8) +4y^2(y+b)$
I have tried to use Cauchy-Riemann to get $v(x,y)$ but realised that I need to find the constants $a$ and $b$ first. Can someone help explain how I can do this?
Note that $u$ is the real part of a complex differentiable function on $\Bbb C$ if and only if $u$ is harmonic, i.e., $\Delta u = 0$. Compute
$$\Delta u(x,y) = 2y(a + 12) + 8(b + 2). \tag{*}$$
The rightmost side of (*) is identically zero if and only if $a = -12$ and $b = -2$. So $u(x,y) = x^2(-12y + 8) + 4y^2(y - 2)$. To find $v(x,y)$, we solve the system $v_x = -u_y$, $v_y = u_x$. Since
$$v_x = -u_y = 12x^2 - 12y^2 + 16y,$$
integration with respect to $x$ yields
$$v(x,y) = 4x^3 - 12xy^2 + 16xy + C(y) \tag{**}$$
where $C(y)$ is a function of $y$. Differentiating $(**)$ with respect to $y$ yields
$$v_y = - 24xy + 16x + C'(y).$$
Since $u_x = -24xy + 16x$ and $u_x = v_y$, we deduce $C'(y) = 0$. Hence $C(y) = A$ for some constant $A$. Setting $A = 0$, we obtain the solution
$$v(x,y) = 4x^3 - 12xy^2 + 16xy.$$