Newsgroups: sci.engr.advanced-tv,sci.image.processing,comp.graphics.algorithms,comp.graphics,comp.lang.postscript
Path: cantaloupe.srv.cs.cmu.edu!das-news2.harvard.edu!news2.near.net!news.mathworks.com!news.kei.com!simtel!harbinger.cc.monash.edu.au!news.cs.su.oz.au!inferno.mpx.com.au!metro!extro!maxtal
From: maxtal@extro.ucc.su.OZ.AU (Tim TAL Lister)
Subject: Re: Best fit sphere to cloud of points
Message-ID: <D9BE8K.8Iz@ucc.su.OZ.AU>
Sender: news@ucc.su.OZ.AU
Nntp-Posting-Host: extro.ucc.su.oz.au
Organization: MAXTAL P/L C/- University Computing Centre, Sydney
References: <Poynton-1705951718580001@ts2-03.inforamp.net> <D93Kpv.4LD@wti.com> <3q2f82$fqh@trochlea.cs.unc.edu>
Date: Mon, 29 May 1995 00:48:18 GMT
Lines: 52
Xref: glinda.oz.cs.cmu.edu sci.engr.advanced-tv:3016 sci.image.processing:15027 comp.graphics.algorithms:17519 comp.graphics:77802 comp.lang.postscript:33206

In article <3q2f82$fqh@trochlea.cs.unc.edu> eberly@cs.unc.edu (David Eberly) writes:
>In article <D93Kpv.4LD@wti.com>, Jon Barber <jasper@wti.com> wrote:
>>Given a cloud of points, I want to know if 
>>those points are on a (fuzzy) sphere, and
>>if so, where the center of the sphere is.
>>
>>I say fuzzy because some tolerance off the
>>sphere is acceptable.
>>
>>Any ideas/pointers?
>
>The following might be sufficient to meet your goals.
>  (1)  Build a bounding box for the points,
>         [xmin,xmax]x[ymin,ymax]x[zmin,zmax]
>  (2)  Discretize the box as [0,P-1]x[0,Q-1]x[0,R-1] where P, Q, R, are
>       integers.  You now have a 3D raster and a map from (x,y,z) in the
>       bounding box to (i,j,k) in the 3D raster.
>  (3)  Select a sequence of radii, 0 < r1 < r2 < ... < rN, and an
>       associated sequence of radii difference, 0 < dr1 < dr2 < ... < drN.
>  (4)  For each (i,j,k) and for each pair (r,dr), count how many points
>       from your cloud lie in the annulus whose center is (x,y,z),
>       whose radius is r, and whose thickness is dr.  Let this counting
>       function be denoted C(x,y,z,r).
>  (5)  The fuzzy sphere is the one whose center is (x,y,z), whose radius
>       is r, and whose thickness is dr, where C(x,y,z,r) attains its
>       absolute maximum.
>
>Dave Eberly
>eberly@cs.unc.edu
  Nice idea.  You could use other tricks, too, like:
  (5a)  as (5) above
  (5b)  The fuzzy sphere is the one whose centre is (x,y,z), whose radius
        is r, and whose thickness is dr, where C(x,y,z) attains its
	most typical value.
  (5c)  ditto, for "most overage value".
  Hmmm, seems there could be more than one sphere meeting any condition,
given the right distribution of points.  Perhaps this is the very point of
a Fuzzy Sphere, and you could specify an average (typical, etc.,) centre
with two radii for an inner and an outer bounding sphere respectively.
  Strange point distributions might specify interesting surfaces (not just
spheres) for the bounding surfaces.  Incomplete surfaces would be some of
the special cases.  The density of points in such bounded regions would be
of some interest, as it need not be linear.

	regards,
		tal

-- 
;----------------------------------------------------------------------
        TIM (TAL) LISTER,         maxtal@extro.ucc.su.oz.au
	Maxtal Pty Ltd, 81a Glebe Pt.Rd, Glebe, NSW 2037, AUSTRALIA
;------ Graphics & C++ libraries, Games & Image Processing ------------
