Mechanical simulation with kangaroo2

Hello everyone,

I recently tried a simple simulation in Kangaroo2, starting from an exercise I found online, to estimate how a lid moves when closing a compartment on a toolbox. Now I would like to attempt the same simulation using geometric constraints, but I don’t have enough experience in this area.

Could anyone guide me on this? I’m trying to understand whether it makes more sense (and is more efficient) to approach this with Kangaroo2, or if it would be better to rely on more “classic”

lid mechanism 00.gh (26.0 KB)

geometric tools instead.

Thank you very much for any advice!

Best regards, Filippo

1 Like

What Rhino version are you using?

So before digging any deeper, here’s how I would do it with Kangaroo:

Using a data recorder, you can then record the midpoint so you see a little better what curve it follows.

The setup with the pivot points appears to be symmetrical but it’s not by a tiny bit. Maybe for a start we could make it symmetrical?

Instead of 209.94 and 213.84, we could make both 210?

In a symmetrical setup the intersection point of the two diagonals describes an ellipse which means the sum of the length of the two segments from the initially horizontal base to the intersection is always the same.

Using a geometrical approach without doing any special math, you can construct an ellipse from foci.

A perp frame between the two foci can be mirrored on the tangent of the ellipse. I don’t know how to explain that any better.

lid mechanism 01.gh (44.3 KB)

In an asymmetrical setup, the curve described by the intersection of the two links is not an ellipse anymore. I guess this would then require a mathematical approach.

The aligned setup with different horizontal distances between pivot points can be constructed in Rhino and then points along the circular paths can be evaluated.

Now who’s going to do this with just trigonometry?

5 Likes

For a 4-bar linkage like this, it can also be solved with intersecting circles. Sometimes it might need a different strategy for automatically picking the right one of the 2 intersection points, but if you know the motion is within a given range, you can often just pick one.

4barlinkage.gh (11.3 KB)

3 Likes

Hi Martin, thank you so much for your detailed and thorough answer.

the rhino Version is 8 SR25 (8.25.25314.11001, 2025-11-10)

Martin , this would have been my next question, thanks for letting me know in advance :wink:

yup, you are right , simmetrical i confirm , my fault

perfect!

Ok undesrtood

what a deep inside !!! i love this approach , great learning opportunity , i also what to thank You because i learnt how to use data dam , very useful togheter witha ton of stuff in your definition.

asymmetrical setup is not of interest for the time being , that said i need to study your definition because its mostly clear but for instance i have never used componenrts.

concerning the corrent setup its clear now that there is a clash between lid and container , I wonder if using the data dam to trace the trajectory accordingly and then using the curve to model the “lid” and the “container” is the only solution or if instead a more complex kinematic scheme can be implemented to change trajectory, let’s say that in this case things get complicated.

what do you think, creating trajectories other than the elliptical one requires the use of toothed racks I suppose what do you say?

anyway , thanks a lot for your great support

Daniel thank You very much for your definition , these as simple as effective , its a great example on how to solve the problem using different approach, i love it !!!

I see what you mean concerning the “picking issue” …, all approached do have pro and cons , i need to make practise

@DanielPiker @martinsiegrist I want to send you my sincere thanks for sharing your time and expertise to help me. Thank you, really.

Martin, maybe a stupid question but how did you trace these trajectory curves ? where them all made using data recorded on different points ? i am impressed

Only the red mustache curve is created with the data dam.

1 Like

And here I am struggling with the basic native components. :face_with_diagonal_mouth:

2 Likes

Thanks Martin ,

shame on me but i am not able to understand how you created curve with data dam.

would you explain ? thanks

Record points with a data recorder component, cull duplicates and create a polyline

1 Like

Hi ,

yes this was clear, I define points on the area that i want to track , i use the trasformation to move them and i record all points , i then ( after culling duplicates ) interpolate the points and get the curve.

Imay be wrong but i don’t understand how data dam can be useful in the above workflow

BTW can i extend the concept and use curves rather than points thus to generate envelope surfaces ? ( or is it necessary to extract points / track them / interpolate them to get curves / and finally loft the curves ?)

I used the data dam to store the initial position of a plane.

You can record curves too but it might need some cleanup before you can do something useful with them…

1 Like