# What expression can I use in matlab to remove the negative component of a sine wave so it can look like the picture below?

The image shows a sine wave is obtained using MATLAB. I would like to know what they possibly multiplied or what expression could one use in MATLABto get this wave instead of a complete sine wave.

• Request @Signal to mark an answer as accepted if they are satisfied with their application, to help any future readers – Shreyas Apr 24 at 10:45
• @Shreyas It's customary to wait at least 24 hours after the question has been asked before accepting an answer. – pipe Apr 24 at 12:15

t = -4*pi:.01:4*pi;