How to plot multiple unit tangent vector along a 3D curve using quiver3

Hi,
I am to sketch the curve r(t) = <t,t^2,t^3> t E [0,2] and the unit tangent vector at several locations along the curve.
Can anyone help?
This is what I got to plot the curve, and I can't seem to figure out how to use quiver 3. Thanks!!
t = linspace(0, 2, 80);
x1 = t;
y1 = t.^2;
z1 = t.^3;
TangentUni= 1/sqrt(1+4t.^2+9t.^4), 2*t/sqrt(1+4t.^2+9t.^4), 3*t.^2/sqrt(1+4t.^2+9t.^4)
figure
plot3(x1,y1,z1,"m", "LineWidth",2)

 Accepted Answer

t = linspace(0, 2, 80);
x1 = t;
y1 = t.^2;
z1 = t.^3;
TangentUni = 1./sqrt(1+4*t.^2+9*t.^4), 2*t./sqrt(1+4*t.^2+9*t.^4), 3*t.^2./sqrt(1+4*t.^2+9*t.^4)
figure
quiver(x1,y1,TangentUni,z1)

More Answers (0)

Categories

Tags

Asked:

on 29 Oct 2020

Edited:

on 21 Nov 2020

Community Treasure Hunt

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

Start Hunting!