Beginner: Want to graph this formula as a 3d shape

조회 수: 1 (최근 30일)
A
A 2013년 12월 11일
댓글: Image Analyst 2013년 12월 11일
Hi,
I'm interested in graphing a formula similar to the one below in matlab as a shape. Is this at all possible?
x = [1/(y - z - 0.01)] - {1/[(1/(C+D))-((z + 1)/1000)]}
Assume that variables C and D are constants that require user input.
Thanks

답변 (2개)

Image Analyst
Image Analyst 2013년 12월 11일
You can plot this as a surface doing something like this:
C = 2;
D = 5;
z = -5:5;
y = -5:10;
[yy, zz] = meshgrid(y, z);
x = 1 ./ (yy - zz - 0.01) - 1 ./ (1/(C+D)-(zz + 1)/1000);
surf(x);
Be sure to check the parentheses that I used -- I had to guess at what you meant because yours were messed up.
  댓글 수: 1
Image Analyst
Image Analyst 2013년 12월 11일
A, it depends on what they mean. A video is 4D data: x, y, color channel, and time. It can be viewed as a movie. 4D data volumetric data can be viewed as a transparent/translucent volume (with more sophisticated software than MATLAB) If you get to 5D data and higher, you'd probably need to reduce it down to 4D or lower.
Please mask as Accepted if I answered your question.

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


A
A 2013년 12월 11일
Thanks! That worked.
Just a simple question. Is it theoretically impossible to graph a shape which has more than 3 variables? If it has...
a = -5 to 5; b = -5 to 5; c = -5 to 5; d = -5 to 5;
etc..?

카테고리

Help CenterFile Exchange에서 2-D and 3-D Plots에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by