added calculating values for sinusoidal graph