The equation in documentation and the source code is not consistent

Asked by Yuxuan Wen

Hello,

I am trying to use a viscoelastic contact model to do the simulation. In the documentation, it shows there are 4 options to assign the parameters and I choose to used the 3rd option, where kn1, ks1, kn2, ks2 are assigned. The documentation shows that the equivalent normal stiffness is kn=2*kn1*kn2/(kn1+kn2), as shown in:

https://yade-dem.org/doc/yade.wrapper.html#yade.wrapper.Law2_ScGeom_ViscElPhys_Basic
----------------------------------------------------------------------------------------------------
If normal and tangential stiffnesses (kn, ks) and damping constant (cn,cs) of each particle are precised, the equivalent stiffnesses and damping constants of each contact made of two particles 1 and 2 is made A=2*a1*a2/(a1+a2).
----------------------------------------------------------------------------------------------------

However, I checked the source code of viscoelastic model and the kn in the source code is: kn=kn1*kn2/(kn1+kn2), the factor "2" is missing comparing to the documentation. The equation in the source code is shown in line 309 of https://gitlab.com/yade-dev/trunk/-/blob/master/pkg/dem/ViscoelasticPM.cpp

I am confused with this contradiction between the source code and the documentation. If you know which is the correct one, I wonder if you can help me, thank you!

Regards,
Yuxuan

Question information

Language:
English Edit question
Status:
Solved
For:
Yade Edit question
Assignee:
No assignee Edit question
Solved by:
Yuxuan Wen
Solved:
Last query:
Last reply:
Revision history for this message
Yuxuan Wen (wenyuxuan) said :
#1

Sorry, I am using the 2nd option in the documentation. I typed "3rd" in the original question, which is not correct, the 2nd option is what I meant to type.

Revision history for this message
Yuxuan Wen (wenyuxuan) said :
#2

Hello,

This question is answered in https://answers.launchpad.net/yade/+question/694574.

Thanks
Yuxuan