Separate non essential methods from goertzel.js and add utility methods.