Energy generation through waves