MATLAB Answers

YT
0

curl with symbolic vector

Asked by YT
on 31 Oct 2019
Latest activity Edited by KALYAN ACHARJYA on 31 Oct 2019
I'm trying to do use curl with a symbolic vector, but it just keeps on returing a zero vector.
% ∇ × F
syms Fx Fy Fz x y z
curl( [Fx, Fy, Fz], [x, y, z] );
> [ 0; 0; 0 ]
According to this accepted answer it should work just fine, so why isn't it?

  0 Comments

Sign in to comment.

Products


Release

R2018b

1 Answer

Answer by KALYAN ACHARJYA on 31 Oct 2019
Edited by KALYAN ACHARJYA on 31 Oct 2019
 Accepted Answer

The answer defined in this way:
syms Fx(x,y,z) Fy(x,y,z) Fz(x,y,z)
curl([Fx Fy,Fz],[x, y, z])
Result:
ans(x, y, z) =
diff(Fz(x, y, z), y) - diff(Fy(x, y, z), z)
diff(Fx(x, y, z), z) - diff(Fz(x, y, z), x)
diff(Fy(x, y, z), x) - diff(Fx(x, y, z), y)

  1 Comment

YT
on 31 Oct 2019
Easy fix, thanks!

Sign in to comment.