Optimal control study of home energy management with cooperative dispatch of electric vehicles and energy storage devices