Plotting a surface with defined unit sizes (meter, mm, inch)

Hi, I want to make sure how can I have a 3D surface in meter or 'mm' units. For example, for a sinusoidal surface with 'x' and 'y' in 'mm' units, how can I define the amplitude of the surface (which is in 'z' axis) in 'mm'? I know how to define the size on 'x' and 'y' with meshgrid but what about the size on 'z' axis (which is a constant amplitude). Units are very important in this case. I appreciate your comments.

 채택된 답변

Walter Roberson
Walter Roberson 2015년 9월 20일

0 개 추천

Is it the case that the plot must be labeled with particular units, or is it the case that the plot must render on the screen a particular physical size because you need people to be able to literally put a ruler to the screen to measure distances? And is the question how to make the Z axis measurable by placing a ruler on the screen?
If the question is how to make Z measurable on the screen, then you need to choose your viewing angle and projection matrix very carefully, and the user has to do some interpretation to figure out which of the infinite number of x, y, z coordinates that project to the same screen x y point is being referred to.
But if the point is to make that kind of measurement, then why not just let the user click on the points and have the computer tell the result?

댓글 수: 1

Make sure you set the axes DataAspect property to control the relative scaling of the Z.

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

추가 답변 (1개)

Star Strider
Star Strider 2015년 9월 20일
편집: Star Strider 2015년 9월 20일

0 개 추천

The units of the z-axis are whatever you calculate them to be. You can define the tick label values using the set function and specifying 'ZTick' quantities and 'ZTickLabel' strings or numeric values. See Chart Surface Properties and Axes Properties for details.

카테고리

질문:

2015년 9월 20일

댓글:

2015년 9월 21일

Community Treasure Hunt

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

Start Hunting!

Translated by