how plot results of a 3d matrix

2 次查看(过去 30 天)
Hi, I've a meshgrid
[X,Y,Z] = meshgrid(0:250:1000,0:250:1000,0:250:1000)
and I computed in each node a value of temperature. I've a 5x5x5 matrix named T_geotherm:
val(:,:,1) =
18.0000 18.0000 18.0000 18.0000 18.0000
18.0000 18.0000 18.0000 18.0000 18.0000
18.0000 18.0000 18.5000 18.5000 18.5000
18.0000 18.0000 18.5000 18.5000 19.0000
18.0000 19.0000 20.0000 20.0000 20.0000
val(:,:,2) =
33.2356 33.2356 34.0689 34.0689 34.6245
33.2356 33.2356 34.0689 34.6245 34.6245
33.2356 34.0689 34.5689 35.1245 35.1245
33.2356 34.0689 35.1245 35.1245 35.6245
33.2356 35.0689 36.6245 37.1800 37.1800
val(:,:,3) =
48.3670 48.3670 50.0337 50.0337 51.1448
48.3670 48.3670 50.0337 51.1448 51.1448
48.3670 50.0337 50.5337 51.6448 51.6448
48.3670 50.0337 51.6448 51.6448 52.1448
48.3670 51.0337 53.1448 54.2559 54.2559
val(:,:,4) =
63.3943 63.3943 65.8943 65.8943 67.5609
63.3943 63.3943 65.8943 67.5609 67.5609
63.3943 65.8943 66.3943 68.0609 68.0609
63.3943 65.8943 68.0609 68.0609 68.5609
63.3943 66.8943 69.5609 71.2276 71.2276
val(:,:,5) =
68.7427 68.7427 71.5427 71.5427 73.4094
68.7427 68.7427 71.5427 73.4094 73.4094
68.7427 71.5427 72.0427 73.9094 73.9094
68.7427 71.5427 73.9094 73.9094 74.4094
68.7427 72.5427 75.4094 77.2760 77.2760
How can I display the results on a plot? For example several slices at different depths or display an isosurface of 60°C?
Thanks for the help
Gianluca
  2 个评论
Jan
Jan 2012-7-5
编辑:Jan 2012-7-5
Please post, what you have tried so far and which problems occurred. Is there any chance that we can identify what "60°C" has to do with your data?
gianluca
gianluca 2012-7-5
Hi Jan, My data are underground temperatures computed at selected depth. I solved the problem regarding how to display the trend of a selected temperature (i.e. 60°C) through an isosurface in this manner:
p = patch(isosurface(X,Y,Z,T_geotherm,60));
isonormals(X,Y,Z,T_geotherm,p);
set(p,'FaceColor','b','EdgeColor','k','FaceAlpha',0.1,'EdgeColor','none');
I would also plot the temperatures at selected depth (i.e. 200, 400, 600 meters). The commands plot3d or contour don't work. Any suggestions?

请先登录,再进行评论。

采纳的回答

Teja Muppirala
Teja Muppirala 2012-7-5
These two commands shoulds be useful:
help isosurface
help slice

更多回答(0 个)

产品

Community Treasure Hunt

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

Start Hunting!

Translated by