Amplitude and phase added
Periods can now be changed