# Collision detection during active modelling

I'm a newbie in Blender and I'm scripting in Python a routine that arranges irregular bodies according to a placement algorithm (Using AI and self-learning methods).

The problem I have so far is that when I place bodies in a systematic way, bodies could interfere (collide). The problem could be solved by using a complex contact algorithm (Contact detection) or you can make my life easier and give me a way to do it without going to the animation step.

Another perspective, is there any pre-scripted contact algorithms for irregular bodies? If so where can I find it?

• I believe the downvotes are probably due to poor formatting on your text, that made everything appear as header text. sin four dashes ---- will create a heading – Duarte Farrajota Ramos Oct 10 '18 at 11:31
• The first and last paragraphs makes sense but the middle one seems to contradict what you are doing in Blender. Can you use the built in Rigid Body Simulations? Do you want to detect collisions in Python either statically or with a rigid body simulation? Are you looking for a Python based collision algorithm to replicate the rigid body options? – rob Oct 10 '18 at 11:42
• Apologies, pretty sure I'm not clear enough. I need to activate body collision during the design phase if you used Autodesk 3ds max you can find such an option to activate collision between bodies during the design phase (Static) without the animation. It will be amazing if I can find something similar. Thx mates – Mahmoud S. M. Shaqfa Oct 10 '18 at 11:52
• I'm working on a problem that sort of (Packing problem) it's an optimization problem in the first place. I will be packing irregular bodies in a limited volume. I wanna make sure that the bodies are not interfering each other during the process. – Mahmoud S. M. Shaqfa Oct 10 '18 at 12:00