How do I take diagonal Slices?

23 views (last 30 days)
Morgan Brown
Morgan Brown on 8 Jun 2020
Answered: darova on 12 Jun 2020
How do I produce slices through the volume? I know you can make slices that are orthogonal to the axes but how do I take slices that are not orthogonal? For example, how do I take a diagonal slice?

Answers (1)

darova
darova on 12 Jun 2020
just create a surface you want to get slice on
[x,y,z,v] = flow;
[x1,y1] = meshgrid(0:10,-3:0.5:3);
z1 = (x1 + y1)/2-2;
slice(x,y,z,v,x1,y1,z1)
hold on
slice(x,y,z,v,[2 7],[],[])
slice(x,y,z,v,[],0,[])
hold off
axis vis3d

Tags

Community Treasure Hunt

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

Start Hunting!