Table Lookup Oscillator in Python