pyroll-project / pyroll-core

PyRoll rolling simulation framework - core library.
https://pyroll.readthedocs.io
BSD 3-Clause "New" or "Revised" License
12 stars 7 forks source link

Infinite contact_length Error - contact length calculation #240

Open RichardPfr opened 1 month ago

RichardPfr commented 1 month ago

The contact_length is currently calculated like this: https://github.com/pyroll-project/pyroll-core/blob/93bfbaf21d057b63e7d5023491470a41ca0b49d6/pyroll/core/roll_pass/hookimpls/roll.py#L11-L14

Problem

In cases like in the following this height_change outputs a negative value which in turn causes an error in the return function:

This is because for the roll_pass.height PyRolL only looks at the tip depth of the groove and if that is grater than the incoming profile it thinks, that both dont touch at all so no contact length would be there.

Proposed Solution

As the picture above shows though there would logically be a contact_length. Would it be feasible, to handle the contact length calculation differently in these cases, by looking at the intersection of groove and in_profile instead?

P.S.: The Error that is output with the above: grafik

ChRen95 commented 1 month ago

Please attach a MWE to reproduce this error.

RichardPfr commented 1 month ago

MWE to reproduce the Error:

MWE_Export.zip