Let $B$ be the unit ball,
$ B:= \left\lbrace (x,y)\in \mathbb{R^2} :x^2+y^2<1 \right\rbrace.$
I want to find a $u:B\to\mathbb R$ that satisfies the following conditions:
$\Delta u(x,y)=x^4+x^2+2x^2y^2+y^2+y^4 $, for $(x,y) \in B$
$u(x,y)=2xy$, for $(x,y) \in \partial B$
The inhomogeneity in the first condition is confusing me. Can someone please provide an explanation of how to solve this problem?
Because this equation is inhomogeneous, we would call it "Poisson's equation", not "Laplace's equation".
Given the geometry of the setup, I would suggest you work in polar coordinates, $(x, y) = (r\cos\phi, r\sin\phi)$. Switching to polar coordinates, the task is to find a $u(r, \phi)$ that satisfies the PDE $$ \frac{1}{r}\frac{\partial}{\partial r}\left(r \frac{\partial u}{\partial r} \right) + \frac{1}{r^2}\frac{\partial^2u}{\partial \phi^2} = r^2 + r^4 \qquad \qquad (\text{for } r < 1),$$ subject to the boundary condition $$ u = \sin 2\phi \qquad \qquad (\text{for } r = 1).$$
To find the general solution to our PDE, we can use the following facts.
Fact 1: The general solution to the homogeneous equation $\frac{1}{r}\frac{\partial}{\partial r}\left(r \frac{\partial u}{\partial r} \right) + \frac{\partial^2u}{\partial \phi^2} = 0$ is $$ u = a_0 + \sum_{n = 1}^\infty \left( a_n \cos(n\phi) + b_n \sin(n\phi)\right)r^n. $$ You can derive this solution using separation of variables. You'll almost certainly be able to find the derivation in your notes or textbook.
Fact 2: The function $$ u = \tfrac{1}{16}r^4 + \tfrac{1}{36}r^6$$ is one particular solution to the full inhomogeneous equation $\frac{1}{r}\frac{\partial}{\partial r}\left(r \frac{\partial u}{\partial r} \right) + \frac{\partial^2u}{\partial \phi^2} = r^2 + r^4$. You can obtain this solution by inspection, and you can verify that it works by substituting it into the PDE.
Combining these two facts, we see that $$ u = a_0 + \sum_{n = 1}^\infty \left( a_n \cos(n\phi) + b_n \sin(n\phi)\right)r^n + \tfrac{1}{16}r^4 + \tfrac{1}{36}r^6$$ is the general solution to our full inhomogeneous PDE.
It remains to apply our boundary condition to determine the coefficients $a_n$ and $b_n$. If you work through this, you should be able to show that $$ a_0 = - \tfrac 1 {16} - \tfrac 1 {36}, \qquad b_2 = 1, $$ and that all the other $a_n$'s and $b_n$'s are zero.