Design of inhomogeneous pentamode metamaterials for minimization of scattering