How to plot a velocity field

19 visualizzazioni (ultimi 30 giorni)
Andres Benoit
Andres Benoit il 21 Dic 2020
Modificato: Andres Benoit il 21 Dic 2020
I want to plot a velocity field defined in polar coodinates as Vr = -10/r and Vt=10/r (radial and tangent coordinates, respectively), but im having some troubles, below the code that i made.
x = -4:0.3:4;
y = x;
[X, Y] = meshgrid(x,y);
Vr = -10./sqrt(X.^2 + Y.^2);
Vt = 10./sqrt(X.^2 + Y.^2);
quiver(x, y, Vr,Vt)
How can i plot it correctly?

Risposte (0)

Categorie

Scopri di più su Vector Fields in Help Center e File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by