meshgrid and streamline
5 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
hello, I have a velocity field u,v,w, where size(u)=size(v)=size(w)=[length(z),length(y),length(z)]. I want to plot streamlines in a horizontal plane so i create the mesh [Y,Z,X]=meshgrid(y,z,x); and I obtain meshgrids with the correct dimensions e.g size(X)=size(u) but when I try to plot with streamslice: streamslice(X,Y,Z,u,v,w,[],[],0.2) where 0.2 is the z-coordinate of the horizontal plane I get this error:
??? Error using ==> interp3 at 138 X, Y and Z must be matrices produced by MESHGRID. Use TriScatteredInterp instead of INTERP3 for scattered data.
Error in ==> streamslice at 147 vi = interp3(x,y,z,v,xi,yi,zi,method);
May you tell me where I am wrong? Thank you very much alberto
0 comentarios
Respuestas (0)
Ver también
Categorías
Más información sobre Surface and Mesh Plots en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!