color a portion of a sphere surface

조회 수: 3 (최근 30일)
lmac456
lmac456 2017년 9월 13일
댓글: Andy 2022년 8월 31일
How would I color just the portion of the surface of the sphere below connected by the 4 black dots? The fill3 or patch function do not work because the surface is curved and not flat.
  댓글 수: 1
Andy
Andy 2022년 8월 31일
lmac456: May I ask to see the code that you used to generate your plot? I'm trying to do something similar, but with hexagonal sections.

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

답변 (1개)

Walter Roberson
Walter Roberson 2017년 9월 13일
편집: Walter Roberson 2017년 9월 13일
Each face of the sphere is locally flat for drawing purposes. If that is too "rough" then you would need to create additional faces that subdivide to get a finer approximation to curvature.
  댓글 수: 2
lmac456
lmac456 2017년 9월 13일
편집: lmac456 2017년 9월 13일
I keep running into this same problem using the patch function even with setting FaceColor to flat (attached image). Is this what you mean by the face possibly being too "rough"?
Walter Roberson
Walter Roberson 2017년 9월 14일
Can you attach the data file for the shape?

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

카테고리

Help CenterFile Exchange에서 Surface and Mesh Plots에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by