The structure of Frobenius algebras and separable algebras