I have a function of 2 variables, x and y, and have been asked to plot it in 2D along the line y = x. I've checked the documentation for the plot command but couldn't find any relevant information.

 채택된 답변

Walter Roberson
Walter Roberson 2014년 1월 3일

0 개 추천

t = linspace(-3, 17, 500); %arbitrary bounds and number of points
plot3(t, t, f(t, t));

댓글 수: 2

Image Analyst
Image Analyst 2014년 1월 3일
But won't you need to turn your "camera" or viewpoint so that you're looking at a 45 degree angle so that you're looking normal to the vertical y=x plane and not from some arbitrary point in space?
Walter Roberson
Walter Roberson 2014년 1월 3일
The problem statement doesn't require it. You can add a view() command if you want. Or you could work with the various Camera* axes properties; see http://www.mathworks.com/help/matlab/ref/axes_props.html#CameraPosition

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

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Annotations에 대해 자세히 알아보기

질문:

2014년 1월 3일

댓글:

2014년 1월 3일

Community Treasure Hunt

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

Start Hunting!

Translated by