I'm looking for the easiest way to simulate an array of cubes that is being pushed. Therefor I need to model the motion/collision effects, the friction with the floor and between blocks and also thermal expansion of the cubes, although that is secondary.

What libraries/packages/software do you recommend to have this simulation in place a.s.a.p.? I am familiar with python and js, therefor I've looked at pybullet & physicjs, however I'd like to hear your opinion on this.

Edit: The approach I have got in mind is to use some kind of 3D library that supports physics, which gives visualization and rapid development speed. Any other fast approach would be ok, though I will need to run many different combinations (block sizes, friction, etc) so it needs to be scriptable in some way.

  • $\begingroup$ my first suggestion for you is to use ANSYS. However, could you tell what kind of approach you are attempting for? Because, this helps in getting a closer and more helpful suggestion. $\endgroup$ Mar 31, 2017 at 7:50
  • $\begingroup$ bullet is a multibody simulator, but with emphasis on plausibility, not accuracy. Besides, friction is a bitch to simulate since you have no way of knowing the values for it without doing measurements on the actual pieces manufactured in same way in same scale... $\endgroup$
    – joojaa
    Mar 31, 2017 at 14:31
  • $\begingroup$ how accurate do you want your simulation to be? is it an engineering simulation, that will result in defining dimensions or patterns of a production line? is it a hobby simulation? game engines are capable of simulating those things, and thermal expansion can be added by yourself, too. $\endgroup$ Apr 3, 2018 at 19:32
  • $\begingroup$ This is an engineering simulation. In a production process, I am pushing a series of boxes through a channel and the boxes can not hit the wall. The boxes however, are tapered so they move sideways as well, they are heated in the channel so they expand and they experience friction with the rails they are on. $\endgroup$
    – marqram
    Apr 25, 2018 at 11:21

1 Answer 1


This is a multi-physics analysis, there are some open source packages though i'm not familiar with them (OpenFOAM is open source CFD software, and COMSOL is example of an commercial multi-physics solver). If you're looking at writing your own, "a.s.a.p." (as soon as possible) is going to be not very soon as that takes a huge amount of work.

The best solution is using a prebuilt software designed for that, ANSYS and NASTRAN are my go to solutions. NASTRAN I think has a better multi-physics integration but that's an opinion.

As far as I know there is no such thing as an "easy" way to do multi-physics analysis. Good luck!

Edit: Given the relative simplicity of the system you're looking at analyzing you may want to consider just one aspect at a time as the multi-physics aspect might be minimal. I.e. thermal expansion of the cubes sliding on a surface likely wont effect the contact. A good first approximation is to do individual analyses and then manually check to see what type of effect they would have on each other. If thermal expansion changes the temperature by a tenth of a degree thermal analysis in multi-phys would be well below the threshold for simulation error and could justifiably be neglected. It really will depend on what answers you're hoping to get from the solution.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.