Cleaner code (Arrays)

Using arrays and looping through them instead of repeating math in
several places. This makes it easier in case I change my mind about
master pitch, pitch wheel lag, portamento time, etc.