An operative method to obtain necessary and sufficient stability conditions for double diffusive convection in porous media