size of surfnorm vectors
1 view (last 30 days)
Show older comments
lorenzo donadio
on 6 Nov 2016
Commented: lorenzo donadio
on 8 Nov 2016
how can I introduce a max length to the vectors plotted by surfnorm or at least scale them?, I cant finde the rigth documentation to do it, thanks.
3 Comments
Walter Roberson
on 7 Nov 2016
The vectors produced by surfnorm are not normalized. That is, they are not unit vectors, do not generally have length 1.
Accepted Answer
Walter Roberson
on 7 Nov 2016
With normalizing:
[nx, ny, nz] = surfnorm(x, y, z);
L = sqrt(nx.^2 + ny.^2 + nz.^2);
quiver3( x, y, z, nx./L, ny./L, nz./L )
More Answers (0)
See Also
Categories
Find more on Vector Fields in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!