Spatial Contact Force -- Normal Force documentation

I am working with Simscape Multibody using Spatial Contact Force block. Can anyone point me to the documentation on the following:
  1. How is the first time derivative of the penetration depth computed as a function of time?
  2. What is the equation of the smoothing function?
Thank you in advance!

3 个评论

Hi @Ben,

I looked into the Spatial Contact Force block in Simscape Multibody and here’s what I found regarding your questions.

How the time derivative of penetration depth (dot d) is computed

Feedback: The documentation calls it “the first time derivative of the penetration depth,” meaning how fast the two objects are moving relative to each other along the contact direction.

What’s missing: The docs don’t explain exactly how Simscape calculates it internally. So,I don’t know if it’s based on the relative velocity at the contact point, a numerical difference of the penetration depth over time, or some other method.

The smoothing function

Feedback: The block uses a smoothing function to make the force increase gradually as the objects start to touch. The documentation says:

  • The function is 0 when objects are just touching, and 1 when penetration reaches the transition width.
  • It increases smoothly and continuously.
  • Its slope is zero at the start and end (so the force doesn’t jump abruptly).

What’s missing:* The documentation never gives the actual formula,which means you will only know the general behavior, not the exact math.

What you can do

Feedback: Contact MathWorks support to ask for the exact smoothing function and how the derivative is calculated — sometimes they can provide internal notes.If you just need something to test with, you can create your own smooth function that meets the same behavior (like a simple curve that goes from 0 to 1 smoothly).

*You can also log the penetration depth in your simulation and calculate its rate of change yourself

If you want full control, you can build a custom force function in Simscape or Simulink and define both the smoothing and the derivative yourself.

Also, I checked archived manuals from older versions of Simscape, and they repeat the same explanations, but still don’t show the exact formula or computation method.

Hope this helps.

I would extend @Umar's suggestion to contact Mathworks support with the submittal of a formal documentation enhancement to add these pieces of background information. While a heuristic description of what the model implementation does is helpful, it leaves the specifics unspecified which could not be defended if publishing using results from such a model, for example.

Hi @Ben,

Please let us know if you need further assistance, we are here to help you.

请先登录,再进行评论。

回答(0 个)

类别

帮助中心File Exchange 中查找有关 Applications 的更多信息

产品

版本

R2025b

标签

提问:

2025-11-16

评论:

2025-11-17

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by