Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations SSS148 on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

bounding sphere

Status
Not open for further replies.

dgowans

Mechanical
Oct 12, 2004
680
I know the topic of finding a bounding box for a part has been discussed and I have found a macro which will do that relative to X, Y, and Z.

Is there a way to find a bounding sphere for a part? I'm trying to determine the smallest sphere which my part will fit into, regardless of orientation. This will be used to try to determine the packaging (several parts into an existing carton).

Thanks,
Dave Gowans
 
Replies continue below

Recommended for you

Any idea on how I might determine the size / position of the spherical envelope? Off the top of my head, this seems like an exercise in trial and error.

Dave Gowans
 
From the help:

You can create an assembly envelope using an existing part file or in the context of the assembly.

To create an assembly envelope from a file:

Click Insert, Envelope, From File.

In the Open dialog box, select the part file to use as an envelope, then click Open.

Click in the assembly window where you want to place the envelope component. You can mate the envelope component to the other components in the assembly to position it precisely.

To create an assembly envelope in the assembly context:

Click Insert, Envelope, New.

In the Save As dialog box, enter a name for the new envelope component, then click Save.

A part document with this name is created.

Click a face or plane in the assembly window where you want to begin sketching the envelope component.

The Front plane of the new envelope component is mated to the selected face or plane with an Inplace mating relation.

Create the base feature and any additional features of the envelope component.

You can reference the geometry of the assembly components as you create the envelope component. If any of the referenced entities changes, the envelope updates accordingly.

When you are done defining the new envelope component, right-click anywhere in the graphics area, and select Edit Assembly:assembly_name.


Regards,

Scott Baugh, CSWP [pc2]
3DVision Technologies

faq731-376
 
I understand how I would go about creating an envelope, but I have no idea how to confirm that I have created the smallest envelope possible - hence my feeling that this would be a lot of trial and error trying to figure out not only the size of the sphere, but it's position.

I've done an internet search on bounding sphere - seems that this is a technique game developers and the like use to do collision detection. Based on what I've read and the little I know about the rendering process, I believe there are mathematical algorithms that will take a set of point data and generate the smallest bounding sphere. I'm wondering if it's possible within Solidworks (custom macro, anyone?) to do the same.
 
That's why you would have to either in-context the bouding sphere to the components or not.

There will be some guessing I suppose, but if you mated the sketch to the 3 of the outer parts then you would have some idea. If the sphere is to big, change the mate to another part and so on until you get the desired result.

The above clipping from the Help explains this process. If you are looking for something more automated, there isn't anything nativly in SW that does this for you. You will have to write something or find a macro someone has already written.

Regards,

Scott Baugh, CSWP [pc2]
3DVision Technologies

faq731-376
 
I was thinking that there must be a way to have a macro scan and measure the distance of a vertex from the centroid. After it found the three longest distances it could then develop the sphere that you require.

Not that I am bright enough to figure it out, but I'm sure someone else could accomplish this execise.

Just my two cent, Canadian, which after exchange, well 'nough said.

Regards,

Christopher Zona - Senior CAD Designer
Litens Automotive Partnership
Concord, Ontario, Canada
 
Hmm...interesting... No idea how to help, but I think the solution must incorporate a Jacobian somehow......

(I'm just trying to sound smart...I've forgotten 99% of my Advanced Calculus)
 
You would have to find the 3 or less outer points of the parts then make circle sketch in-contexted to them, then make your sphere. Sounds easy enough, but I know it's not. So I would make the part (Sphere) as a part and place where you want to center to be at, or if that's not important, then in-context the sketch to the parts as needed to finish making your Bounding sphere.

Regards,

Scott Baugh, CSWP [pc2]
3DVision Technologies

faq731-376
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor