How can I plot this graph in matlab?
I have trouble plotting this one

댓글 수: 4

Sriram Tadavarty
Sriram Tadavarty 2020년 3월 19일
May i know what did you try to achieve this?
Saad Rana
Saad Rana 2020년 3월 19일
i'm new to matlab and I was just trying to plot this
Saad Rana
Saad Rana 2020년 3월 19일
actually I have to convolve these two signals but I couldn't draw either of these signals
Sriram Tadavarty
Sriram Tadavarty 2020년 3월 19일
Saad, i suggest you to go through MATLAB onramp course here https://www.mathworks.com/learn/tutorials/matlab-onramp.html
To solve this particular problem, you could go through the links of plot, conv functions. Once try with the links and they will help.

댓글을 달려면 로그인하십시오.

 채택된 답변

Star Strider
Star Strider 2020년 3월 19일

0 개 추천

Try this:
x = linspace(-1, 3);
y = 2*((x >= 0) & (x < 1)) + 1*((x >= 1) & (x < 2));
figure
stairs(x, y)
grid
axis([-1 3 -1 3])

추가 답변 (1개)

Steven Lord
Steven Lord 2020년 3월 19일

0 개 추천

If you're trying to create a plot that has a particular appearance but you're not sure which function can create such a plot, open the Plots tab on the Toolstrip. This includes a gallery where you can look at small thumbnails and see which function was used to create each. Find a plot that looks similar to what you want and look for help or doc on the function whose name appears below the thumbnail.
If you select the data you want to plot in the Workspace window, you can even filter that list to those functions that are appropriate for the selected data.

카테고리

도움말 센터File Exchange에서 2-D and 3-D Plots에 대해 자세히 알아보기

제품

태그

질문:

2020년 3월 19일

답변:

2020년 3월 19일

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by