graphics - Matlab's Quiver3 plots only 4 vectors -


i want use command quiver3(x,y,z,m,n,o) in order vector field, matrices 10x10x10 arrays real entries. wanted plot , got 4 vectors instead of expected 1000. here know, possibly have done wrong? if need further information, available comments.

assuming problem occurs when attempting display data (rather attempting display unallowed numerical values such inf or nan), think problem range of norms of vectors, such 4 show up.

the importance of norm of vectors relative range of coordinate system important, illustrated following example:

here 10 random vectors show up:

na = 10; [x y z m n o] = deal(rand(na,1),rand(na,1),rand(na,1),rand(na,1),rand(na,1),rand(na,1));  quiver3(x,y,z,m,n,o) 

enter image description here

but if of vectors made 100 x bigger, smaller ones show up:

mul = 1e+3; [x y z m n o] = deal(rand(na,1),rand(na,1),rand(na,1),...     [mul*rand(na/2,1);rand(na/2,1)],...     [mul*rand(na/2,1);rand(na/2,1)],...     [mul*rand(na/2,1);rand(na/2,1)]); quiver3(x,y,z,m,n,o) 

enter image description here

similarly if of vectors made small don't show up:

mul = 1e-3; [x y z m n o] = deal(rand(na,1),rand(na,1),rand(na,1),...     [mul*rand(na/2,1);rand(na/2,1)],...     [mul*rand(na/2,1);rand(na/2,1)],...     [mul*rand(na/2,1);rand(na/2,1)]); quiver3(x,y,z,m,n,o) 

enter image description here

vectors large or small relative axis not displayed @ all.

if problem scaling may want inspect function , see how narrow range of x,y,z vectors have narrower range of values, or change scale (logarithm?) data can displayed in 1 figure.

edit

as alternative question of how display data, may want consider using isosurfaces. here's example, each red sphere representing different isosurface in spherical potential:

enter image description here


Comments

Popular posts from this blog

image - ClassNotFoundException when add a prebuilt apk into system.img in android -

I need to import mysql 5.1 to 5.5? -

Java, Hibernate, MySQL - store UTC date-time -