From: Ben on
I realize this isn't a technical question per se, but I think that
some of you may have some insight into this type of problem.

I have a set of x,y,z arbitrarily scattered points/particles that I
would like to collapse into a sphere containing the same number of
particles, all are on the same 3-D grid with no overlapping
particles. For example, the grid has a 1.0 spacing in x, y, z
directions, some of the grid points are initially occupied with
particles in the domain (51x51x51), most points are not.

I would like to "walk" or move the particles toward the center of the
domain (defined as 0,0,0), but need to do it in (at least) 10 steps so
I can do some analysis on the intermediate steps. "Teleporting" is
fine, it doesn't have to random walk.... just as long as the general
progress is "collapsing" in some fashion.

One idea is a 3-D random walk, avoiding occupied sites, proceeding
generally inward. If I loop over all points and let it make a step
each time, then eventually it will collapse, but may take a longer
time as it gets closer to a spherical shape. The other idea I had
was to simply teleport along a straight line toward the center, each
iteration would check for open spots nearby and occupy them. It
should fill sphere shape faster.

I guess this is essentially "volumetric morphing" .. . any thoughts
about relatively efficient / novel methods for doing this?

Thanks,
-Ben


From: John D'Errico on
Ben <jbenjam(a)gmail.com> wrote in message <0b53be5b-dc84-441b-
80bb-4cd283fa67fe(a)26g2000hsk.googlegroups.com>...
> I realize this isn't a technical question per se, but I think that
> some of you may have some insight into this type of problem.
>
> I have a set of x,y,z arbitrarily scattered points/particles that I
> would like to collapse into a sphere containing the same number of
> particles, all are on the same 3-D grid with no overlapping
> particles. For example, the grid has a 1.0 spacing in x, y, z
> directions, some of the grid points are initially occupied with
> particles in the domain (51x51x51), most points are not.
>
> I would like to "walk" or move the particles toward the center of the
> domain (defined as 0,0,0), but need to do it in (at least) 10 steps so
> I can do some analysis on the intermediate steps. "Teleporting" is
> fine, it doesn't have to random walk.... just as long as the general
> progress is "collapsing" in some fashion.
>
> One idea is a 3-D random walk, avoiding occupied sites, proceeding
> generally inward. If I loop over all points and let it make a step
> each time, then eventually it will collapse, but may take a longer
> time as it gets closer to a spherical shape. The other idea I had
> was to simply teleport along a straight line toward the center, each
> iteration would check for open spots nearby and occupy them. It
> should fill sphere shape faster.
>
> I guess this is essentially "volumetric morphing" .. . any thoughts
> about relatively efficient / novel methods for doing this?

Sorry, but I need a better description of
your goal here.

You have a list of points in 3-d, that you
wish to move onto the surface of a unit
sphere?

Assuming that your points will move along
a linear path towards the origin, whats the
problem?

% pick a random set of points in a cube.
xyz0 = (rand(100,3)-.5)*50;

% the distance for each point from the origin
D = sqrt(sum(xyz0.^2,2));

% their final location on the surface of
% a unit sphere
xyzfinal = xyz0.*repmat(1./D,1,3);

% You apparently want the points to
% move slowly from xyz0 to xyzfinal
% Here we will do so in 11 linear steps
plot3(xyz0(:,1),xyz0(:,2),xyz0(:,3),'ro')
hold on
for t = 0.1:.1:0.9
xyzt = xyz0*(1-t) + xyzfinal*t;
plot3(xyzt(:,1),xyzt(:,2),xyzt(:,3),'g.')
end
plot3(xyzfinal(:,1), xyzfinal(:,2), xyzfinal(:,3),'bo')
hold off
box on
grid on

I honestly don't know if this is what you
are trying to do.

John