Skip to content

Algo for vectorScale does poorly on irregular grids #11

Open
@etpinard

Description

@etpinard

See example in https://github.com/gl-vis/gl-cone3d/compare/irregular-grid-cone-size

On x/y/z and u/v/w data generated by (python code from https://plot.ly/~empet/14868/sizemode-and-sizeref-for-cone-trac/#/)

from scipy.integrate import odeint

def eq_vf(pos, t):
    x, y, z = pos 
    return  -y-z, x+0.2*y, 0.2+z*(x-5.7)

def Rossler_vf(x, y, z):
    return  -y-z, x+0.2*y, 0.2+z*(x-5.7)

pos0 = (0.6, 1, .0)
t = np.arange(0.0, 75, 0.025) 
pos = odeint(eq_vf, pos0, t)

I = [8*k for k in range(pos.shape[0]//8)]
newpos = pos[I,:]

x, y, z = newpos.T
u, v, w = Rossler_vf(x,y,z)

We get a maxNorm of ~64 and a minSeparation of ~0.26 making for a very small vectorScale and pretty much invisible small cones.


With this data, the field-wide maxNorm and minSeparation do a poor job of defining the spacing in-between each cone. Perhaps we should come up with a more "local" algorithm. One thing is sure, cones should be visible by default (w/o having to set coneSize) regardless of the input positions and vectors.

cc @kig @alexcjohnson who may have ideas about this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions