# Matlab optimized slice plot

3 vues (au cours des 30 derniers jours)
Steffen B. le 8 Mar 2024
Commenté : Avni Agrawal le 3 Avr 2024
Hello,
I have a question regarding the slice plot in matlab.
I solve the temperature field in a cube domain, depending on convective and or temperature boundary conditions. So far no problem, but the result plot is not really nice. When I use the slice function I get this:
But I want a plot like this:
With this shape:
A Cube with a cut out quarter, to present the temperature change over time.
Is it even possible to create such a plot, or is another plot function a better choice?
In addition, a small second question. Can I plot only the temperature isolines on the surfaces?
The slice related code I used is following:
f2 = figure(2);
movegui(f2,[1200 100]);
fontSize=20;
fontSize2=16;
f2.Position(3:4) = [1080 780];
% 3D
h=slice(x,y,z,T,[0 L/2],[H],[B/2 B],'cubic');
set(gca,'FontSize',fontSize)
set(gca,'YDir','normal')
colormap(jet)
brighten(jet,.5)
set(h,'edgecolor','black','facealpha',1,'linewidth',1)
xlabel('x-Direction x/ m','FontSize', fontSize)
ylabel('z-Direction z/ m','FontSize', fontSize)
zlabel('y-Direction y/ m','FontSize', fontSize)
axis([0 B 0 L 0 H])
view(30,30)
rotate(h,[1,0,0],-90);
hold on
cb=colorbar("northoutside");
set(cb,'FontSize',fontSize);
caxis([70, 300]);
##### 1 commentaireAfficher -1 commentaires plus anciensMasquer -1 commentaires plus anciens
Avni Agrawal le 3 Avr 2024
Hi @Steffen B., can you share values for x,y,z,T, L, H, B?

Connectez-vous pour commenter.

### Catégories

En savoir plus sur Animation dans Help Center et File Exchange

R2016b

### Community Treasure Hunt

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

Start Hunting!

Translated by