Design of grid-connected directly driven wave power generation system with optimal control of output power