This question was asked in Example 1
Sine graph 
Mahek Shaikh's image