Jump to content
  • Advertisement
Sign in to follow this  
Narutachi

Hammering task problem being a softbody problem or not?

This topic is 3108 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Sorry for posting this question here but i do not know where to post it otherwise. So here is my problem: I want to simulate a hammering task, where an arm tries to hit a nail with a hammer in order to put the nail into a board. The nail should be deformable, the hammer obviously not. But i am not sure if it is best to simulate this task using softbody dynamics or not? I am new to physx but not to physics because i study physics about four years now. So maybe someone can help me. Another question: Do you think that this task is rather complicated or not (taking the dynamic constraints of the board to the nail into account during nailing). Thanks

Share this post


Link to post
Share on other sites
Advertisement
Frankly, no, I wouldn't use softbody dynamics. A nail is approximately a rigid body. When it deforms, it is because enough force was applied to deform it permanently, nonelastic deformation. And after the deformation, it again behaves like a rigid body. Soft body dynamics is usually about things that deform elastically...they bounce back like a rubber band or pillow or jellow or balloon filled with air. Or cloth that deforms freely. So, softbody is inappropriate.

I'll be frank again. You should get something working without worrying about nail deformation first. One step at a time. When you get that working, then you can perhaps add some *logic* to deal with nail deformation, e.g., test the force applied and torque applied, and if they exceed some threshold that you choose, then swap in a new shape for the nail that is deformed. Or procedurally deform it. There may be some PhysX tools that will help simulate the effect you want, but I do not believe you are going to do a pure physics simulation of the nail deforming realistically. That is kind out of the realm of most game physics engines due to the non-elastic nature of the deformation. (Actually I am pretty certain Pixelux's digital molecular matter--DMM--could do the nail simulation. DMM uses finite element technology that is capable of better material modeling and I believe they support deformation beyond the elastic region. I think they have indie/hobby-friendly prices, but probably you can't use it for free. Also, there is far less community experience and support for that product right now so depending on your patience and comfort level with less established tools, you might find DMM difficult to work with.)

Share this post


Link to post
Share on other sites
Thanks for your answer grhodes_at_work.
I will start with some simple scene. But maybe i should ask about the tools i should use first.

So basically i need a physics simulation for my diplom thesis. The parts i really need are:
1. It should be possible to put the nail step by step into a desk via some force applied by the hammer.
2. The nail should be deformable (it should not be 100% realistic, that's fine). The nails head does not have to be deformable.

For the first point i do not know how to put the nail step by step into the desk. In order to do so the desk has to be plastically deformable (by the sharp nail) too and i do not know which engine to use for that (physx, bullet, dmm, ...). Some advice here would be very helpful.

For the nail deformation: i think i can devide the nail into parts of rigid bodies and connect them somehow via some joints in order to simulate the deformation of the shaft, the head of the nail does not have to be deformable. Will this idea work?

If it's to difficult or even impossible to simulate this task with a common physics engine i will simulate these parts by myself but using a physics engine has many advantages over a self made simulation because of collision detection and so on which i wanted to avoid.


Thanks for your help

Share this post


Link to post
Share on other sites
i can't help with the code but i have hit a lot of nails. the heads of most hammers are rounded to a point and the nail usually bends in the middle in the direction of the side of the head you hit it in. where the nail bends also really depends on what kind of material you are driving it into and what kind of material the nail is made out of.

just make a non deformable nail and tell your professor that the nail is made out of tungsten. :D

really though, i dont think joints is the right idea. it is going to look weird. while the nail could bend at a point into an angle, it could also bend into a long curve. i am not sure about the difficulty of this but i would say that unless there is a certain amount of pressure it won't kink and turn into two lines.

how difficult would it be to use a spline to represent the nail?

Share this post


Link to post
Share on other sites
Thanks for your answer.
That's my last attempt to solve my problem using a physics engine. Basically i got a few ideas but it seems that nobody at nvidia's physx forum (http://developer.nvidia.com/forums/index.php?showtopic=3855) can help me. So i post the same ideas here again:

"So i got a few ideas to solve my problem, maybe someone can tell me if these ideas are good enough to try them out or not.

Basically i ran some of the lessons of physx and found the following lessons interesting:
Lesson405_Grass
Lesson1003_Damping
Lesson1010_Metal

My ideas:
In order to simulate the (deformable) desk i got the idea to use some kind of grass, maybe more than one layer of grass and maybe with different lengths and orientations (see the grass demo)

Can damping be adjusted in such a manner that it does not deform back into the original form? Maybe changing the damping parameter dynamically (using some threshold) such that the form gets fixed after deformation .

Can something like the metal demo be used to simulate the deformation of the nail?"

So that are my ideas i hope someone can lead me into the right direction.

Thank you all very much,
Thomas

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!