Pseudospin symmetry solution of the Dirac equation with an angle-dependent potential