how to get data(u,v,w) corresponding to spicific x ,y ,z in 3D quiver in matlab?
3 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
S.Mostafa BaniHashemian
am 2 Jan. 2024
Kommentiert: S.Mostafa BaniHashemian
am 3 Jan. 2024
hello.
I want to extract data(including: u,v,w) corresponding to spicific x ,y ,z (or specific coordinate) in a 3D quiver graph.
(this is a "matlab function" with quiver3 in simulink, and i want to give specific & unique x,y,z position to "matlab function" and extract corresponding data of u,v,w from it).
Can I also use the "ind2sub" and or "u=interp3(x,y,z)" command in "matlab function"?(How can I use it?)
Can anyone guide me?
0 Kommentare
Akzeptierte Antwort
Sulaymon Eshkabilov
am 2 Jan. 2024
if the quiver3() plot figure is obtained/saved, the data can be extracted, e.g.,
fig = openfig('Q3.fig');
fig = gcf;
axObjs = fig.Children;
dataObjs = axObjs.Children;
x = dataObjs(1).XData;
y = dataObjs(1).YData;
z = dataObjs(1).ZData;
[U,V,W] = surfnorm(x,y,z);
quiver3(x, y, z, U,V,W,0)
axis equal
shg
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Vector Fields finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!