Superlinearly Convergent Algorithms for Solving Singular Equations and Smooth Reformulations of Complementarity Problems