Solve for z -p*(51+z)=dz+84