Tweeked sine wave generation