The space between the plates of a parallel-plate capacitor

The space between the plates of a parallel-plate capacitor is filled with dielectric material whose dielectric constant varies linearly fom 1 at the bottom plate (x=0) to 2 at the top plate (x=d). The capacitor is connected to a battery of voltage V.

Find all the bound charge, and check that the total is zero.