Generalized solution to the anisotropic Mandel's problem