Detecting Self-Intersecting Parts

Detecting Self-Intersecting Parts

MechMachineMan
Advisor Advisor
2,449 Views
6 Replies
Message 1 of 7

Detecting Self-Intersecting Parts

MechMachineMan
Advisor
Advisor

Coming across some old parts designed by other people in the company and they have geometry that is self intersecting.

 

The problem with this is that it causes "Interference Analysis" to fail on an assembly that contains these parts.

 

The part doesn't even show any issues with these parts, so I'm at a loss of how to detect it. 

 

Does anyone have a method that can tell me if the part is self-intersecting?

 

(I'm assuming at this point I might have to use the API to access some object properties, but not even sure how I would do that, so any further help would definitely be appreciated!")

 

Attached is an example of the file, as well as a picture. (see flange joint pointing to the bottom right of the picture)

 

 

Self-Intersecting Flanges.JPG

 

 

 


--------------------------------------
Did you find this reply helpful ? If so please use the 'Accept as Solution' or 'Like' button below.

Justin K
Inventor 2018.2.3, Build 227 | Excel 2013+ VBA
ERP/CAD Communication | Custom Scripting
Machine Design | Process Optimization


iLogic/Inventor API: Autodesk Online Help | API Shortcut In Google Chrome | iLogic API Documentation
Vb.Net/VBA Programming: MSDN | Stackoverflow | Excel Object Model
Inventor API/VBA/Vb.Net Learning Resources: Forum Thread

Sample Solutions:Debugging in iLogic ( and Batch PDF Export Sample ) | API HasSaveCopyAs Issues |
BOM Export & Column Reorder | Reorient Skewed Part | Add Internal Profile Dogbones |
Run iLogic From VBA | Batch File Renaming| Continuous Pick/Rename Objects

Local Help: %PUBLIC%\Documents\Autodesk\Inventor 2018\Local Help

Ideas: Dockable/Customizable Property Browser | Section Line API/Thread Feature in Assembly/PartsList API Static Cells | Fourth BOM Type
0 Likes
2,450 Views
6 Replies
Replies (6)
Message 2 of 7

WHolzwarth
Mentor
Mentor

Issue is located in the old part.

I've made some changes by thicken operations (2017 IPT)

Walter

Walter Holzwarth

EESignature

0 Likes
Message 3 of 7

MechMachineMan
Advisor
Advisor

Thanks for the response Walter.

 

That definitely shows an easier method for fixing the parts than what I was doing before (editing sketch/cutting/re-constraining/extending lines, etc).

 

 

However, what I am actually looking for is some method or some procedure that consistent fails or acts as an identifier for self-intersecting parts so that I can use it in a VBA macro and establish a list of all parts within our file system that are self intersecting.

 

Some things I've tried:

1) Inserting the part and a dummy part in an assembly and running interference analysis

        - This doesn't consistently fail, so cannot be used as a good metric.

2) Checking volume vs mass to see if there are inconsistencies because of the overlapping material

        - Inventor appears to calculate the volume/mass based on the final composite solid, rather than using individual features,

 


--------------------------------------
Did you find this reply helpful ? If so please use the 'Accept as Solution' or 'Like' button below.

Justin K
Inventor 2018.2.3, Build 227 | Excel 2013+ VBA
ERP/CAD Communication | Custom Scripting
Machine Design | Process Optimization


iLogic/Inventor API: Autodesk Online Help | API Shortcut In Google Chrome | iLogic API Documentation
Vb.Net/VBA Programming: MSDN | Stackoverflow | Excel Object Model
Inventor API/VBA/Vb.Net Learning Resources: Forum Thread

Sample Solutions:Debugging in iLogic ( and Batch PDF Export Sample ) | API HasSaveCopyAs Issues |
BOM Export & Column Reorder | Reorient Skewed Part | Add Internal Profile Dogbones |
Run iLogic From VBA | Batch File Renaming| Continuous Pick/Rename Objects

Local Help: %PUBLIC%\Documents\Autodesk\Inventor 2018\Local Help

Ideas: Dockable/Customizable Property Browser | Section Line API/Thread Feature in Assembly/PartsList API Static Cells | Fourth BOM Type
0 Likes
Message 4 of 7

Curtis_Waguespack
Consultant
Consultant

Hi MechMachineMan,

 

I would try one or both of these:

 

  1. Programmatically, delete and re-create the flat pattern in order to raise the error dialog again (might be to heavy handed if there are flat pattern sketches or features).
  2. Use the FlatPattern.FindUsingRay method to find intersections.

 

Never tried either for this purpose, but maybe they'll work for this?

 

I hope this helps.
Best of luck to you in all of your Inventor pursuits,
Curtis
http://inventortrenches.blogspot.com

EESignature

0 Likes
Message 5 of 7

MechMachineMan
Advisor
Advisor

Delete/Recreating Flat pattern doesn't error out the file.

 

FindUsingRay seems interesting. Can't think of how I would necessarily find intersections using it. But it made me think of FindUsingPoint on the folded model, because at a point that is intersecting it should hypothetically shown more than 1 entity for that location. Going to have to try it out!


--------------------------------------
Did you find this reply helpful ? If so please use the 'Accept as Solution' or 'Like' button below.

Justin K
Inventor 2018.2.3, Build 227 | Excel 2013+ VBA
ERP/CAD Communication | Custom Scripting
Machine Design | Process Optimization


iLogic/Inventor API: Autodesk Online Help | API Shortcut In Google Chrome | iLogic API Documentation
Vb.Net/VBA Programming: MSDN | Stackoverflow | Excel Object Model
Inventor API/VBA/Vb.Net Learning Resources: Forum Thread

Sample Solutions:Debugging in iLogic ( and Batch PDF Export Sample ) | API HasSaveCopyAs Issues |
BOM Export & Column Reorder | Reorient Skewed Part | Add Internal Profile Dogbones |
Run iLogic From VBA | Batch File Renaming| Continuous Pick/Rename Objects

Local Help: %PUBLIC%\Documents\Autodesk\Inventor 2018\Local Help

Ideas: Dockable/Customizable Property Browser | Section Line API/Thread Feature in Assembly/PartsList API Static Cells | Fourth BOM Type
0 Likes
Message 6 of 7

Curtis_Waguespack
Consultant
Consultant

@MechMachineMan wrote:

 

FindUsingRay seems interesting. Can't think of how I would necessarily find intersections using it.


Hi MechMachineMan,

 

This is what caught my eye about the FindUsingRay method, but maybe FindUsingPoint might work just as well? I'd be interested in seeing a working example if you get it worked out, but don't feel obligated.

 

I hope this helps.
Best of luck to you in all of your Inventor pursuits,
Curtis
http://inventortrenches.blogspot.com

 

Form the API on the FindUsingRay method:

 

"There is also a precedence in the type of entities returned. The entities returned can be Vertex, Edge, or Face objects. The precedence is in that order. If the ray intersects a vertex, then that vertex is returned and none of the edges or faces that connect to that vertex are returned. If the ray intersects an edge, then that edge is returned and none of the faces that connect to the edge are returned. If the ray intersects a face, then that face is returned. If desired, you can use the functionality provided by the B-Rep portion of the API to obtain the various associated objects from the entity returned. For example if you need a face but an edge is returned, you can use the Faces property of the Edge object to get the associated faces. The start point defines the physical starting point from which to determine intersections. Any intersections behind the start point are ignored. However, the ray is infinite from the start point, so all intersections in the direction of the ray will be returned. "

 

 

EESignature

0 Likes
Message 7 of 7

MechMachineMan
Advisor
Advisor

The only issue i see with the rays if it is a box shape I have created - it then will find both sides of the box.

 

Seems a little more complex seeing as the individual physical features (ie; each flange) is not ever represented as a solid on it's own, but only by the solid of the feature that created it. Makes things tough even using points.


--------------------------------------
Did you find this reply helpful ? If so please use the 'Accept as Solution' or 'Like' button below.

Justin K
Inventor 2018.2.3, Build 227 | Excel 2013+ VBA
ERP/CAD Communication | Custom Scripting
Machine Design | Process Optimization


iLogic/Inventor API: Autodesk Online Help | API Shortcut In Google Chrome | iLogic API Documentation
Vb.Net/VBA Programming: MSDN | Stackoverflow | Excel Object Model
Inventor API/VBA/Vb.Net Learning Resources: Forum Thread

Sample Solutions:Debugging in iLogic ( and Batch PDF Export Sample ) | API HasSaveCopyAs Issues |
BOM Export & Column Reorder | Reorient Skewed Part | Add Internal Profile Dogbones |
Run iLogic From VBA | Batch File Renaming| Continuous Pick/Rename Objects

Local Help: %PUBLIC%\Documents\Autodesk\Inventor 2018\Local Help

Ideas: Dockable/Customizable Property Browser | Section Line API/Thread Feature in Assembly/PartsList API Static Cells | Fourth BOM Type